tor-browser

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

async-generator-name-redeclaration-attempt-with-var.js (780B)


      1 // |reftest| error:SyntaxError
      2 // This file was procedurally generated from the following sources:
      3 // - src/declarations/var.case
      4 // - src/declarations/redeclare-allow-var/switch-attempt-to-redeclare-async-generator-declaration.template
      5 /*---
      6 description: redeclaration with VariableDeclaration (AsyncGeneratorDeclaration in SwitchStatement)
      7 esid: sec-switch-statement-static-semantics-early-errors
      8 features: [async-iteration]
      9 flags: [generated]
     10 negative:
     11  phase: parse
     12  type: SyntaxError
     13 info: |
     14    SwitchStatement : switch ( Expression ) CaseBlock
     15 
     16    It is a Syntax Error if any element of the LexicallyDeclaredNames of
     17    CaseBlock also occurs in the VarDeclaredNames of CaseBlock.
     18 
     19 ---*/
     20 
     21 
     22 $DONOTEVALUATE();
     23 
     24 switch (0) { case 1: async function* f() {} default: var f }