tor-browser

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

dflt-params-duplicates.js (1276B)


      1 // |reftest| error:SyntaxError
      2 // This file was procedurally generated from the following sources:
      3 // - src/function-forms/dflt-params-duplicates.case
      4 // - src/function-forms/syntax/async-gen-func-expr.template
      5 /*---
      6 description: It is a Syntax Error if BoundNames of FormalParameters contains any duplicate elements. (async generator function expression)
      7 esid: sec-asyncgenerator-definitions-evaluation
      8 features: [default-parameters, async-iteration]
      9 flags: [generated]
     10 negative:
     11  phase: parse
     12  type: SyntaxError
     13 info: |
     14    AsyncGeneratorExpression : async [no LineTerminator here] function * ( FormalParameters ) {
     15        AsyncGeneratorBody }
     16 
     17        [...]
     18        3. Let closure be ! AsyncGeneratorFunctionCreate(Normal, FormalParameters,
     19           AsyncGeneratorBody, scope, strict).
     20        [...]
     21 
     22 
     23    14.1.2 Static Semantics: Early Errors
     24 
     25    StrictFormalParameters : FormalParameters
     26 
     27    - It is a Syntax Error if BoundNames of FormalParameters contains any
     28      duplicate elements.
     29 
     30    FormalParameters : FormalParameterList
     31 
     32    - It is a Syntax Error if IsSimpleParameterList of FormalParameterList is
     33      false and BoundNames of FormalParameterList contains any duplicate
     34      elements.
     35 
     36 ---*/
     37 $DONOTEVALUATE();
     38 
     39 
     40 0, async function*(x = 0, x) {
     41  
     42 };