tor-browser

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

ident-name-prop-name-literal-await-static-init.js (686B)


      1 // Copyright (C) 2021 the V8 project authors. All rights reserved.
      2 // This code is governed by the BSD license found in the LICENSE file.
      3 /*---
      4 esid: sec-class-definitions-static-semantics-early-errors
      5 description: The restriction on `await` does not apply to IdentifierName
      6 info: |
      7  BindingIdentifier : Identifier
      8 
      9  [...]
     10  - It is a Syntax Error if the code matched by this production is nested,
     11    directly or indirectly (but not crossing function or static initialization
     12    block boundaries), within a ClassStaticBlock and the StringValue of
     13    Identifier is "await".
     14 features: [class-static-block]
     15 ---*/
     16 
     17 class C {
     18  static {
     19    ({ await: 0 });
     20  }
     21 }
     22 
     23 
     24 reportCompare(0, 0);