tor-browser

The Tor Browser
git clone https://git.dasho.dev/tor-browser.git
Log | Files | Refs | README | LICENSE

emulates-undefined.js (771B)


      1 // Copyright (C) 2020 Alexey Shvayka. All rights reserved.
      2 // This code is governed by the BSD license found in the LICENSE file.
      3 /*---
      4 esid: sec-binary-logical-operators-runtime-semantics-evaluation
      5 description: >
      6  ToBoolean returns `false` for [[IsHTMLDDA]] object.
      7 info: |
      8  UnaryExpression : ! UnaryExpression
      9 
     10  1. Let expr be the result of evaluating UnaryExpression.
     11  2. Let oldValue be ! ToBoolean(? GetValue(expr)).
     12  3. If oldValue is true, return false.
     13  4. Return true.
     14 
     15  The [[IsHTMLDDA]] Internal Slot / Changes to ToBoolean
     16 
     17  1. If argument has an [[IsHTMLDDA]] internal slot, return false.
     18  2. Return true.
     19 features: [IsHTMLDDA]
     20 ---*/
     21 
     22 var IsHTMLDDA = $262.IsHTMLDDA;
     23 
     24 assert(!IsHTMLDDA);
     25 assert.sameValue(!!IsHTMLDDA, false);
     26 
     27 reportCompare(0, 0);