summaryrefslogtreecommitdiffstats
path: root/js/src/tests/test262/language/block-scope/syntax/redeclaration
diff options
context:
space:
mode:
Diffstat (limited to 'js/src/tests/test262/language/block-scope/syntax/redeclaration')
-rw-r--r--js/src/tests/test262/language/block-scope/syntax/redeclaration/async-function-name-redeclaration-attempt-with-async-function.js24
-rw-r--r--js/src/tests/test262/language/block-scope/syntax/redeclaration/async-function-name-redeclaration-attempt-with-async-generator.js24
-rw-r--r--js/src/tests/test262/language/block-scope/syntax/redeclaration/async-function-name-redeclaration-attempt-with-class.js24
-rw-r--r--js/src/tests/test262/language/block-scope/syntax/redeclaration/async-function-name-redeclaration-attempt-with-const.js24
-rw-r--r--js/src/tests/test262/language/block-scope/syntax/redeclaration/async-function-name-redeclaration-attempt-with-function.js24
-rw-r--r--js/src/tests/test262/language/block-scope/syntax/redeclaration/async-function-name-redeclaration-attempt-with-generator.js24
-rw-r--r--js/src/tests/test262/language/block-scope/syntax/redeclaration/async-function-name-redeclaration-attempt-with-let.js24
-rw-r--r--js/src/tests/test262/language/block-scope/syntax/redeclaration/async-function-name-redeclaration-attempt-with-var.js24
-rw-r--r--js/src/tests/test262/language/block-scope/syntax/redeclaration/async-generator-name-redeclaration-attempt-with-async-function.js24
-rw-r--r--js/src/tests/test262/language/block-scope/syntax/redeclaration/async-generator-name-redeclaration-attempt-with-async-generator.js24
-rw-r--r--js/src/tests/test262/language/block-scope/syntax/redeclaration/async-generator-name-redeclaration-attempt-with-class.js24
-rw-r--r--js/src/tests/test262/language/block-scope/syntax/redeclaration/async-generator-name-redeclaration-attempt-with-const.js24
-rw-r--r--js/src/tests/test262/language/block-scope/syntax/redeclaration/async-generator-name-redeclaration-attempt-with-function.js24
-rw-r--r--js/src/tests/test262/language/block-scope/syntax/redeclaration/async-generator-name-redeclaration-attempt-with-generator.js24
-rw-r--r--js/src/tests/test262/language/block-scope/syntax/redeclaration/async-generator-name-redeclaration-attempt-with-let.js24
-rw-r--r--js/src/tests/test262/language/block-scope/syntax/redeclaration/async-generator-name-redeclaration-attempt-with-var.js24
-rw-r--r--js/src/tests/test262/language/block-scope/syntax/redeclaration/browser.js0
-rw-r--r--js/src/tests/test262/language/block-scope/syntax/redeclaration/class-name-redeclaration-attempt-with-async-function.js24
-rw-r--r--js/src/tests/test262/language/block-scope/syntax/redeclaration/class-name-redeclaration-attempt-with-async-generator.js24
-rw-r--r--js/src/tests/test262/language/block-scope/syntax/redeclaration/class-name-redeclaration-attempt-with-class.js23
-rw-r--r--js/src/tests/test262/language/block-scope/syntax/redeclaration/class-name-redeclaration-attempt-with-const.js23
-rw-r--r--js/src/tests/test262/language/block-scope/syntax/redeclaration/class-name-redeclaration-attempt-with-function.js23
-rw-r--r--js/src/tests/test262/language/block-scope/syntax/redeclaration/class-name-redeclaration-attempt-with-generator.js24
-rw-r--r--js/src/tests/test262/language/block-scope/syntax/redeclaration/class-name-redeclaration-attempt-with-let.js23
-rw-r--r--js/src/tests/test262/language/block-scope/syntax/redeclaration/class-name-redeclaration-attempt-with-var.js23
-rw-r--r--js/src/tests/test262/language/block-scope/syntax/redeclaration/const-name-redeclaration-attempt-with-async-function.js24
-rw-r--r--js/src/tests/test262/language/block-scope/syntax/redeclaration/const-name-redeclaration-attempt-with-async-generator.js24
-rw-r--r--js/src/tests/test262/language/block-scope/syntax/redeclaration/const-name-redeclaration-attempt-with-class.js23
-rw-r--r--js/src/tests/test262/language/block-scope/syntax/redeclaration/const-name-redeclaration-attempt-with-const.js23
-rw-r--r--js/src/tests/test262/language/block-scope/syntax/redeclaration/const-name-redeclaration-attempt-with-function.js23
-rw-r--r--js/src/tests/test262/language/block-scope/syntax/redeclaration/const-name-redeclaration-attempt-with-generator.js24
-rw-r--r--js/src/tests/test262/language/block-scope/syntax/redeclaration/const-name-redeclaration-attempt-with-let.js23
-rw-r--r--js/src/tests/test262/language/block-scope/syntax/redeclaration/const-name-redeclaration-attempt-with-var.js23
-rw-r--r--js/src/tests/test262/language/block-scope/syntax/redeclaration/fn-scope-var-name-redeclaration-attempt-with-async-function.js26
-rw-r--r--js/src/tests/test262/language/block-scope/syntax/redeclaration/fn-scope-var-name-redeclaration-attempt-with-async-generator.js26
-rw-r--r--js/src/tests/test262/language/block-scope/syntax/redeclaration/fn-scope-var-name-redeclaration-attempt-with-class.js25
-rw-r--r--js/src/tests/test262/language/block-scope/syntax/redeclaration/fn-scope-var-name-redeclaration-attempt-with-const.js25
-rw-r--r--js/src/tests/test262/language/block-scope/syntax/redeclaration/fn-scope-var-name-redeclaration-attempt-with-function.js25
-rw-r--r--js/src/tests/test262/language/block-scope/syntax/redeclaration/fn-scope-var-name-redeclaration-attempt-with-generator.js26
-rw-r--r--js/src/tests/test262/language/block-scope/syntax/redeclaration/fn-scope-var-name-redeclaration-attempt-with-let.js25
-rw-r--r--js/src/tests/test262/language/block-scope/syntax/redeclaration/fn-scope-var-name-redeclaration-attempt-with-var.js20
-rw-r--r--js/src/tests/test262/language/block-scope/syntax/redeclaration/function-declaration-attempt-to-redeclare-with-var-declaration-nested-in-function.js32
-rw-r--r--js/src/tests/test262/language/block-scope/syntax/redeclaration/function-name-redeclaration-attempt-with-async-function.js24
-rw-r--r--js/src/tests/test262/language/block-scope/syntax/redeclaration/function-name-redeclaration-attempt-with-async-generator.js24
-rw-r--r--js/src/tests/test262/language/block-scope/syntax/redeclaration/function-name-redeclaration-attempt-with-class.js23
-rw-r--r--js/src/tests/test262/language/block-scope/syntax/redeclaration/function-name-redeclaration-attempt-with-const.js23
-rw-r--r--js/src/tests/test262/language/block-scope/syntax/redeclaration/function-name-redeclaration-attempt-with-function-strict.js24
-rw-r--r--js/src/tests/test262/language/block-scope/syntax/redeclaration/function-name-redeclaration-attempt-with-generator.js24
-rw-r--r--js/src/tests/test262/language/block-scope/syntax/redeclaration/function-name-redeclaration-attempt-with-let.js23
-rw-r--r--js/src/tests/test262/language/block-scope/syntax/redeclaration/function-name-redeclaration-attempt-with-var.js23
-rw-r--r--js/src/tests/test262/language/block-scope/syntax/redeclaration/generator-name-redeclaration-attempt-with-async-function.js24
-rw-r--r--js/src/tests/test262/language/block-scope/syntax/redeclaration/generator-name-redeclaration-attempt-with-async-generator.js24
-rw-r--r--js/src/tests/test262/language/block-scope/syntax/redeclaration/generator-name-redeclaration-attempt-with-class.js24
-rw-r--r--js/src/tests/test262/language/block-scope/syntax/redeclaration/generator-name-redeclaration-attempt-with-const.js24
-rw-r--r--js/src/tests/test262/language/block-scope/syntax/redeclaration/generator-name-redeclaration-attempt-with-function.js24
-rw-r--r--js/src/tests/test262/language/block-scope/syntax/redeclaration/generator-name-redeclaration-attempt-with-generator.js24
-rw-r--r--js/src/tests/test262/language/block-scope/syntax/redeclaration/generator-name-redeclaration-attempt-with-let.js24
-rw-r--r--js/src/tests/test262/language/block-scope/syntax/redeclaration/generator-name-redeclaration-attempt-with-var.js24
-rw-r--r--js/src/tests/test262/language/block-scope/syntax/redeclaration/inner-block-var-name-redeclaration-attempt-with-async-function.js40
-rw-r--r--js/src/tests/test262/language/block-scope/syntax/redeclaration/inner-block-var-name-redeclaration-attempt-with-async-generator.js40
-rw-r--r--js/src/tests/test262/language/block-scope/syntax/redeclaration/inner-block-var-name-redeclaration-attempt-with-class.js39
-rw-r--r--js/src/tests/test262/language/block-scope/syntax/redeclaration/inner-block-var-name-redeclaration-attempt-with-const.js39
-rw-r--r--js/src/tests/test262/language/block-scope/syntax/redeclaration/inner-block-var-name-redeclaration-attempt-with-function.js39
-rw-r--r--js/src/tests/test262/language/block-scope/syntax/redeclaration/inner-block-var-name-redeclaration-attempt-with-generator.js40
-rw-r--r--js/src/tests/test262/language/block-scope/syntax/redeclaration/inner-block-var-name-redeclaration-attempt-with-let.js39
-rw-r--r--js/src/tests/test262/language/block-scope/syntax/redeclaration/inner-block-var-name-redeclaration-attempt-with-var.js34
-rw-r--r--js/src/tests/test262/language/block-scope/syntax/redeclaration/inner-block-var-redeclaration-attempt-after-async-function.js40
-rw-r--r--js/src/tests/test262/language/block-scope/syntax/redeclaration/inner-block-var-redeclaration-attempt-after-async-generator.js40
-rw-r--r--js/src/tests/test262/language/block-scope/syntax/redeclaration/inner-block-var-redeclaration-attempt-after-class.js39
-rw-r--r--js/src/tests/test262/language/block-scope/syntax/redeclaration/inner-block-var-redeclaration-attempt-after-const.js39
-rw-r--r--js/src/tests/test262/language/block-scope/syntax/redeclaration/inner-block-var-redeclaration-attempt-after-function.js39
-rw-r--r--js/src/tests/test262/language/block-scope/syntax/redeclaration/inner-block-var-redeclaration-attempt-after-generator.js40
-rw-r--r--js/src/tests/test262/language/block-scope/syntax/redeclaration/inner-block-var-redeclaration-attempt-after-let.js39
-rw-r--r--js/src/tests/test262/language/block-scope/syntax/redeclaration/let-name-redeclaration-attempt-with-async-function.js24
-rw-r--r--js/src/tests/test262/language/block-scope/syntax/redeclaration/let-name-redeclaration-attempt-with-async-generator.js24
-rw-r--r--js/src/tests/test262/language/block-scope/syntax/redeclaration/let-name-redeclaration-attempt-with-class.js23
-rw-r--r--js/src/tests/test262/language/block-scope/syntax/redeclaration/let-name-redeclaration-attempt-with-const.js23
-rw-r--r--js/src/tests/test262/language/block-scope/syntax/redeclaration/let-name-redeclaration-attempt-with-function.js23
-rw-r--r--js/src/tests/test262/language/block-scope/syntax/redeclaration/let-name-redeclaration-attempt-with-generator.js24
-rw-r--r--js/src/tests/test262/language/block-scope/syntax/redeclaration/let-name-redeclaration-attempt-with-let.js23
-rw-r--r--js/src/tests/test262/language/block-scope/syntax/redeclaration/let-name-redeclaration-attempt-with-var.js23
-rw-r--r--js/src/tests/test262/language/block-scope/syntax/redeclaration/shell.js0
-rw-r--r--js/src/tests/test262/language/block-scope/syntax/redeclaration/var-name-redeclaration-attempt-with-async-function.js24
-rw-r--r--js/src/tests/test262/language/block-scope/syntax/redeclaration/var-name-redeclaration-attempt-with-async-generator.js24
-rw-r--r--js/src/tests/test262/language/block-scope/syntax/redeclaration/var-name-redeclaration-attempt-with-class.js23
-rw-r--r--js/src/tests/test262/language/block-scope/syntax/redeclaration/var-name-redeclaration-attempt-with-const.js23
-rw-r--r--js/src/tests/test262/language/block-scope/syntax/redeclaration/var-name-redeclaration-attempt-with-function.js23
-rw-r--r--js/src/tests/test262/language/block-scope/syntax/redeclaration/var-name-redeclaration-attempt-with-generator.js24
-rw-r--r--js/src/tests/test262/language/block-scope/syntax/redeclaration/var-name-redeclaration-attempt-with-let.js23
-rw-r--r--js/src/tests/test262/language/block-scope/syntax/redeclaration/var-name-redeclaration-attempt-with-var.js18
-rw-r--r--js/src/tests/test262/language/block-scope/syntax/redeclaration/var-redeclaration-attempt-after-async-function.js24
-rw-r--r--js/src/tests/test262/language/block-scope/syntax/redeclaration/var-redeclaration-attempt-after-async-generator.js24
-rw-r--r--js/src/tests/test262/language/block-scope/syntax/redeclaration/var-redeclaration-attempt-after-class.js23
-rw-r--r--js/src/tests/test262/language/block-scope/syntax/redeclaration/var-redeclaration-attempt-after-const.js23
-rw-r--r--js/src/tests/test262/language/block-scope/syntax/redeclaration/var-redeclaration-attempt-after-function.js23
-rw-r--r--js/src/tests/test262/language/block-scope/syntax/redeclaration/var-redeclaration-attempt-after-generator.js24
-rw-r--r--js/src/tests/test262/language/block-scope/syntax/redeclaration/var-redeclaration-attempt-after-let.js23
97 files changed, 2487 insertions, 0 deletions
diff --git a/js/src/tests/test262/language/block-scope/syntax/redeclaration/async-function-name-redeclaration-attempt-with-async-function.js b/js/src/tests/test262/language/block-scope/syntax/redeclaration/async-function-name-redeclaration-attempt-with-async-function.js
new file mode 100644
index 0000000000..30e9060835
--- /dev/null
+++ b/js/src/tests/test262/language/block-scope/syntax/redeclaration/async-function-name-redeclaration-attempt-with-async-function.js
@@ -0,0 +1,24 @@
+// |reftest| error:SyntaxError
+// This file was procedurally generated from the following sources:
+// - src/declarations/async-function.case
+// - src/declarations/redeclare/block-attempt-to-redeclare-async-function-declaration.template
+/*---
+description: redeclaration with AsyncFunctionDeclaration (AsyncFunctionDeclaration in BlockStatement)
+esid: sec-block-static-semantics-early-errors
+features: [async-functions]
+flags: [generated]
+negative:
+ phase: parse
+ type: SyntaxError
+info: |
+ Block : { StatementList }
+
+ It is a Syntax Error if the LexicallyDeclaredNames of StatementList contains
+ any duplicate entries.
+
+---*/
+
+
+$DONOTEVALUATE();
+
+{ async function f() {} async function f() {} }
diff --git a/js/src/tests/test262/language/block-scope/syntax/redeclaration/async-function-name-redeclaration-attempt-with-async-generator.js b/js/src/tests/test262/language/block-scope/syntax/redeclaration/async-function-name-redeclaration-attempt-with-async-generator.js
new file mode 100644
index 0000000000..f0090c5c2c
--- /dev/null
+++ b/js/src/tests/test262/language/block-scope/syntax/redeclaration/async-function-name-redeclaration-attempt-with-async-generator.js
@@ -0,0 +1,24 @@
+// |reftest| error:SyntaxError
+// This file was procedurally generated from the following sources:
+// - src/declarations/async-generator.case
+// - src/declarations/redeclare/block-attempt-to-redeclare-async-function-declaration.template
+/*---
+description: redeclaration with AsyncGeneratorDeclaration (AsyncFunctionDeclaration in BlockStatement)
+esid: sec-block-static-semantics-early-errors
+features: [async-iteration, async-functions]
+flags: [generated]
+negative:
+ phase: parse
+ type: SyntaxError
+info: |
+ Block : { StatementList }
+
+ It is a Syntax Error if the LexicallyDeclaredNames of StatementList contains
+ any duplicate entries.
+
+---*/
+
+
+$DONOTEVALUATE();
+
+{ async function f() {} async function* f() {} }
diff --git a/js/src/tests/test262/language/block-scope/syntax/redeclaration/async-function-name-redeclaration-attempt-with-class.js b/js/src/tests/test262/language/block-scope/syntax/redeclaration/async-function-name-redeclaration-attempt-with-class.js
new file mode 100644
index 0000000000..fd0003513b
--- /dev/null
+++ b/js/src/tests/test262/language/block-scope/syntax/redeclaration/async-function-name-redeclaration-attempt-with-class.js
@@ -0,0 +1,24 @@
+// |reftest| error:SyntaxError
+// This file was procedurally generated from the following sources:
+// - src/declarations/class.case
+// - src/declarations/redeclare/block-attempt-to-redeclare-async-function-declaration.template
+/*---
+description: redeclaration with ClassDeclaration (AsyncFunctionDeclaration in BlockStatement)
+esid: sec-block-static-semantics-early-errors
+features: [async-functions]
+flags: [generated]
+negative:
+ phase: parse
+ type: SyntaxError
+info: |
+ Block : { StatementList }
+
+ It is a Syntax Error if the LexicallyDeclaredNames of StatementList contains
+ any duplicate entries.
+
+---*/
+
+
+$DONOTEVALUATE();
+
+{ async function f() {} class f {} }
diff --git a/js/src/tests/test262/language/block-scope/syntax/redeclaration/async-function-name-redeclaration-attempt-with-const.js b/js/src/tests/test262/language/block-scope/syntax/redeclaration/async-function-name-redeclaration-attempt-with-const.js
new file mode 100644
index 0000000000..2d2da8c965
--- /dev/null
+++ b/js/src/tests/test262/language/block-scope/syntax/redeclaration/async-function-name-redeclaration-attempt-with-const.js
@@ -0,0 +1,24 @@
+// |reftest| error:SyntaxError
+// This file was procedurally generated from the following sources:
+// - src/declarations/const.case
+// - src/declarations/redeclare/block-attempt-to-redeclare-async-function-declaration.template
+/*---
+description: redeclaration with const-LexicalDeclaration (AsyncFunctionDeclaration in BlockStatement)
+esid: sec-block-static-semantics-early-errors
+features: [async-functions]
+flags: [generated]
+negative:
+ phase: parse
+ type: SyntaxError
+info: |
+ Block : { StatementList }
+
+ It is a Syntax Error if the LexicallyDeclaredNames of StatementList contains
+ any duplicate entries.
+
+---*/
+
+
+$DONOTEVALUATE();
+
+{ async function f() {} const f = 0 }
diff --git a/js/src/tests/test262/language/block-scope/syntax/redeclaration/async-function-name-redeclaration-attempt-with-function.js b/js/src/tests/test262/language/block-scope/syntax/redeclaration/async-function-name-redeclaration-attempt-with-function.js
new file mode 100644
index 0000000000..63838a6d0d
--- /dev/null
+++ b/js/src/tests/test262/language/block-scope/syntax/redeclaration/async-function-name-redeclaration-attempt-with-function.js
@@ -0,0 +1,24 @@
+// |reftest| error:SyntaxError
+// This file was procedurally generated from the following sources:
+// - src/declarations/function.case
+// - src/declarations/redeclare-allow-sloppy-function/block-attempt-to-redeclare-async-function-declaration.template
+/*---
+description: redeclaration with FunctionDeclaration (AsyncFunctionDeclaration in BlockStatement)
+esid: sec-block-static-semantics-early-errors
+features: [async-functions]
+flags: [generated]
+negative:
+ phase: parse
+ type: SyntaxError
+info: |
+ Block : { StatementList }
+
+ It is a Syntax Error if the LexicallyDeclaredNames of StatementList contains
+ any duplicate entries.
+
+---*/
+
+
+$DONOTEVALUATE();
+
+{ async function f() {} function f() {} }
diff --git a/js/src/tests/test262/language/block-scope/syntax/redeclaration/async-function-name-redeclaration-attempt-with-generator.js b/js/src/tests/test262/language/block-scope/syntax/redeclaration/async-function-name-redeclaration-attempt-with-generator.js
new file mode 100644
index 0000000000..7c6ddaf799
--- /dev/null
+++ b/js/src/tests/test262/language/block-scope/syntax/redeclaration/async-function-name-redeclaration-attempt-with-generator.js
@@ -0,0 +1,24 @@
+// |reftest| error:SyntaxError
+// This file was procedurally generated from the following sources:
+// - src/declarations/generator.case
+// - src/declarations/redeclare/block-attempt-to-redeclare-async-function-declaration.template
+/*---
+description: redeclaration with GeneratorDeclaration (AsyncFunctionDeclaration in BlockStatement)
+esid: sec-block-static-semantics-early-errors
+features: [generators, async-functions]
+flags: [generated]
+negative:
+ phase: parse
+ type: SyntaxError
+info: |
+ Block : { StatementList }
+
+ It is a Syntax Error if the LexicallyDeclaredNames of StatementList contains
+ any duplicate entries.
+
+---*/
+
+
+$DONOTEVALUATE();
+
+{ async function f() {} function* f() {} }
diff --git a/js/src/tests/test262/language/block-scope/syntax/redeclaration/async-function-name-redeclaration-attempt-with-let.js b/js/src/tests/test262/language/block-scope/syntax/redeclaration/async-function-name-redeclaration-attempt-with-let.js
new file mode 100644
index 0000000000..60bf796a9c
--- /dev/null
+++ b/js/src/tests/test262/language/block-scope/syntax/redeclaration/async-function-name-redeclaration-attempt-with-let.js
@@ -0,0 +1,24 @@
+// |reftest| error:SyntaxError
+// This file was procedurally generated from the following sources:
+// - src/declarations/let.case
+// - src/declarations/redeclare/block-attempt-to-redeclare-async-function-declaration.template
+/*---
+description: redeclaration with let-LexicalDeclaration (AsyncFunctionDeclaration in BlockStatement)
+esid: sec-block-static-semantics-early-errors
+features: [async-functions]
+flags: [generated]
+negative:
+ phase: parse
+ type: SyntaxError
+info: |
+ Block : { StatementList }
+
+ It is a Syntax Error if the LexicallyDeclaredNames of StatementList contains
+ any duplicate entries.
+
+---*/
+
+
+$DONOTEVALUATE();
+
+{ async function f() {} let f }
diff --git a/js/src/tests/test262/language/block-scope/syntax/redeclaration/async-function-name-redeclaration-attempt-with-var.js b/js/src/tests/test262/language/block-scope/syntax/redeclaration/async-function-name-redeclaration-attempt-with-var.js
new file mode 100644
index 0000000000..df21e890e6
--- /dev/null
+++ b/js/src/tests/test262/language/block-scope/syntax/redeclaration/async-function-name-redeclaration-attempt-with-var.js
@@ -0,0 +1,24 @@
+// |reftest| error:SyntaxError
+// This file was procedurally generated from the following sources:
+// - src/declarations/var.case
+// - src/declarations/redeclare-allow-var/block-attempt-to-redeclare-async-function-declaration.template
+/*---
+description: redeclaration with VariableDeclaration (AsyncFunctionDeclaration in BlockStatement)
+esid: sec-block-static-semantics-early-errors
+features: [async-functions]
+flags: [generated]
+negative:
+ phase: parse
+ type: SyntaxError
+info: |
+ Block : { StatementList }
+
+ It is a Syntax Error if any element of the LexicallyDeclaredNames of
+ StatementList also occurs in the VarDeclaredNames of StatementList.
+
+---*/
+
+
+$DONOTEVALUATE();
+
+{ async function f() {} var f }
diff --git a/js/src/tests/test262/language/block-scope/syntax/redeclaration/async-generator-name-redeclaration-attempt-with-async-function.js b/js/src/tests/test262/language/block-scope/syntax/redeclaration/async-generator-name-redeclaration-attempt-with-async-function.js
new file mode 100644
index 0000000000..3c23f35b63
--- /dev/null
+++ b/js/src/tests/test262/language/block-scope/syntax/redeclaration/async-generator-name-redeclaration-attempt-with-async-function.js
@@ -0,0 +1,24 @@
+// |reftest| error:SyntaxError
+// This file was procedurally generated from the following sources:
+// - src/declarations/async-function.case
+// - src/declarations/redeclare/block-attempt-to-redeclare-async-generator-declaration.template
+/*---
+description: redeclaration with AsyncFunctionDeclaration (AsyncGeneratorDeclaration in BlockStatement)
+esid: sec-block-static-semantics-early-errors
+features: [async-functions, async-iteration]
+flags: [generated]
+negative:
+ phase: parse
+ type: SyntaxError
+info: |
+ Block : { StatementList }
+
+ It is a Syntax Error if the LexicallyDeclaredNames of StatementList contains
+ any duplicate entries.
+
+---*/
+
+
+$DONOTEVALUATE();
+
+{ async function* f() {} async function f() {} }
diff --git a/js/src/tests/test262/language/block-scope/syntax/redeclaration/async-generator-name-redeclaration-attempt-with-async-generator.js b/js/src/tests/test262/language/block-scope/syntax/redeclaration/async-generator-name-redeclaration-attempt-with-async-generator.js
new file mode 100644
index 0000000000..a5a05f0cef
--- /dev/null
+++ b/js/src/tests/test262/language/block-scope/syntax/redeclaration/async-generator-name-redeclaration-attempt-with-async-generator.js
@@ -0,0 +1,24 @@
+// |reftest| error:SyntaxError
+// This file was procedurally generated from the following sources:
+// - src/declarations/async-generator.case
+// - src/declarations/redeclare/block-attempt-to-redeclare-async-generator-declaration.template
+/*---
+description: redeclaration with AsyncGeneratorDeclaration (AsyncGeneratorDeclaration in BlockStatement)
+esid: sec-block-static-semantics-early-errors
+features: [async-iteration]
+flags: [generated]
+negative:
+ phase: parse
+ type: SyntaxError
+info: |
+ Block : { StatementList }
+
+ It is a Syntax Error if the LexicallyDeclaredNames of StatementList contains
+ any duplicate entries.
+
+---*/
+
+
+$DONOTEVALUATE();
+
+{ async function* f() {} async function* f() {} }
diff --git a/js/src/tests/test262/language/block-scope/syntax/redeclaration/async-generator-name-redeclaration-attempt-with-class.js b/js/src/tests/test262/language/block-scope/syntax/redeclaration/async-generator-name-redeclaration-attempt-with-class.js
new file mode 100644
index 0000000000..762c243df1
--- /dev/null
+++ b/js/src/tests/test262/language/block-scope/syntax/redeclaration/async-generator-name-redeclaration-attempt-with-class.js
@@ -0,0 +1,24 @@
+// |reftest| error:SyntaxError
+// This file was procedurally generated from the following sources:
+// - src/declarations/class.case
+// - src/declarations/redeclare/block-attempt-to-redeclare-async-generator-declaration.template
+/*---
+description: redeclaration with ClassDeclaration (AsyncGeneratorDeclaration in BlockStatement)
+esid: sec-block-static-semantics-early-errors
+features: [async-iteration]
+flags: [generated]
+negative:
+ phase: parse
+ type: SyntaxError
+info: |
+ Block : { StatementList }
+
+ It is a Syntax Error if the LexicallyDeclaredNames of StatementList contains
+ any duplicate entries.
+
+---*/
+
+
+$DONOTEVALUATE();
+
+{ async function* f() {} class f {} }
diff --git a/js/src/tests/test262/language/block-scope/syntax/redeclaration/async-generator-name-redeclaration-attempt-with-const.js b/js/src/tests/test262/language/block-scope/syntax/redeclaration/async-generator-name-redeclaration-attempt-with-const.js
new file mode 100644
index 0000000000..3063589f2c
--- /dev/null
+++ b/js/src/tests/test262/language/block-scope/syntax/redeclaration/async-generator-name-redeclaration-attempt-with-const.js
@@ -0,0 +1,24 @@
+// |reftest| error:SyntaxError
+// This file was procedurally generated from the following sources:
+// - src/declarations/const.case
+// - src/declarations/redeclare/block-attempt-to-redeclare-async-generator-declaration.template
+/*---
+description: redeclaration with const-LexicalDeclaration (AsyncGeneratorDeclaration in BlockStatement)
+esid: sec-block-static-semantics-early-errors
+features: [async-iteration]
+flags: [generated]
+negative:
+ phase: parse
+ type: SyntaxError
+info: |
+ Block : { StatementList }
+
+ It is a Syntax Error if the LexicallyDeclaredNames of StatementList contains
+ any duplicate entries.
+
+---*/
+
+
+$DONOTEVALUATE();
+
+{ async function* f() {} const f = 0 }
diff --git a/js/src/tests/test262/language/block-scope/syntax/redeclaration/async-generator-name-redeclaration-attempt-with-function.js b/js/src/tests/test262/language/block-scope/syntax/redeclaration/async-generator-name-redeclaration-attempt-with-function.js
new file mode 100644
index 0000000000..fe967de833
--- /dev/null
+++ b/js/src/tests/test262/language/block-scope/syntax/redeclaration/async-generator-name-redeclaration-attempt-with-function.js
@@ -0,0 +1,24 @@
+// |reftest| error:SyntaxError
+// This file was procedurally generated from the following sources:
+// - src/declarations/function.case
+// - src/declarations/redeclare-allow-sloppy-function/block-attempt-to-redeclare-async-generator-declaration.template
+/*---
+description: redeclaration with FunctionDeclaration (AsyncGeneratorDeclaration in BlockStatement)
+esid: sec-block-static-semantics-early-errors
+features: [async-iteration]
+flags: [generated]
+negative:
+ phase: parse
+ type: SyntaxError
+info: |
+ Block : { StatementList }
+
+ It is a Syntax Error if the LexicallyDeclaredNames of StatementList contains
+ any duplicate entries.
+
+---*/
+
+
+$DONOTEVALUATE();
+
+{ async function* f() {} function f() {} }
diff --git a/js/src/tests/test262/language/block-scope/syntax/redeclaration/async-generator-name-redeclaration-attempt-with-generator.js b/js/src/tests/test262/language/block-scope/syntax/redeclaration/async-generator-name-redeclaration-attempt-with-generator.js
new file mode 100644
index 0000000000..4309c5c10d
--- /dev/null
+++ b/js/src/tests/test262/language/block-scope/syntax/redeclaration/async-generator-name-redeclaration-attempt-with-generator.js
@@ -0,0 +1,24 @@
+// |reftest| error:SyntaxError
+// This file was procedurally generated from the following sources:
+// - src/declarations/generator.case
+// - src/declarations/redeclare/block-attempt-to-redeclare-async-generator-declaration.template
+/*---
+description: redeclaration with GeneratorDeclaration (AsyncGeneratorDeclaration in BlockStatement)
+esid: sec-block-static-semantics-early-errors
+features: [generators, async-iteration]
+flags: [generated]
+negative:
+ phase: parse
+ type: SyntaxError
+info: |
+ Block : { StatementList }
+
+ It is a Syntax Error if the LexicallyDeclaredNames of StatementList contains
+ any duplicate entries.
+
+---*/
+
+
+$DONOTEVALUATE();
+
+{ async function* f() {} function* f() {} }
diff --git a/js/src/tests/test262/language/block-scope/syntax/redeclaration/async-generator-name-redeclaration-attempt-with-let.js b/js/src/tests/test262/language/block-scope/syntax/redeclaration/async-generator-name-redeclaration-attempt-with-let.js
new file mode 100644
index 0000000000..8704f96a24
--- /dev/null
+++ b/js/src/tests/test262/language/block-scope/syntax/redeclaration/async-generator-name-redeclaration-attempt-with-let.js
@@ -0,0 +1,24 @@
+// |reftest| error:SyntaxError
+// This file was procedurally generated from the following sources:
+// - src/declarations/let.case
+// - src/declarations/redeclare/block-attempt-to-redeclare-async-generator-declaration.template
+/*---
+description: redeclaration with let-LexicalDeclaration (AsyncGeneratorDeclaration in BlockStatement)
+esid: sec-block-static-semantics-early-errors
+features: [async-iteration]
+flags: [generated]
+negative:
+ phase: parse
+ type: SyntaxError
+info: |
+ Block : { StatementList }
+
+ It is a Syntax Error if the LexicallyDeclaredNames of StatementList contains
+ any duplicate entries.
+
+---*/
+
+
+$DONOTEVALUATE();
+
+{ async function* f() {} let f }
diff --git a/js/src/tests/test262/language/block-scope/syntax/redeclaration/async-generator-name-redeclaration-attempt-with-var.js b/js/src/tests/test262/language/block-scope/syntax/redeclaration/async-generator-name-redeclaration-attempt-with-var.js
new file mode 100644
index 0000000000..50011a54f4
--- /dev/null
+++ b/js/src/tests/test262/language/block-scope/syntax/redeclaration/async-generator-name-redeclaration-attempt-with-var.js
@@ -0,0 +1,24 @@
+// |reftest| error:SyntaxError
+// This file was procedurally generated from the following sources:
+// - src/declarations/var.case
+// - src/declarations/redeclare-allow-var/block-attempt-to-redeclare-async-generator-declaration.template
+/*---
+description: redeclaration with VariableDeclaration (AsyncGeneratorDeclaration in BlockStatement)
+esid: sec-block-static-semantics-early-errors
+features: [async-iteration]
+flags: [generated]
+negative:
+ phase: parse
+ type: SyntaxError
+info: |
+ Block : { StatementList }
+
+ It is a Syntax Error if any element of the LexicallyDeclaredNames of
+ StatementList also occurs in the VarDeclaredNames of StatementList.
+
+---*/
+
+
+$DONOTEVALUATE();
+
+{ async function* f() {} var f }
diff --git a/js/src/tests/test262/language/block-scope/syntax/redeclaration/browser.js b/js/src/tests/test262/language/block-scope/syntax/redeclaration/browser.js
new file mode 100644
index 0000000000..e69de29bb2
--- /dev/null
+++ b/js/src/tests/test262/language/block-scope/syntax/redeclaration/browser.js
diff --git a/js/src/tests/test262/language/block-scope/syntax/redeclaration/class-name-redeclaration-attempt-with-async-function.js b/js/src/tests/test262/language/block-scope/syntax/redeclaration/class-name-redeclaration-attempt-with-async-function.js
new file mode 100644
index 0000000000..af383c677c
--- /dev/null
+++ b/js/src/tests/test262/language/block-scope/syntax/redeclaration/class-name-redeclaration-attempt-with-async-function.js
@@ -0,0 +1,24 @@
+// |reftest| error:SyntaxError
+// This file was procedurally generated from the following sources:
+// - src/declarations/async-function.case
+// - src/declarations/redeclare/block-attempt-to-redeclare-class-declaration.template
+/*---
+description: redeclaration with AsyncFunctionDeclaration (ClassDeclaration in BlockStatement)
+esid: sec-block-static-semantics-early-errors
+features: [async-functions]
+flags: [generated]
+negative:
+ phase: parse
+ type: SyntaxError
+info: |
+ Block : { StatementList }
+
+ It is a Syntax Error if the LexicallyDeclaredNames of StatementList contains
+ any duplicate entries.
+
+---*/
+
+
+$DONOTEVALUATE();
+
+{ class f {} async function f() {} }
diff --git a/js/src/tests/test262/language/block-scope/syntax/redeclaration/class-name-redeclaration-attempt-with-async-generator.js b/js/src/tests/test262/language/block-scope/syntax/redeclaration/class-name-redeclaration-attempt-with-async-generator.js
new file mode 100644
index 0000000000..89127b7a0e
--- /dev/null
+++ b/js/src/tests/test262/language/block-scope/syntax/redeclaration/class-name-redeclaration-attempt-with-async-generator.js
@@ -0,0 +1,24 @@
+// |reftest| error:SyntaxError
+// This file was procedurally generated from the following sources:
+// - src/declarations/async-generator.case
+// - src/declarations/redeclare/block-attempt-to-redeclare-class-declaration.template
+/*---
+description: redeclaration with AsyncGeneratorDeclaration (ClassDeclaration in BlockStatement)
+esid: sec-block-static-semantics-early-errors
+features: [async-iteration]
+flags: [generated]
+negative:
+ phase: parse
+ type: SyntaxError
+info: |
+ Block : { StatementList }
+
+ It is a Syntax Error if the LexicallyDeclaredNames of StatementList contains
+ any duplicate entries.
+
+---*/
+
+
+$DONOTEVALUATE();
+
+{ class f {} async function* f() {} }
diff --git a/js/src/tests/test262/language/block-scope/syntax/redeclaration/class-name-redeclaration-attempt-with-class.js b/js/src/tests/test262/language/block-scope/syntax/redeclaration/class-name-redeclaration-attempt-with-class.js
new file mode 100644
index 0000000000..d7750c679d
--- /dev/null
+++ b/js/src/tests/test262/language/block-scope/syntax/redeclaration/class-name-redeclaration-attempt-with-class.js
@@ -0,0 +1,23 @@
+// |reftest| error:SyntaxError
+// This file was procedurally generated from the following sources:
+// - src/declarations/class.case
+// - src/declarations/redeclare/block-attempt-to-redeclare-class-declaration.template
+/*---
+description: redeclaration with ClassDeclaration (ClassDeclaration in BlockStatement)
+esid: sec-block-static-semantics-early-errors
+flags: [generated]
+negative:
+ phase: parse
+ type: SyntaxError
+info: |
+ Block : { StatementList }
+
+ It is a Syntax Error if the LexicallyDeclaredNames of StatementList contains
+ any duplicate entries.
+
+---*/
+
+
+$DONOTEVALUATE();
+
+{ class f {} class f {} }
diff --git a/js/src/tests/test262/language/block-scope/syntax/redeclaration/class-name-redeclaration-attempt-with-const.js b/js/src/tests/test262/language/block-scope/syntax/redeclaration/class-name-redeclaration-attempt-with-const.js
new file mode 100644
index 0000000000..2a170d5ba9
--- /dev/null
+++ b/js/src/tests/test262/language/block-scope/syntax/redeclaration/class-name-redeclaration-attempt-with-const.js
@@ -0,0 +1,23 @@
+// |reftest| error:SyntaxError
+// This file was procedurally generated from the following sources:
+// - src/declarations/const.case
+// - src/declarations/redeclare/block-attempt-to-redeclare-class-declaration.template
+/*---
+description: redeclaration with const-LexicalDeclaration (ClassDeclaration in BlockStatement)
+esid: sec-block-static-semantics-early-errors
+flags: [generated]
+negative:
+ phase: parse
+ type: SyntaxError
+info: |
+ Block : { StatementList }
+
+ It is a Syntax Error if the LexicallyDeclaredNames of StatementList contains
+ any duplicate entries.
+
+---*/
+
+
+$DONOTEVALUATE();
+
+{ class f {} const f = 0 }
diff --git a/js/src/tests/test262/language/block-scope/syntax/redeclaration/class-name-redeclaration-attempt-with-function.js b/js/src/tests/test262/language/block-scope/syntax/redeclaration/class-name-redeclaration-attempt-with-function.js
new file mode 100644
index 0000000000..6d18ab875d
--- /dev/null
+++ b/js/src/tests/test262/language/block-scope/syntax/redeclaration/class-name-redeclaration-attempt-with-function.js
@@ -0,0 +1,23 @@
+// |reftest| error:SyntaxError
+// This file was procedurally generated from the following sources:
+// - src/declarations/function.case
+// - src/declarations/redeclare-allow-sloppy-function/block-attempt-to-redeclare-class-declaration.template
+/*---
+description: redeclaration with FunctionDeclaration (ClassDeclaration in BlockStatement)
+esid: sec-block-static-semantics-early-errors
+flags: [generated]
+negative:
+ phase: parse
+ type: SyntaxError
+info: |
+ Block : { StatementList }
+
+ It is a Syntax Error if the LexicallyDeclaredNames of StatementList contains
+ any duplicate entries.
+
+---*/
+
+
+$DONOTEVALUATE();
+
+{ class f {} function f() {} }
diff --git a/js/src/tests/test262/language/block-scope/syntax/redeclaration/class-name-redeclaration-attempt-with-generator.js b/js/src/tests/test262/language/block-scope/syntax/redeclaration/class-name-redeclaration-attempt-with-generator.js
new file mode 100644
index 0000000000..8707b6397e
--- /dev/null
+++ b/js/src/tests/test262/language/block-scope/syntax/redeclaration/class-name-redeclaration-attempt-with-generator.js
@@ -0,0 +1,24 @@
+// |reftest| error:SyntaxError
+// This file was procedurally generated from the following sources:
+// - src/declarations/generator.case
+// - src/declarations/redeclare/block-attempt-to-redeclare-class-declaration.template
+/*---
+description: redeclaration with GeneratorDeclaration (ClassDeclaration in BlockStatement)
+esid: sec-block-static-semantics-early-errors
+features: [generators]
+flags: [generated]
+negative:
+ phase: parse
+ type: SyntaxError
+info: |
+ Block : { StatementList }
+
+ It is a Syntax Error if the LexicallyDeclaredNames of StatementList contains
+ any duplicate entries.
+
+---*/
+
+
+$DONOTEVALUATE();
+
+{ class f {} function* f() {} }
diff --git a/js/src/tests/test262/language/block-scope/syntax/redeclaration/class-name-redeclaration-attempt-with-let.js b/js/src/tests/test262/language/block-scope/syntax/redeclaration/class-name-redeclaration-attempt-with-let.js
new file mode 100644
index 0000000000..0d497ceada
--- /dev/null
+++ b/js/src/tests/test262/language/block-scope/syntax/redeclaration/class-name-redeclaration-attempt-with-let.js
@@ -0,0 +1,23 @@
+// |reftest| error:SyntaxError
+// This file was procedurally generated from the following sources:
+// - src/declarations/let.case
+// - src/declarations/redeclare/block-attempt-to-redeclare-class-declaration.template
+/*---
+description: redeclaration with let-LexicalDeclaration (ClassDeclaration in BlockStatement)
+esid: sec-block-static-semantics-early-errors
+flags: [generated]
+negative:
+ phase: parse
+ type: SyntaxError
+info: |
+ Block : { StatementList }
+
+ It is a Syntax Error if the LexicallyDeclaredNames of StatementList contains
+ any duplicate entries.
+
+---*/
+
+
+$DONOTEVALUATE();
+
+{ class f {} let f }
diff --git a/js/src/tests/test262/language/block-scope/syntax/redeclaration/class-name-redeclaration-attempt-with-var.js b/js/src/tests/test262/language/block-scope/syntax/redeclaration/class-name-redeclaration-attempt-with-var.js
new file mode 100644
index 0000000000..bff3e380a6
--- /dev/null
+++ b/js/src/tests/test262/language/block-scope/syntax/redeclaration/class-name-redeclaration-attempt-with-var.js
@@ -0,0 +1,23 @@
+// |reftest| error:SyntaxError
+// This file was procedurally generated from the following sources:
+// - src/declarations/var.case
+// - src/declarations/redeclare-allow-var/block-attempt-to-redeclare-class-declaration.template
+/*---
+description: redeclaration with VariableDeclaration (ClassDeclaration in BlockStatement)
+esid: sec-block-static-semantics-early-errors
+flags: [generated]
+negative:
+ phase: parse
+ type: SyntaxError
+info: |
+ Block : { StatementList }
+
+ It is a Syntax Error if any element of the LexicallyDeclaredNames of
+ StatementList also occurs in the VarDeclaredNames of StatementList.
+
+---*/
+
+
+$DONOTEVALUATE();
+
+{ class f {} var f }
diff --git a/js/src/tests/test262/language/block-scope/syntax/redeclaration/const-name-redeclaration-attempt-with-async-function.js b/js/src/tests/test262/language/block-scope/syntax/redeclaration/const-name-redeclaration-attempt-with-async-function.js
new file mode 100644
index 0000000000..be6f6d7470
--- /dev/null
+++ b/js/src/tests/test262/language/block-scope/syntax/redeclaration/const-name-redeclaration-attempt-with-async-function.js
@@ -0,0 +1,24 @@
+// |reftest| error:SyntaxError
+// This file was procedurally generated from the following sources:
+// - src/declarations/async-function.case
+// - src/declarations/redeclare/block-attempt-to-redeclare-const-declaration.template
+/*---
+description: redeclaration with AsyncFunctionDeclaration (LexicalDeclaration (const) in BlockStatement)
+esid: sec-block-static-semantics-early-errors
+features: [async-functions]
+flags: [generated]
+negative:
+ phase: parse
+ type: SyntaxError
+info: |
+ Block : { StatementList }
+
+ It is a Syntax Error if the LexicallyDeclaredNames of StatementList contains
+ any duplicate entries.
+
+---*/
+
+
+$DONOTEVALUATE();
+
+{ const f = 0; async function f() {} }
diff --git a/js/src/tests/test262/language/block-scope/syntax/redeclaration/const-name-redeclaration-attempt-with-async-generator.js b/js/src/tests/test262/language/block-scope/syntax/redeclaration/const-name-redeclaration-attempt-with-async-generator.js
new file mode 100644
index 0000000000..72c84df655
--- /dev/null
+++ b/js/src/tests/test262/language/block-scope/syntax/redeclaration/const-name-redeclaration-attempt-with-async-generator.js
@@ -0,0 +1,24 @@
+// |reftest| error:SyntaxError
+// This file was procedurally generated from the following sources:
+// - src/declarations/async-generator.case
+// - src/declarations/redeclare/block-attempt-to-redeclare-const-declaration.template
+/*---
+description: redeclaration with AsyncGeneratorDeclaration (LexicalDeclaration (const) in BlockStatement)
+esid: sec-block-static-semantics-early-errors
+features: [async-iteration]
+flags: [generated]
+negative:
+ phase: parse
+ type: SyntaxError
+info: |
+ Block : { StatementList }
+
+ It is a Syntax Error if the LexicallyDeclaredNames of StatementList contains
+ any duplicate entries.
+
+---*/
+
+
+$DONOTEVALUATE();
+
+{ const f = 0; async function* f() {} }
diff --git a/js/src/tests/test262/language/block-scope/syntax/redeclaration/const-name-redeclaration-attempt-with-class.js b/js/src/tests/test262/language/block-scope/syntax/redeclaration/const-name-redeclaration-attempt-with-class.js
new file mode 100644
index 0000000000..9bfda25bfc
--- /dev/null
+++ b/js/src/tests/test262/language/block-scope/syntax/redeclaration/const-name-redeclaration-attempt-with-class.js
@@ -0,0 +1,23 @@
+// |reftest| error:SyntaxError
+// This file was procedurally generated from the following sources:
+// - src/declarations/class.case
+// - src/declarations/redeclare/block-attempt-to-redeclare-const-declaration.template
+/*---
+description: redeclaration with ClassDeclaration (LexicalDeclaration (const) in BlockStatement)
+esid: sec-block-static-semantics-early-errors
+flags: [generated]
+negative:
+ phase: parse
+ type: SyntaxError
+info: |
+ Block : { StatementList }
+
+ It is a Syntax Error if the LexicallyDeclaredNames of StatementList contains
+ any duplicate entries.
+
+---*/
+
+
+$DONOTEVALUATE();
+
+{ const f = 0; class f {} }
diff --git a/js/src/tests/test262/language/block-scope/syntax/redeclaration/const-name-redeclaration-attempt-with-const.js b/js/src/tests/test262/language/block-scope/syntax/redeclaration/const-name-redeclaration-attempt-with-const.js
new file mode 100644
index 0000000000..7735c597b1
--- /dev/null
+++ b/js/src/tests/test262/language/block-scope/syntax/redeclaration/const-name-redeclaration-attempt-with-const.js
@@ -0,0 +1,23 @@
+// |reftest| error:SyntaxError
+// This file was procedurally generated from the following sources:
+// - src/declarations/const.case
+// - src/declarations/redeclare/block-attempt-to-redeclare-const-declaration.template
+/*---
+description: redeclaration with const-LexicalDeclaration (LexicalDeclaration (const) in BlockStatement)
+esid: sec-block-static-semantics-early-errors
+flags: [generated]
+negative:
+ phase: parse
+ type: SyntaxError
+info: |
+ Block : { StatementList }
+
+ It is a Syntax Error if the LexicallyDeclaredNames of StatementList contains
+ any duplicate entries.
+
+---*/
+
+
+$DONOTEVALUATE();
+
+{ const f = 0; const f = 0 }
diff --git a/js/src/tests/test262/language/block-scope/syntax/redeclaration/const-name-redeclaration-attempt-with-function.js b/js/src/tests/test262/language/block-scope/syntax/redeclaration/const-name-redeclaration-attempt-with-function.js
new file mode 100644
index 0000000000..6bf53adcdc
--- /dev/null
+++ b/js/src/tests/test262/language/block-scope/syntax/redeclaration/const-name-redeclaration-attempt-with-function.js
@@ -0,0 +1,23 @@
+// |reftest| error:SyntaxError
+// This file was procedurally generated from the following sources:
+// - src/declarations/function.case
+// - src/declarations/redeclare-allow-sloppy-function/block-attempt-to-redeclare-const-declaration.template
+/*---
+description: redeclaration with FunctionDeclaration (LexicalDeclaration (const) in BlockStatement)
+esid: sec-block-static-semantics-early-errors
+flags: [generated]
+negative:
+ phase: parse
+ type: SyntaxError
+info: |
+ Block : { StatementList }
+
+ It is a Syntax Error if the LexicallyDeclaredNames of StatementList contains
+ any duplicate entries.
+
+---*/
+
+
+$DONOTEVALUATE();
+
+{ const f = 0; function f() {} }
diff --git a/js/src/tests/test262/language/block-scope/syntax/redeclaration/const-name-redeclaration-attempt-with-generator.js b/js/src/tests/test262/language/block-scope/syntax/redeclaration/const-name-redeclaration-attempt-with-generator.js
new file mode 100644
index 0000000000..68a8db29c8
--- /dev/null
+++ b/js/src/tests/test262/language/block-scope/syntax/redeclaration/const-name-redeclaration-attempt-with-generator.js
@@ -0,0 +1,24 @@
+// |reftest| error:SyntaxError
+// This file was procedurally generated from the following sources:
+// - src/declarations/generator.case
+// - src/declarations/redeclare/block-attempt-to-redeclare-const-declaration.template
+/*---
+description: redeclaration with GeneratorDeclaration (LexicalDeclaration (const) in BlockStatement)
+esid: sec-block-static-semantics-early-errors
+features: [generators]
+flags: [generated]
+negative:
+ phase: parse
+ type: SyntaxError
+info: |
+ Block : { StatementList }
+
+ It is a Syntax Error if the LexicallyDeclaredNames of StatementList contains
+ any duplicate entries.
+
+---*/
+
+
+$DONOTEVALUATE();
+
+{ const f = 0; function* f() {} }
diff --git a/js/src/tests/test262/language/block-scope/syntax/redeclaration/const-name-redeclaration-attempt-with-let.js b/js/src/tests/test262/language/block-scope/syntax/redeclaration/const-name-redeclaration-attempt-with-let.js
new file mode 100644
index 0000000000..d531c94df7
--- /dev/null
+++ b/js/src/tests/test262/language/block-scope/syntax/redeclaration/const-name-redeclaration-attempt-with-let.js
@@ -0,0 +1,23 @@
+// |reftest| error:SyntaxError
+// This file was procedurally generated from the following sources:
+// - src/declarations/let.case
+// - src/declarations/redeclare/block-attempt-to-redeclare-const-declaration.template
+/*---
+description: redeclaration with let-LexicalDeclaration (LexicalDeclaration (const) in BlockStatement)
+esid: sec-block-static-semantics-early-errors
+flags: [generated]
+negative:
+ phase: parse
+ type: SyntaxError
+info: |
+ Block : { StatementList }
+
+ It is a Syntax Error if the LexicallyDeclaredNames of StatementList contains
+ any duplicate entries.
+
+---*/
+
+
+$DONOTEVALUATE();
+
+{ const f = 0; let f }
diff --git a/js/src/tests/test262/language/block-scope/syntax/redeclaration/const-name-redeclaration-attempt-with-var.js b/js/src/tests/test262/language/block-scope/syntax/redeclaration/const-name-redeclaration-attempt-with-var.js
new file mode 100644
index 0000000000..ffd66089ae
--- /dev/null
+++ b/js/src/tests/test262/language/block-scope/syntax/redeclaration/const-name-redeclaration-attempt-with-var.js
@@ -0,0 +1,23 @@
+// |reftest| error:SyntaxError
+// This file was procedurally generated from the following sources:
+// - src/declarations/var.case
+// - src/declarations/redeclare-allow-var/block-attempt-to-redeclare-const-declaration.template
+/*---
+description: redeclaration with VariableDeclaration (LexicalDeclaration (const) in BlockStatement)
+esid: sec-block-static-semantics-early-errors
+flags: [generated]
+negative:
+ phase: parse
+ type: SyntaxError
+info: |
+ Block : { StatementList }
+
+ It is a Syntax Error if any element of the LexicallyDeclaredNames of
+ StatementList also occurs in the VarDeclaredNames of StatementList.
+
+---*/
+
+
+$DONOTEVALUATE();
+
+{ const f = 0; var f }
diff --git a/js/src/tests/test262/language/block-scope/syntax/redeclaration/fn-scope-var-name-redeclaration-attempt-with-async-function.js b/js/src/tests/test262/language/block-scope/syntax/redeclaration/fn-scope-var-name-redeclaration-attempt-with-async-function.js
new file mode 100644
index 0000000000..5ce0b8096f
--- /dev/null
+++ b/js/src/tests/test262/language/block-scope/syntax/redeclaration/fn-scope-var-name-redeclaration-attempt-with-async-function.js
@@ -0,0 +1,26 @@
+// |reftest| error:SyntaxError
+// This file was procedurally generated from the following sources:
+// - src/declarations/async-function.case
+// - src/declarations/redeclare/fn-block-attempt-to-redeclare-var-declaration.template
+/*---
+description: redeclaration with AsyncFunctionDeclaration (VariableDeclaration in BlockStatement inside a function)
+esid: sec-block-static-semantics-early-errors
+features: [async-functions]
+flags: [generated]
+negative:
+ phase: parse
+ type: SyntaxError
+info: |
+ Block : { StatementList }
+
+ It is a Syntax Error if any element of the LexicallyDeclaredNames of
+ StatementList also occurs in the VarDeclaredNames of StatementList.
+
+---*/
+
+
+$DONOTEVALUATE();
+
+function x() {
+ { async function f() {}; var f; }
+}
diff --git a/js/src/tests/test262/language/block-scope/syntax/redeclaration/fn-scope-var-name-redeclaration-attempt-with-async-generator.js b/js/src/tests/test262/language/block-scope/syntax/redeclaration/fn-scope-var-name-redeclaration-attempt-with-async-generator.js
new file mode 100644
index 0000000000..13a398f6fe
--- /dev/null
+++ b/js/src/tests/test262/language/block-scope/syntax/redeclaration/fn-scope-var-name-redeclaration-attempt-with-async-generator.js
@@ -0,0 +1,26 @@
+// |reftest| error:SyntaxError
+// This file was procedurally generated from the following sources:
+// - src/declarations/async-generator.case
+// - src/declarations/redeclare/fn-block-attempt-to-redeclare-var-declaration.template
+/*---
+description: redeclaration with AsyncGeneratorDeclaration (VariableDeclaration in BlockStatement inside a function)
+esid: sec-block-static-semantics-early-errors
+features: [async-iteration]
+flags: [generated]
+negative:
+ phase: parse
+ type: SyntaxError
+info: |
+ Block : { StatementList }
+
+ It is a Syntax Error if any element of the LexicallyDeclaredNames of
+ StatementList also occurs in the VarDeclaredNames of StatementList.
+
+---*/
+
+
+$DONOTEVALUATE();
+
+function x() {
+ { async function* f() {}; var f; }
+}
diff --git a/js/src/tests/test262/language/block-scope/syntax/redeclaration/fn-scope-var-name-redeclaration-attempt-with-class.js b/js/src/tests/test262/language/block-scope/syntax/redeclaration/fn-scope-var-name-redeclaration-attempt-with-class.js
new file mode 100644
index 0000000000..3504d76bfb
--- /dev/null
+++ b/js/src/tests/test262/language/block-scope/syntax/redeclaration/fn-scope-var-name-redeclaration-attempt-with-class.js
@@ -0,0 +1,25 @@
+// |reftest| error:SyntaxError
+// This file was procedurally generated from the following sources:
+// - src/declarations/class.case
+// - src/declarations/redeclare/fn-block-attempt-to-redeclare-var-declaration.template
+/*---
+description: redeclaration with ClassDeclaration (VariableDeclaration in BlockStatement inside a function)
+esid: sec-block-static-semantics-early-errors
+flags: [generated]
+negative:
+ phase: parse
+ type: SyntaxError
+info: |
+ Block : { StatementList }
+
+ It is a Syntax Error if any element of the LexicallyDeclaredNames of
+ StatementList also occurs in the VarDeclaredNames of StatementList.
+
+---*/
+
+
+$DONOTEVALUATE();
+
+function x() {
+ { class f {}; var f; }
+}
diff --git a/js/src/tests/test262/language/block-scope/syntax/redeclaration/fn-scope-var-name-redeclaration-attempt-with-const.js b/js/src/tests/test262/language/block-scope/syntax/redeclaration/fn-scope-var-name-redeclaration-attempt-with-const.js
new file mode 100644
index 0000000000..b6fc7ff7bc
--- /dev/null
+++ b/js/src/tests/test262/language/block-scope/syntax/redeclaration/fn-scope-var-name-redeclaration-attempt-with-const.js
@@ -0,0 +1,25 @@
+// |reftest| error:SyntaxError
+// This file was procedurally generated from the following sources:
+// - src/declarations/const.case
+// - src/declarations/redeclare/fn-block-attempt-to-redeclare-var-declaration.template
+/*---
+description: redeclaration with const-LexicalDeclaration (VariableDeclaration in BlockStatement inside a function)
+esid: sec-block-static-semantics-early-errors
+flags: [generated]
+negative:
+ phase: parse
+ type: SyntaxError
+info: |
+ Block : { StatementList }
+
+ It is a Syntax Error if any element of the LexicallyDeclaredNames of
+ StatementList also occurs in the VarDeclaredNames of StatementList.
+
+---*/
+
+
+$DONOTEVALUATE();
+
+function x() {
+ { const f = 0; var f; }
+}
diff --git a/js/src/tests/test262/language/block-scope/syntax/redeclaration/fn-scope-var-name-redeclaration-attempt-with-function.js b/js/src/tests/test262/language/block-scope/syntax/redeclaration/fn-scope-var-name-redeclaration-attempt-with-function.js
new file mode 100644
index 0000000000..00d1a1427d
--- /dev/null
+++ b/js/src/tests/test262/language/block-scope/syntax/redeclaration/fn-scope-var-name-redeclaration-attempt-with-function.js
@@ -0,0 +1,25 @@
+// |reftest| error:SyntaxError
+// This file was procedurally generated from the following sources:
+// - src/declarations/function.case
+// - src/declarations/redeclare-allow-sloppy-function/fn-block-attempt-to-redeclare-var-declaration.template
+/*---
+description: redeclaration with FunctionDeclaration (VariableDeclaration in BlockStatement inside a function)
+esid: sec-block-static-semantics-early-errors
+flags: [generated]
+negative:
+ phase: parse
+ type: SyntaxError
+info: |
+ Block : { StatementList }
+
+ It is a Syntax Error if any element of the LexicallyDeclaredNames of
+ StatementList also occurs in the VarDeclaredNames of StatementList.
+
+---*/
+
+
+$DONOTEVALUATE();
+
+function x() {
+ { function f() {}; var f; }
+}
diff --git a/js/src/tests/test262/language/block-scope/syntax/redeclaration/fn-scope-var-name-redeclaration-attempt-with-generator.js b/js/src/tests/test262/language/block-scope/syntax/redeclaration/fn-scope-var-name-redeclaration-attempt-with-generator.js
new file mode 100644
index 0000000000..54e206c3aa
--- /dev/null
+++ b/js/src/tests/test262/language/block-scope/syntax/redeclaration/fn-scope-var-name-redeclaration-attempt-with-generator.js
@@ -0,0 +1,26 @@
+// |reftest| error:SyntaxError
+// This file was procedurally generated from the following sources:
+// - src/declarations/generator.case
+// - src/declarations/redeclare/fn-block-attempt-to-redeclare-var-declaration.template
+/*---
+description: redeclaration with GeneratorDeclaration (VariableDeclaration in BlockStatement inside a function)
+esid: sec-block-static-semantics-early-errors
+features: [generators]
+flags: [generated]
+negative:
+ phase: parse
+ type: SyntaxError
+info: |
+ Block : { StatementList }
+
+ It is a Syntax Error if any element of the LexicallyDeclaredNames of
+ StatementList also occurs in the VarDeclaredNames of StatementList.
+
+---*/
+
+
+$DONOTEVALUATE();
+
+function x() {
+ { function* f() {}; var f; }
+}
diff --git a/js/src/tests/test262/language/block-scope/syntax/redeclaration/fn-scope-var-name-redeclaration-attempt-with-let.js b/js/src/tests/test262/language/block-scope/syntax/redeclaration/fn-scope-var-name-redeclaration-attempt-with-let.js
new file mode 100644
index 0000000000..f75f2d3d92
--- /dev/null
+++ b/js/src/tests/test262/language/block-scope/syntax/redeclaration/fn-scope-var-name-redeclaration-attempt-with-let.js
@@ -0,0 +1,25 @@
+// |reftest| error:SyntaxError
+// This file was procedurally generated from the following sources:
+// - src/declarations/let.case
+// - src/declarations/redeclare/fn-block-attempt-to-redeclare-var-declaration.template
+/*---
+description: redeclaration with let-LexicalDeclaration (VariableDeclaration in BlockStatement inside a function)
+esid: sec-block-static-semantics-early-errors
+flags: [generated]
+negative:
+ phase: parse
+ type: SyntaxError
+info: |
+ Block : { StatementList }
+
+ It is a Syntax Error if any element of the LexicallyDeclaredNames of
+ StatementList also occurs in the VarDeclaredNames of StatementList.
+
+---*/
+
+
+$DONOTEVALUATE();
+
+function x() {
+ { let f; var f; }
+}
diff --git a/js/src/tests/test262/language/block-scope/syntax/redeclaration/fn-scope-var-name-redeclaration-attempt-with-var.js b/js/src/tests/test262/language/block-scope/syntax/redeclaration/fn-scope-var-name-redeclaration-attempt-with-var.js
new file mode 100644
index 0000000000..2ad1fd58eb
--- /dev/null
+++ b/js/src/tests/test262/language/block-scope/syntax/redeclaration/fn-scope-var-name-redeclaration-attempt-with-var.js
@@ -0,0 +1,20 @@
+// This file was procedurally generated from the following sources:
+// - src/declarations/var.case
+// - src/declarations/redeclare-allow-var/fn-block-attempt-to-redeclare-var-declaration.template
+/*---
+description: redeclaration with VariableDeclaration (VariableDeclaration in BlockStatement inside a function)
+esid: sec-block-static-semantics-early-errors
+flags: [generated]
+info: |
+ Block : { StatementList }
+
+ It is a Syntax Error if any element of the LexicallyDeclaredNames of
+ StatementList also occurs in the VarDeclaredNames of StatementList.
+---*/
+
+
+function x() {
+ { var f; var f }
+}
+
+reportCompare(0, 0);
diff --git a/js/src/tests/test262/language/block-scope/syntax/redeclaration/function-declaration-attempt-to-redeclare-with-var-declaration-nested-in-function.js b/js/src/tests/test262/language/block-scope/syntax/redeclaration/function-declaration-attempt-to-redeclare-with-var-declaration-nested-in-function.js
new file mode 100644
index 0000000000..3c72d3aeb1
--- /dev/null
+++ b/js/src/tests/test262/language/block-scope/syntax/redeclaration/function-declaration-attempt-to-redeclare-with-var-declaration-nested-in-function.js
@@ -0,0 +1,32 @@
+// |reftest| error:SyntaxError
+// Copyright (C) 2018 André Bargull. All rights reserved.
+// This code is governed by the BSD license found in the LICENSE file.
+
+/*---
+esid: sec-block-static-semantics-early-errors
+description: >
+ Redeclaration with VariableDeclaration (FunctionDeclaration in BlockStatement)
+info: |
+ 13.2.1 Static Semantics: Early Errors
+
+ It is a Syntax Error if any element of the LexicallyDeclaredNames of
+ StatementList also occurs in the VarDeclaredNames of StatementList.
+negative:
+ phase: parse
+ type: SyntaxError
+---*/
+
+$DONOTEVALUATE();
+
+function g() {
+ // Create an outer block-statement.
+ {
+ // A lexically declared function declaration.
+ function f() {}
+
+ // An inner block-statement with a variable-declared name.
+ {
+ var f;
+ }
+ }
+}
diff --git a/js/src/tests/test262/language/block-scope/syntax/redeclaration/function-name-redeclaration-attempt-with-async-function.js b/js/src/tests/test262/language/block-scope/syntax/redeclaration/function-name-redeclaration-attempt-with-async-function.js
new file mode 100644
index 0000000000..e96e49fcb5
--- /dev/null
+++ b/js/src/tests/test262/language/block-scope/syntax/redeclaration/function-name-redeclaration-attempt-with-async-function.js
@@ -0,0 +1,24 @@
+// |reftest| error:SyntaxError
+// This file was procedurally generated from the following sources:
+// - src/declarations/async-function.case
+// - src/declarations/redeclare/block-attempt-to-redeclare-function-declaration.template
+/*---
+description: redeclaration with AsyncFunctionDeclaration (FunctionDeclaration in BlockStatement)
+esid: sec-block-static-semantics-early-errors
+features: [async-functions]
+flags: [generated]
+negative:
+ phase: parse
+ type: SyntaxError
+info: |
+ Block : { StatementList }
+
+ It is a Syntax Error if the LexicallyDeclaredNames of StatementList contains
+ any duplicate entries.
+
+---*/
+
+
+$DONOTEVALUATE();
+
+{ function f() {} async function f() {} }
diff --git a/js/src/tests/test262/language/block-scope/syntax/redeclaration/function-name-redeclaration-attempt-with-async-generator.js b/js/src/tests/test262/language/block-scope/syntax/redeclaration/function-name-redeclaration-attempt-with-async-generator.js
new file mode 100644
index 0000000000..ffd109e6d0
--- /dev/null
+++ b/js/src/tests/test262/language/block-scope/syntax/redeclaration/function-name-redeclaration-attempt-with-async-generator.js
@@ -0,0 +1,24 @@
+// |reftest| error:SyntaxError
+// This file was procedurally generated from the following sources:
+// - src/declarations/async-generator.case
+// - src/declarations/redeclare/block-attempt-to-redeclare-function-declaration.template
+/*---
+description: redeclaration with AsyncGeneratorDeclaration (FunctionDeclaration in BlockStatement)
+esid: sec-block-static-semantics-early-errors
+features: [async-iteration]
+flags: [generated]
+negative:
+ phase: parse
+ type: SyntaxError
+info: |
+ Block : { StatementList }
+
+ It is a Syntax Error if the LexicallyDeclaredNames of StatementList contains
+ any duplicate entries.
+
+---*/
+
+
+$DONOTEVALUATE();
+
+{ function f() {} async function* f() {} }
diff --git a/js/src/tests/test262/language/block-scope/syntax/redeclaration/function-name-redeclaration-attempt-with-class.js b/js/src/tests/test262/language/block-scope/syntax/redeclaration/function-name-redeclaration-attempt-with-class.js
new file mode 100644
index 0000000000..6bdeb6dceb
--- /dev/null
+++ b/js/src/tests/test262/language/block-scope/syntax/redeclaration/function-name-redeclaration-attempt-with-class.js
@@ -0,0 +1,23 @@
+// |reftest| error:SyntaxError
+// This file was procedurally generated from the following sources:
+// - src/declarations/class.case
+// - src/declarations/redeclare/block-attempt-to-redeclare-function-declaration.template
+/*---
+description: redeclaration with ClassDeclaration (FunctionDeclaration in BlockStatement)
+esid: sec-block-static-semantics-early-errors
+flags: [generated]
+negative:
+ phase: parse
+ type: SyntaxError
+info: |
+ Block : { StatementList }
+
+ It is a Syntax Error if the LexicallyDeclaredNames of StatementList contains
+ any duplicate entries.
+
+---*/
+
+
+$DONOTEVALUATE();
+
+{ function f() {} class f {} }
diff --git a/js/src/tests/test262/language/block-scope/syntax/redeclaration/function-name-redeclaration-attempt-with-const.js b/js/src/tests/test262/language/block-scope/syntax/redeclaration/function-name-redeclaration-attempt-with-const.js
new file mode 100644
index 0000000000..6f0622cf5a
--- /dev/null
+++ b/js/src/tests/test262/language/block-scope/syntax/redeclaration/function-name-redeclaration-attempt-with-const.js
@@ -0,0 +1,23 @@
+// |reftest| error:SyntaxError
+// This file was procedurally generated from the following sources:
+// - src/declarations/const.case
+// - src/declarations/redeclare/block-attempt-to-redeclare-function-declaration.template
+/*---
+description: redeclaration with const-LexicalDeclaration (FunctionDeclaration in BlockStatement)
+esid: sec-block-static-semantics-early-errors
+flags: [generated]
+negative:
+ phase: parse
+ type: SyntaxError
+info: |
+ Block : { StatementList }
+
+ It is a Syntax Error if the LexicallyDeclaredNames of StatementList contains
+ any duplicate entries.
+
+---*/
+
+
+$DONOTEVALUATE();
+
+{ function f() {} const f = 0 }
diff --git a/js/src/tests/test262/language/block-scope/syntax/redeclaration/function-name-redeclaration-attempt-with-function-strict.js b/js/src/tests/test262/language/block-scope/syntax/redeclaration/function-name-redeclaration-attempt-with-function-strict.js
new file mode 100644
index 0000000000..de89b4b02b
--- /dev/null
+++ b/js/src/tests/test262/language/block-scope/syntax/redeclaration/function-name-redeclaration-attempt-with-function-strict.js
@@ -0,0 +1,24 @@
+// |reftest| error:SyntaxError
+'use strict';
+// This file was procedurally generated from the following sources:
+// - src/declarations/function.case
+// - src/declarations/redeclare-allow-sloppy-function/block-attempt-to-redeclare-function-declaration.template
+/*---
+description: redeclaration with FunctionDeclaration (FunctionDeclaration in BlockStatement)
+esid: sec-block-static-semantics-early-errors
+flags: [generated, onlyStrict]
+negative:
+ phase: parse
+ type: SyntaxError
+info: |
+ Block : { StatementList }
+
+ It is a Syntax Error if the LexicallyDeclaredNames of StatementList contains
+ any duplicate entries.
+
+---*/
+
+
+$DONOTEVALUATE();
+
+{ function f() {} function f() {} }
diff --git a/js/src/tests/test262/language/block-scope/syntax/redeclaration/function-name-redeclaration-attempt-with-generator.js b/js/src/tests/test262/language/block-scope/syntax/redeclaration/function-name-redeclaration-attempt-with-generator.js
new file mode 100644
index 0000000000..e1fe7d8417
--- /dev/null
+++ b/js/src/tests/test262/language/block-scope/syntax/redeclaration/function-name-redeclaration-attempt-with-generator.js
@@ -0,0 +1,24 @@
+// |reftest| error:SyntaxError
+// This file was procedurally generated from the following sources:
+// - src/declarations/generator.case
+// - src/declarations/redeclare/block-attempt-to-redeclare-function-declaration.template
+/*---
+description: redeclaration with GeneratorDeclaration (FunctionDeclaration in BlockStatement)
+esid: sec-block-static-semantics-early-errors
+features: [generators]
+flags: [generated]
+negative:
+ phase: parse
+ type: SyntaxError
+info: |
+ Block : { StatementList }
+
+ It is a Syntax Error if the LexicallyDeclaredNames of StatementList contains
+ any duplicate entries.
+
+---*/
+
+
+$DONOTEVALUATE();
+
+{ function f() {} function* f() {} }
diff --git a/js/src/tests/test262/language/block-scope/syntax/redeclaration/function-name-redeclaration-attempt-with-let.js b/js/src/tests/test262/language/block-scope/syntax/redeclaration/function-name-redeclaration-attempt-with-let.js
new file mode 100644
index 0000000000..793027ea79
--- /dev/null
+++ b/js/src/tests/test262/language/block-scope/syntax/redeclaration/function-name-redeclaration-attempt-with-let.js
@@ -0,0 +1,23 @@
+// |reftest| error:SyntaxError
+// This file was procedurally generated from the following sources:
+// - src/declarations/let.case
+// - src/declarations/redeclare/block-attempt-to-redeclare-function-declaration.template
+/*---
+description: redeclaration with let-LexicalDeclaration (FunctionDeclaration in BlockStatement)
+esid: sec-block-static-semantics-early-errors
+flags: [generated]
+negative:
+ phase: parse
+ type: SyntaxError
+info: |
+ Block : { StatementList }
+
+ It is a Syntax Error if the LexicallyDeclaredNames of StatementList contains
+ any duplicate entries.
+
+---*/
+
+
+$DONOTEVALUATE();
+
+{ function f() {} let f }
diff --git a/js/src/tests/test262/language/block-scope/syntax/redeclaration/function-name-redeclaration-attempt-with-var.js b/js/src/tests/test262/language/block-scope/syntax/redeclaration/function-name-redeclaration-attempt-with-var.js
new file mode 100644
index 0000000000..a6b0fdc033
--- /dev/null
+++ b/js/src/tests/test262/language/block-scope/syntax/redeclaration/function-name-redeclaration-attempt-with-var.js
@@ -0,0 +1,23 @@
+// |reftest| error:SyntaxError
+// This file was procedurally generated from the following sources:
+// - src/declarations/var.case
+// - src/declarations/redeclare-allow-var/block-attempt-to-redeclare-function-declaration.template
+/*---
+description: redeclaration with VariableDeclaration (FunctionDeclaration in BlockStatement)
+esid: sec-block-static-semantics-early-errors
+flags: [generated]
+negative:
+ phase: parse
+ type: SyntaxError
+info: |
+ Block : { StatementList }
+
+ It is a Syntax Error if any element of the LexicallyDeclaredNames of
+ StatementList also occurs in the VarDeclaredNames of StatementList.
+
+---*/
+
+
+$DONOTEVALUATE();
+
+{ function f() {} var f }
diff --git a/js/src/tests/test262/language/block-scope/syntax/redeclaration/generator-name-redeclaration-attempt-with-async-function.js b/js/src/tests/test262/language/block-scope/syntax/redeclaration/generator-name-redeclaration-attempt-with-async-function.js
new file mode 100644
index 0000000000..602f2e33a4
--- /dev/null
+++ b/js/src/tests/test262/language/block-scope/syntax/redeclaration/generator-name-redeclaration-attempt-with-async-function.js
@@ -0,0 +1,24 @@
+// |reftest| error:SyntaxError
+// This file was procedurally generated from the following sources:
+// - src/declarations/async-function.case
+// - src/declarations/redeclare/block-attempt-to-redeclare-generator-declaration.template
+/*---
+description: redeclaration with AsyncFunctionDeclaration (GeneratorDeclaration in BlockStatement)
+esid: sec-block-static-semantics-early-errors
+features: [async-functions, generators]
+flags: [generated]
+negative:
+ phase: parse
+ type: SyntaxError
+info: |
+ Block : { StatementList }
+
+ It is a Syntax Error if the LexicallyDeclaredNames of StatementList contains
+ any duplicate entries.
+
+---*/
+
+
+$DONOTEVALUATE();
+
+{ function* f() {} async function f() {} }
diff --git a/js/src/tests/test262/language/block-scope/syntax/redeclaration/generator-name-redeclaration-attempt-with-async-generator.js b/js/src/tests/test262/language/block-scope/syntax/redeclaration/generator-name-redeclaration-attempt-with-async-generator.js
new file mode 100644
index 0000000000..c73e8355d4
--- /dev/null
+++ b/js/src/tests/test262/language/block-scope/syntax/redeclaration/generator-name-redeclaration-attempt-with-async-generator.js
@@ -0,0 +1,24 @@
+// |reftest| error:SyntaxError
+// This file was procedurally generated from the following sources:
+// - src/declarations/async-generator.case
+// - src/declarations/redeclare/block-attempt-to-redeclare-generator-declaration.template
+/*---
+description: redeclaration with AsyncGeneratorDeclaration (GeneratorDeclaration in BlockStatement)
+esid: sec-block-static-semantics-early-errors
+features: [async-iteration, generators]
+flags: [generated]
+negative:
+ phase: parse
+ type: SyntaxError
+info: |
+ Block : { StatementList }
+
+ It is a Syntax Error if the LexicallyDeclaredNames of StatementList contains
+ any duplicate entries.
+
+---*/
+
+
+$DONOTEVALUATE();
+
+{ function* f() {} async function* f() {} }
diff --git a/js/src/tests/test262/language/block-scope/syntax/redeclaration/generator-name-redeclaration-attempt-with-class.js b/js/src/tests/test262/language/block-scope/syntax/redeclaration/generator-name-redeclaration-attempt-with-class.js
new file mode 100644
index 0000000000..a3f3322da9
--- /dev/null
+++ b/js/src/tests/test262/language/block-scope/syntax/redeclaration/generator-name-redeclaration-attempt-with-class.js
@@ -0,0 +1,24 @@
+// |reftest| error:SyntaxError
+// This file was procedurally generated from the following sources:
+// - src/declarations/class.case
+// - src/declarations/redeclare/block-attempt-to-redeclare-generator-declaration.template
+/*---
+description: redeclaration with ClassDeclaration (GeneratorDeclaration in BlockStatement)
+esid: sec-block-static-semantics-early-errors
+features: [generators]
+flags: [generated]
+negative:
+ phase: parse
+ type: SyntaxError
+info: |
+ Block : { StatementList }
+
+ It is a Syntax Error if the LexicallyDeclaredNames of StatementList contains
+ any duplicate entries.
+
+---*/
+
+
+$DONOTEVALUATE();
+
+{ function* f() {} class f {} }
diff --git a/js/src/tests/test262/language/block-scope/syntax/redeclaration/generator-name-redeclaration-attempt-with-const.js b/js/src/tests/test262/language/block-scope/syntax/redeclaration/generator-name-redeclaration-attempt-with-const.js
new file mode 100644
index 0000000000..6e918b52a8
--- /dev/null
+++ b/js/src/tests/test262/language/block-scope/syntax/redeclaration/generator-name-redeclaration-attempt-with-const.js
@@ -0,0 +1,24 @@
+// |reftest| error:SyntaxError
+// This file was procedurally generated from the following sources:
+// - src/declarations/const.case
+// - src/declarations/redeclare/block-attempt-to-redeclare-generator-declaration.template
+/*---
+description: redeclaration with const-LexicalDeclaration (GeneratorDeclaration in BlockStatement)
+esid: sec-block-static-semantics-early-errors
+features: [generators]
+flags: [generated]
+negative:
+ phase: parse
+ type: SyntaxError
+info: |
+ Block : { StatementList }
+
+ It is a Syntax Error if the LexicallyDeclaredNames of StatementList contains
+ any duplicate entries.
+
+---*/
+
+
+$DONOTEVALUATE();
+
+{ function* f() {} const f = 0 }
diff --git a/js/src/tests/test262/language/block-scope/syntax/redeclaration/generator-name-redeclaration-attempt-with-function.js b/js/src/tests/test262/language/block-scope/syntax/redeclaration/generator-name-redeclaration-attempt-with-function.js
new file mode 100644
index 0000000000..12495cfc56
--- /dev/null
+++ b/js/src/tests/test262/language/block-scope/syntax/redeclaration/generator-name-redeclaration-attempt-with-function.js
@@ -0,0 +1,24 @@
+// |reftest| error:SyntaxError
+// This file was procedurally generated from the following sources:
+// - src/declarations/function.case
+// - src/declarations/redeclare-allow-sloppy-function/block-attempt-to-redeclare-generator-declaration.template
+/*---
+description: redeclaration with FunctionDeclaration (GeneratorDeclaration in BlockStatement)
+esid: sec-block-static-semantics-early-errors
+features: [generators]
+flags: [generated]
+negative:
+ phase: parse
+ type: SyntaxError
+info: |
+ Block : { StatementList }
+
+ It is a Syntax Error if the LexicallyDeclaredNames of StatementList contains
+ any duplicate entries.
+
+---*/
+
+
+$DONOTEVALUATE();
+
+{ function* f() {} function f() {} }
diff --git a/js/src/tests/test262/language/block-scope/syntax/redeclaration/generator-name-redeclaration-attempt-with-generator.js b/js/src/tests/test262/language/block-scope/syntax/redeclaration/generator-name-redeclaration-attempt-with-generator.js
new file mode 100644
index 0000000000..72597b350c
--- /dev/null
+++ b/js/src/tests/test262/language/block-scope/syntax/redeclaration/generator-name-redeclaration-attempt-with-generator.js
@@ -0,0 +1,24 @@
+// |reftest| error:SyntaxError
+// This file was procedurally generated from the following sources:
+// - src/declarations/generator.case
+// - src/declarations/redeclare/block-attempt-to-redeclare-generator-declaration.template
+/*---
+description: redeclaration with GeneratorDeclaration (GeneratorDeclaration in BlockStatement)
+esid: sec-block-static-semantics-early-errors
+features: [generators]
+flags: [generated]
+negative:
+ phase: parse
+ type: SyntaxError
+info: |
+ Block : { StatementList }
+
+ It is a Syntax Error if the LexicallyDeclaredNames of StatementList contains
+ any duplicate entries.
+
+---*/
+
+
+$DONOTEVALUATE();
+
+{ function* f() {} function* f() {} }
diff --git a/js/src/tests/test262/language/block-scope/syntax/redeclaration/generator-name-redeclaration-attempt-with-let.js b/js/src/tests/test262/language/block-scope/syntax/redeclaration/generator-name-redeclaration-attempt-with-let.js
new file mode 100644
index 0000000000..3099228f20
--- /dev/null
+++ b/js/src/tests/test262/language/block-scope/syntax/redeclaration/generator-name-redeclaration-attempt-with-let.js
@@ -0,0 +1,24 @@
+// |reftest| error:SyntaxError
+// This file was procedurally generated from the following sources:
+// - src/declarations/let.case
+// - src/declarations/redeclare/block-attempt-to-redeclare-generator-declaration.template
+/*---
+description: redeclaration with let-LexicalDeclaration (GeneratorDeclaration in BlockStatement)
+esid: sec-block-static-semantics-early-errors
+features: [generators]
+flags: [generated]
+negative:
+ phase: parse
+ type: SyntaxError
+info: |
+ Block : { StatementList }
+
+ It is a Syntax Error if the LexicallyDeclaredNames of StatementList contains
+ any duplicate entries.
+
+---*/
+
+
+$DONOTEVALUATE();
+
+{ function* f() {} let f }
diff --git a/js/src/tests/test262/language/block-scope/syntax/redeclaration/generator-name-redeclaration-attempt-with-var.js b/js/src/tests/test262/language/block-scope/syntax/redeclaration/generator-name-redeclaration-attempt-with-var.js
new file mode 100644
index 0000000000..57b9ad552f
--- /dev/null
+++ b/js/src/tests/test262/language/block-scope/syntax/redeclaration/generator-name-redeclaration-attempt-with-var.js
@@ -0,0 +1,24 @@
+// |reftest| error:SyntaxError
+// This file was procedurally generated from the following sources:
+// - src/declarations/var.case
+// - src/declarations/redeclare-allow-var/block-attempt-to-redeclare-generator-declaration.template
+/*---
+description: redeclaration with VariableDeclaration (GeneratorDeclaration in BlockStatement)
+esid: sec-block-static-semantics-early-errors
+features: [generators]
+flags: [generated]
+negative:
+ phase: parse
+ type: SyntaxError
+info: |
+ Block : { StatementList }
+
+ It is a Syntax Error if any element of the LexicallyDeclaredNames of
+ StatementList also occurs in the VarDeclaredNames of StatementList.
+
+---*/
+
+
+$DONOTEVALUATE();
+
+{ function* f() {} var f }
diff --git a/js/src/tests/test262/language/block-scope/syntax/redeclaration/inner-block-var-name-redeclaration-attempt-with-async-function.js b/js/src/tests/test262/language/block-scope/syntax/redeclaration/inner-block-var-name-redeclaration-attempt-with-async-function.js
new file mode 100644
index 0000000000..9251a7886e
--- /dev/null
+++ b/js/src/tests/test262/language/block-scope/syntax/redeclaration/inner-block-var-name-redeclaration-attempt-with-async-function.js
@@ -0,0 +1,40 @@
+// |reftest| error:SyntaxError
+// This file was procedurally generated from the following sources:
+// - src/declarations/async-function.case
+// - src/declarations/redeclare/block-attempt-to-redeclare-inner-block-var-declaration.template
+/*---
+description: redeclaration with AsyncFunctionDeclaration (VariableDeclaration in a BlockStatement inside a BlockStatement)
+esid: sec-block-static-semantics-early-errors
+features: [async-functions]
+flags: [generated]
+negative:
+ phase: parse
+ type: SyntaxError
+info: |
+ Block : { StatementList }
+
+ It is a Syntax Error if any element of the LexicallyDeclaredNames of
+ StatementList also occurs in the VarDeclaredNames of StatementList.
+
+ Static Semantics: VarDeclaredNames
+
+ Block : { }
+
+ 1. Return a new empty List.
+
+ StatementList : StatementList StatementListItem
+
+ 1. Let names be VarDeclaredNames of StatementList.
+ 2. Append to names the elements of the VarDeclaredNames of StatementListItem.
+ 3. Return names.
+
+ StatementListItem : Declaration
+
+ 1. Return a new empty List.
+
+---*/
+
+
+$DONOTEVALUATE();
+
+{ { var f; } async function f() {}; }
diff --git a/js/src/tests/test262/language/block-scope/syntax/redeclaration/inner-block-var-name-redeclaration-attempt-with-async-generator.js b/js/src/tests/test262/language/block-scope/syntax/redeclaration/inner-block-var-name-redeclaration-attempt-with-async-generator.js
new file mode 100644
index 0000000000..38a095ef55
--- /dev/null
+++ b/js/src/tests/test262/language/block-scope/syntax/redeclaration/inner-block-var-name-redeclaration-attempt-with-async-generator.js
@@ -0,0 +1,40 @@
+// |reftest| error:SyntaxError
+// This file was procedurally generated from the following sources:
+// - src/declarations/async-generator.case
+// - src/declarations/redeclare/block-attempt-to-redeclare-inner-block-var-declaration.template
+/*---
+description: redeclaration with AsyncGeneratorDeclaration (VariableDeclaration in a BlockStatement inside a BlockStatement)
+esid: sec-block-static-semantics-early-errors
+features: [async-iteration]
+flags: [generated]
+negative:
+ phase: parse
+ type: SyntaxError
+info: |
+ Block : { StatementList }
+
+ It is a Syntax Error if any element of the LexicallyDeclaredNames of
+ StatementList also occurs in the VarDeclaredNames of StatementList.
+
+ Static Semantics: VarDeclaredNames
+
+ Block : { }
+
+ 1. Return a new empty List.
+
+ StatementList : StatementList StatementListItem
+
+ 1. Let names be VarDeclaredNames of StatementList.
+ 2. Append to names the elements of the VarDeclaredNames of StatementListItem.
+ 3. Return names.
+
+ StatementListItem : Declaration
+
+ 1. Return a new empty List.
+
+---*/
+
+
+$DONOTEVALUATE();
+
+{ { var f; } async function* f() {}; }
diff --git a/js/src/tests/test262/language/block-scope/syntax/redeclaration/inner-block-var-name-redeclaration-attempt-with-class.js b/js/src/tests/test262/language/block-scope/syntax/redeclaration/inner-block-var-name-redeclaration-attempt-with-class.js
new file mode 100644
index 0000000000..8d31296d14
--- /dev/null
+++ b/js/src/tests/test262/language/block-scope/syntax/redeclaration/inner-block-var-name-redeclaration-attempt-with-class.js
@@ -0,0 +1,39 @@
+// |reftest| error:SyntaxError
+// This file was procedurally generated from the following sources:
+// - src/declarations/class.case
+// - src/declarations/redeclare/block-attempt-to-redeclare-inner-block-var-declaration.template
+/*---
+description: redeclaration with ClassDeclaration (VariableDeclaration in a BlockStatement inside a BlockStatement)
+esid: sec-block-static-semantics-early-errors
+flags: [generated]
+negative:
+ phase: parse
+ type: SyntaxError
+info: |
+ Block : { StatementList }
+
+ It is a Syntax Error if any element of the LexicallyDeclaredNames of
+ StatementList also occurs in the VarDeclaredNames of StatementList.
+
+ Static Semantics: VarDeclaredNames
+
+ Block : { }
+
+ 1. Return a new empty List.
+
+ StatementList : StatementList StatementListItem
+
+ 1. Let names be VarDeclaredNames of StatementList.
+ 2. Append to names the elements of the VarDeclaredNames of StatementListItem.
+ 3. Return names.
+
+ StatementListItem : Declaration
+
+ 1. Return a new empty List.
+
+---*/
+
+
+$DONOTEVALUATE();
+
+{ { var f; } class f {}; }
diff --git a/js/src/tests/test262/language/block-scope/syntax/redeclaration/inner-block-var-name-redeclaration-attempt-with-const.js b/js/src/tests/test262/language/block-scope/syntax/redeclaration/inner-block-var-name-redeclaration-attempt-with-const.js
new file mode 100644
index 0000000000..a3023384ad
--- /dev/null
+++ b/js/src/tests/test262/language/block-scope/syntax/redeclaration/inner-block-var-name-redeclaration-attempt-with-const.js
@@ -0,0 +1,39 @@
+// |reftest| error:SyntaxError
+// This file was procedurally generated from the following sources:
+// - src/declarations/const.case
+// - src/declarations/redeclare/block-attempt-to-redeclare-inner-block-var-declaration.template
+/*---
+description: redeclaration with const-LexicalDeclaration (VariableDeclaration in a BlockStatement inside a BlockStatement)
+esid: sec-block-static-semantics-early-errors
+flags: [generated]
+negative:
+ phase: parse
+ type: SyntaxError
+info: |
+ Block : { StatementList }
+
+ It is a Syntax Error if any element of the LexicallyDeclaredNames of
+ StatementList also occurs in the VarDeclaredNames of StatementList.
+
+ Static Semantics: VarDeclaredNames
+
+ Block : { }
+
+ 1. Return a new empty List.
+
+ StatementList : StatementList StatementListItem
+
+ 1. Let names be VarDeclaredNames of StatementList.
+ 2. Append to names the elements of the VarDeclaredNames of StatementListItem.
+ 3. Return names.
+
+ StatementListItem : Declaration
+
+ 1. Return a new empty List.
+
+---*/
+
+
+$DONOTEVALUATE();
+
+{ { var f; } const f = 0; }
diff --git a/js/src/tests/test262/language/block-scope/syntax/redeclaration/inner-block-var-name-redeclaration-attempt-with-function.js b/js/src/tests/test262/language/block-scope/syntax/redeclaration/inner-block-var-name-redeclaration-attempt-with-function.js
new file mode 100644
index 0000000000..8bcb39e45e
--- /dev/null
+++ b/js/src/tests/test262/language/block-scope/syntax/redeclaration/inner-block-var-name-redeclaration-attempt-with-function.js
@@ -0,0 +1,39 @@
+// |reftest| error:SyntaxError
+// This file was procedurally generated from the following sources:
+// - src/declarations/function.case
+// - src/declarations/redeclare-allow-sloppy-function/block-attempt-to-redeclare-inner-block-var-declaration.template
+/*---
+description: redeclaration with FunctionDeclaration (VariableDeclaration in a BlockStatement inside a BlockStatement)
+esid: sec-block-static-semantics-early-errors
+flags: [generated]
+negative:
+ phase: parse
+ type: SyntaxError
+info: |
+ Block : { StatementList }
+
+ It is a Syntax Error if any element of the LexicallyDeclaredNames of
+ StatementList also occurs in the VarDeclaredNames of StatementList.
+
+ Static Semantics: VarDeclaredNames
+
+ Block : { }
+
+ 1. Return a new empty List.
+
+ StatementList : StatementList StatementListItem
+
+ 1. Let names be VarDeclaredNames of StatementList.
+ 2. Append to names the elements of the VarDeclaredNames of StatementListItem.
+ 3. Return names.
+
+ StatementListItem : Declaration
+
+ 1. Return a new empty List.
+
+---*/
+
+
+$DONOTEVALUATE();
+
+{ { var f; } function f() {} }
diff --git a/js/src/tests/test262/language/block-scope/syntax/redeclaration/inner-block-var-name-redeclaration-attempt-with-generator.js b/js/src/tests/test262/language/block-scope/syntax/redeclaration/inner-block-var-name-redeclaration-attempt-with-generator.js
new file mode 100644
index 0000000000..e20a966469
--- /dev/null
+++ b/js/src/tests/test262/language/block-scope/syntax/redeclaration/inner-block-var-name-redeclaration-attempt-with-generator.js
@@ -0,0 +1,40 @@
+// |reftest| error:SyntaxError
+// This file was procedurally generated from the following sources:
+// - src/declarations/generator.case
+// - src/declarations/redeclare/block-attempt-to-redeclare-inner-block-var-declaration.template
+/*---
+description: redeclaration with GeneratorDeclaration (VariableDeclaration in a BlockStatement inside a BlockStatement)
+esid: sec-block-static-semantics-early-errors
+features: [generators]
+flags: [generated]
+negative:
+ phase: parse
+ type: SyntaxError
+info: |
+ Block : { StatementList }
+
+ It is a Syntax Error if any element of the LexicallyDeclaredNames of
+ StatementList also occurs in the VarDeclaredNames of StatementList.
+
+ Static Semantics: VarDeclaredNames
+
+ Block : { }
+
+ 1. Return a new empty List.
+
+ StatementList : StatementList StatementListItem
+
+ 1. Let names be VarDeclaredNames of StatementList.
+ 2. Append to names the elements of the VarDeclaredNames of StatementListItem.
+ 3. Return names.
+
+ StatementListItem : Declaration
+
+ 1. Return a new empty List.
+
+---*/
+
+
+$DONOTEVALUATE();
+
+{ { var f; } function* f() {}; }
diff --git a/js/src/tests/test262/language/block-scope/syntax/redeclaration/inner-block-var-name-redeclaration-attempt-with-let.js b/js/src/tests/test262/language/block-scope/syntax/redeclaration/inner-block-var-name-redeclaration-attempt-with-let.js
new file mode 100644
index 0000000000..85b7fe4059
--- /dev/null
+++ b/js/src/tests/test262/language/block-scope/syntax/redeclaration/inner-block-var-name-redeclaration-attempt-with-let.js
@@ -0,0 +1,39 @@
+// |reftest| error:SyntaxError
+// This file was procedurally generated from the following sources:
+// - src/declarations/let.case
+// - src/declarations/redeclare/block-attempt-to-redeclare-inner-block-var-declaration.template
+/*---
+description: redeclaration with let-LexicalDeclaration (VariableDeclaration in a BlockStatement inside a BlockStatement)
+esid: sec-block-static-semantics-early-errors
+flags: [generated]
+negative:
+ phase: parse
+ type: SyntaxError
+info: |
+ Block : { StatementList }
+
+ It is a Syntax Error if any element of the LexicallyDeclaredNames of
+ StatementList also occurs in the VarDeclaredNames of StatementList.
+
+ Static Semantics: VarDeclaredNames
+
+ Block : { }
+
+ 1. Return a new empty List.
+
+ StatementList : StatementList StatementListItem
+
+ 1. Let names be VarDeclaredNames of StatementList.
+ 2. Append to names the elements of the VarDeclaredNames of StatementListItem.
+ 3. Return names.
+
+ StatementListItem : Declaration
+
+ 1. Return a new empty List.
+
+---*/
+
+
+$DONOTEVALUATE();
+
+{ { var f; } let f; }
diff --git a/js/src/tests/test262/language/block-scope/syntax/redeclaration/inner-block-var-name-redeclaration-attempt-with-var.js b/js/src/tests/test262/language/block-scope/syntax/redeclaration/inner-block-var-name-redeclaration-attempt-with-var.js
new file mode 100644
index 0000000000..2920168bc9
--- /dev/null
+++ b/js/src/tests/test262/language/block-scope/syntax/redeclaration/inner-block-var-name-redeclaration-attempt-with-var.js
@@ -0,0 +1,34 @@
+// This file was procedurally generated from the following sources:
+// - src/declarations/var.case
+// - src/declarations/redeclare-allow-var/block-attempt-to-redeclare-inner-block-var-declaration.template
+/*---
+description: redeclaration with VariableDeclaration (VariableDeclaration in a BlockStatement inside a BlockStatement)
+esid: sec-block-static-semantics-early-errors
+flags: [generated]
+info: |
+ Block : { StatementList }
+
+ It is a Syntax Error if any element of the LexicallyDeclaredNames of
+ StatementList also occurs in the VarDeclaredNames of StatementList.
+
+ Static Semantics: VarDeclaredNames
+
+ Block : { }
+
+ 1. Return a new empty List.
+
+ StatementList : StatementList StatementListItem
+
+ 1. Let names be VarDeclaredNames of StatementList.
+ 2. Append to names the elements of the VarDeclaredNames of StatementListItem.
+ 3. Return names.
+
+ StatementListItem : Declaration
+
+ 1. Return a new empty List.
+---*/
+
+
+{ { var f; } var f }
+
+reportCompare(0, 0);
diff --git a/js/src/tests/test262/language/block-scope/syntax/redeclaration/inner-block-var-redeclaration-attempt-after-async-function.js b/js/src/tests/test262/language/block-scope/syntax/redeclaration/inner-block-var-redeclaration-attempt-after-async-function.js
new file mode 100644
index 0000000000..136d49a177
--- /dev/null
+++ b/js/src/tests/test262/language/block-scope/syntax/redeclaration/inner-block-var-redeclaration-attempt-after-async-function.js
@@ -0,0 +1,40 @@
+// |reftest| error:SyntaxError
+// This file was procedurally generated from the following sources:
+// - src/declarations/async-function.case
+// - src/declarations/redeclare/block-attempt-to-redeclare-inner-block-var-declaration-after.template
+/*---
+description: redeclaration with AsyncFunctionDeclaration (VariableDeclaration in a BlockStatement inside a BlockStatement)
+esid: sec-block-static-semantics-early-errors
+features: [async-functions]
+flags: [generated]
+negative:
+ phase: parse
+ type: SyntaxError
+info: |
+ Block : { StatementList }
+
+ It is a Syntax Error if any element of the LexicallyDeclaredNames of
+ StatementList also occurs in the VarDeclaredNames of StatementList.
+
+ Static Semantics: VarDeclaredNames
+
+ Block : { }
+
+ 1. Return a new empty List.
+
+ StatementList : StatementList StatementListItem
+
+ 1. Let names be VarDeclaredNames of StatementList.
+ 2. Append to names the elements of the VarDeclaredNames of StatementListItem.
+ 3. Return names.
+
+ StatementListItem : Declaration
+
+ 1. Return a new empty List.
+
+---*/
+
+
+$DONOTEVALUATE();
+
+{ async function f() {}; { var f; } }
diff --git a/js/src/tests/test262/language/block-scope/syntax/redeclaration/inner-block-var-redeclaration-attempt-after-async-generator.js b/js/src/tests/test262/language/block-scope/syntax/redeclaration/inner-block-var-redeclaration-attempt-after-async-generator.js
new file mode 100644
index 0000000000..df37d53238
--- /dev/null
+++ b/js/src/tests/test262/language/block-scope/syntax/redeclaration/inner-block-var-redeclaration-attempt-after-async-generator.js
@@ -0,0 +1,40 @@
+// |reftest| error:SyntaxError
+// This file was procedurally generated from the following sources:
+// - src/declarations/async-generator.case
+// - src/declarations/redeclare/block-attempt-to-redeclare-inner-block-var-declaration-after.template
+/*---
+description: redeclaration with AsyncGeneratorDeclaration (VariableDeclaration in a BlockStatement inside a BlockStatement)
+esid: sec-block-static-semantics-early-errors
+features: [async-iteration]
+flags: [generated]
+negative:
+ phase: parse
+ type: SyntaxError
+info: |
+ Block : { StatementList }
+
+ It is a Syntax Error if any element of the LexicallyDeclaredNames of
+ StatementList also occurs in the VarDeclaredNames of StatementList.
+
+ Static Semantics: VarDeclaredNames
+
+ Block : { }
+
+ 1. Return a new empty List.
+
+ StatementList : StatementList StatementListItem
+
+ 1. Let names be VarDeclaredNames of StatementList.
+ 2. Append to names the elements of the VarDeclaredNames of StatementListItem.
+ 3. Return names.
+
+ StatementListItem : Declaration
+
+ 1. Return a new empty List.
+
+---*/
+
+
+$DONOTEVALUATE();
+
+{ async function* f() {}; { var f; } }
diff --git a/js/src/tests/test262/language/block-scope/syntax/redeclaration/inner-block-var-redeclaration-attempt-after-class.js b/js/src/tests/test262/language/block-scope/syntax/redeclaration/inner-block-var-redeclaration-attempt-after-class.js
new file mode 100644
index 0000000000..33de9aeb71
--- /dev/null
+++ b/js/src/tests/test262/language/block-scope/syntax/redeclaration/inner-block-var-redeclaration-attempt-after-class.js
@@ -0,0 +1,39 @@
+// |reftest| error:SyntaxError
+// This file was procedurally generated from the following sources:
+// - src/declarations/class.case
+// - src/declarations/redeclare/block-attempt-to-redeclare-inner-block-var-declaration-after.template
+/*---
+description: redeclaration with ClassDeclaration (VariableDeclaration in a BlockStatement inside a BlockStatement)
+esid: sec-block-static-semantics-early-errors
+flags: [generated]
+negative:
+ phase: parse
+ type: SyntaxError
+info: |
+ Block : { StatementList }
+
+ It is a Syntax Error if any element of the LexicallyDeclaredNames of
+ StatementList also occurs in the VarDeclaredNames of StatementList.
+
+ Static Semantics: VarDeclaredNames
+
+ Block : { }
+
+ 1. Return a new empty List.
+
+ StatementList : StatementList StatementListItem
+
+ 1. Let names be VarDeclaredNames of StatementList.
+ 2. Append to names the elements of the VarDeclaredNames of StatementListItem.
+ 3. Return names.
+
+ StatementListItem : Declaration
+
+ 1. Return a new empty List.
+
+---*/
+
+
+$DONOTEVALUATE();
+
+{ class f {}; { var f; } }
diff --git a/js/src/tests/test262/language/block-scope/syntax/redeclaration/inner-block-var-redeclaration-attempt-after-const.js b/js/src/tests/test262/language/block-scope/syntax/redeclaration/inner-block-var-redeclaration-attempt-after-const.js
new file mode 100644
index 0000000000..5c9984bd42
--- /dev/null
+++ b/js/src/tests/test262/language/block-scope/syntax/redeclaration/inner-block-var-redeclaration-attempt-after-const.js
@@ -0,0 +1,39 @@
+// |reftest| error:SyntaxError
+// This file was procedurally generated from the following sources:
+// - src/declarations/const.case
+// - src/declarations/redeclare/block-attempt-to-redeclare-inner-block-var-declaration-after.template
+/*---
+description: redeclaration with const-LexicalDeclaration (VariableDeclaration in a BlockStatement inside a BlockStatement)
+esid: sec-block-static-semantics-early-errors
+flags: [generated]
+negative:
+ phase: parse
+ type: SyntaxError
+info: |
+ Block : { StatementList }
+
+ It is a Syntax Error if any element of the LexicallyDeclaredNames of
+ StatementList also occurs in the VarDeclaredNames of StatementList.
+
+ Static Semantics: VarDeclaredNames
+
+ Block : { }
+
+ 1. Return a new empty List.
+
+ StatementList : StatementList StatementListItem
+
+ 1. Let names be VarDeclaredNames of StatementList.
+ 2. Append to names the elements of the VarDeclaredNames of StatementListItem.
+ 3. Return names.
+
+ StatementListItem : Declaration
+
+ 1. Return a new empty List.
+
+---*/
+
+
+$DONOTEVALUATE();
+
+{ const f = 0; { var f; } }
diff --git a/js/src/tests/test262/language/block-scope/syntax/redeclaration/inner-block-var-redeclaration-attempt-after-function.js b/js/src/tests/test262/language/block-scope/syntax/redeclaration/inner-block-var-redeclaration-attempt-after-function.js
new file mode 100644
index 0000000000..e66637fcab
--- /dev/null
+++ b/js/src/tests/test262/language/block-scope/syntax/redeclaration/inner-block-var-redeclaration-attempt-after-function.js
@@ -0,0 +1,39 @@
+// |reftest| error:SyntaxError
+// This file was procedurally generated from the following sources:
+// - src/declarations/function.case
+// - src/declarations/redeclare-allow-sloppy-function/block-attempt-to-redeclare-inner-block-var-declaration-after.template
+/*---
+description: redeclaration with FunctionDeclaration (VariableDeclaration in a BlockStatement inside a BlockStatement)
+esid: sec-block-static-semantics-early-errors
+flags: [generated]
+negative:
+ phase: parse
+ type: SyntaxError
+info: |
+ Block : { StatementList }
+
+ It is a Syntax Error if any element of the LexicallyDeclaredNames of
+ StatementList also occurs in the VarDeclaredNames of StatementList.
+
+ Static Semantics: VarDeclaredNames
+
+ Block : { }
+
+ 1. Return a new empty List.
+
+ StatementList : StatementList StatementListItem
+
+ 1. Let names be VarDeclaredNames of StatementList.
+ 2. Append to names the elements of the VarDeclaredNames of StatementListItem.
+ 3. Return names.
+
+ StatementListItem : Declaration
+
+ 1. Return a new empty List.
+
+---*/
+
+
+$DONOTEVALUATE();
+
+{ function f() {} { var f; } }
diff --git a/js/src/tests/test262/language/block-scope/syntax/redeclaration/inner-block-var-redeclaration-attempt-after-generator.js b/js/src/tests/test262/language/block-scope/syntax/redeclaration/inner-block-var-redeclaration-attempt-after-generator.js
new file mode 100644
index 0000000000..0ea32cdcca
--- /dev/null
+++ b/js/src/tests/test262/language/block-scope/syntax/redeclaration/inner-block-var-redeclaration-attempt-after-generator.js
@@ -0,0 +1,40 @@
+// |reftest| error:SyntaxError
+// This file was procedurally generated from the following sources:
+// - src/declarations/generator.case
+// - src/declarations/redeclare/block-attempt-to-redeclare-inner-block-var-declaration-after.template
+/*---
+description: redeclaration with GeneratorDeclaration (VariableDeclaration in a BlockStatement inside a BlockStatement)
+esid: sec-block-static-semantics-early-errors
+features: [generators]
+flags: [generated]
+negative:
+ phase: parse
+ type: SyntaxError
+info: |
+ Block : { StatementList }
+
+ It is a Syntax Error if any element of the LexicallyDeclaredNames of
+ StatementList also occurs in the VarDeclaredNames of StatementList.
+
+ Static Semantics: VarDeclaredNames
+
+ Block : { }
+
+ 1. Return a new empty List.
+
+ StatementList : StatementList StatementListItem
+
+ 1. Let names be VarDeclaredNames of StatementList.
+ 2. Append to names the elements of the VarDeclaredNames of StatementListItem.
+ 3. Return names.
+
+ StatementListItem : Declaration
+
+ 1. Return a new empty List.
+
+---*/
+
+
+$DONOTEVALUATE();
+
+{ function* f() {}; { var f; } }
diff --git a/js/src/tests/test262/language/block-scope/syntax/redeclaration/inner-block-var-redeclaration-attempt-after-let.js b/js/src/tests/test262/language/block-scope/syntax/redeclaration/inner-block-var-redeclaration-attempt-after-let.js
new file mode 100644
index 0000000000..42e8ad738f
--- /dev/null
+++ b/js/src/tests/test262/language/block-scope/syntax/redeclaration/inner-block-var-redeclaration-attempt-after-let.js
@@ -0,0 +1,39 @@
+// |reftest| error:SyntaxError
+// This file was procedurally generated from the following sources:
+// - src/declarations/let.case
+// - src/declarations/redeclare/block-attempt-to-redeclare-inner-block-var-declaration-after.template
+/*---
+description: redeclaration with let-LexicalDeclaration (VariableDeclaration in a BlockStatement inside a BlockStatement)
+esid: sec-block-static-semantics-early-errors
+flags: [generated]
+negative:
+ phase: parse
+ type: SyntaxError
+info: |
+ Block : { StatementList }
+
+ It is a Syntax Error if any element of the LexicallyDeclaredNames of
+ StatementList also occurs in the VarDeclaredNames of StatementList.
+
+ Static Semantics: VarDeclaredNames
+
+ Block : { }
+
+ 1. Return a new empty List.
+
+ StatementList : StatementList StatementListItem
+
+ 1. Let names be VarDeclaredNames of StatementList.
+ 2. Append to names the elements of the VarDeclaredNames of StatementListItem.
+ 3. Return names.
+
+ StatementListItem : Declaration
+
+ 1. Return a new empty List.
+
+---*/
+
+
+$DONOTEVALUATE();
+
+{ let f; { var f; } }
diff --git a/js/src/tests/test262/language/block-scope/syntax/redeclaration/let-name-redeclaration-attempt-with-async-function.js b/js/src/tests/test262/language/block-scope/syntax/redeclaration/let-name-redeclaration-attempt-with-async-function.js
new file mode 100644
index 0000000000..fb96dc7bb1
--- /dev/null
+++ b/js/src/tests/test262/language/block-scope/syntax/redeclaration/let-name-redeclaration-attempt-with-async-function.js
@@ -0,0 +1,24 @@
+// |reftest| error:SyntaxError
+// This file was procedurally generated from the following sources:
+// - src/declarations/async-function.case
+// - src/declarations/redeclare/block-attempt-to-redeclare-let-declaration.template
+/*---
+description: redeclaration with AsyncFunctionDeclaration (LexicalDeclaration (let) in BlockStatement)
+esid: sec-block-static-semantics-early-errors
+features: [async-functions]
+flags: [generated]
+negative:
+ phase: parse
+ type: SyntaxError
+info: |
+ Block : { StatementList }
+
+ It is a Syntax Error if the LexicallyDeclaredNames of StatementList contains
+ any duplicate entries.
+
+---*/
+
+
+$DONOTEVALUATE();
+
+{ let f; async function f() {} }
diff --git a/js/src/tests/test262/language/block-scope/syntax/redeclaration/let-name-redeclaration-attempt-with-async-generator.js b/js/src/tests/test262/language/block-scope/syntax/redeclaration/let-name-redeclaration-attempt-with-async-generator.js
new file mode 100644
index 0000000000..a995140cdd
--- /dev/null
+++ b/js/src/tests/test262/language/block-scope/syntax/redeclaration/let-name-redeclaration-attempt-with-async-generator.js
@@ -0,0 +1,24 @@
+// |reftest| error:SyntaxError
+// This file was procedurally generated from the following sources:
+// - src/declarations/async-generator.case
+// - src/declarations/redeclare/block-attempt-to-redeclare-let-declaration.template
+/*---
+description: redeclaration with AsyncGeneratorDeclaration (LexicalDeclaration (let) in BlockStatement)
+esid: sec-block-static-semantics-early-errors
+features: [async-iteration]
+flags: [generated]
+negative:
+ phase: parse
+ type: SyntaxError
+info: |
+ Block : { StatementList }
+
+ It is a Syntax Error if the LexicallyDeclaredNames of StatementList contains
+ any duplicate entries.
+
+---*/
+
+
+$DONOTEVALUATE();
+
+{ let f; async function* f() {} }
diff --git a/js/src/tests/test262/language/block-scope/syntax/redeclaration/let-name-redeclaration-attempt-with-class.js b/js/src/tests/test262/language/block-scope/syntax/redeclaration/let-name-redeclaration-attempt-with-class.js
new file mode 100644
index 0000000000..135a5bed29
--- /dev/null
+++ b/js/src/tests/test262/language/block-scope/syntax/redeclaration/let-name-redeclaration-attempt-with-class.js
@@ -0,0 +1,23 @@
+// |reftest| error:SyntaxError
+// This file was procedurally generated from the following sources:
+// - src/declarations/class.case
+// - src/declarations/redeclare/block-attempt-to-redeclare-let-declaration.template
+/*---
+description: redeclaration with ClassDeclaration (LexicalDeclaration (let) in BlockStatement)
+esid: sec-block-static-semantics-early-errors
+flags: [generated]
+negative:
+ phase: parse
+ type: SyntaxError
+info: |
+ Block : { StatementList }
+
+ It is a Syntax Error if the LexicallyDeclaredNames of StatementList contains
+ any duplicate entries.
+
+---*/
+
+
+$DONOTEVALUATE();
+
+{ let f; class f {} }
diff --git a/js/src/tests/test262/language/block-scope/syntax/redeclaration/let-name-redeclaration-attempt-with-const.js b/js/src/tests/test262/language/block-scope/syntax/redeclaration/let-name-redeclaration-attempt-with-const.js
new file mode 100644
index 0000000000..892a392c97
--- /dev/null
+++ b/js/src/tests/test262/language/block-scope/syntax/redeclaration/let-name-redeclaration-attempt-with-const.js
@@ -0,0 +1,23 @@
+// |reftest| error:SyntaxError
+// This file was procedurally generated from the following sources:
+// - src/declarations/const.case
+// - src/declarations/redeclare/block-attempt-to-redeclare-let-declaration.template
+/*---
+description: redeclaration with const-LexicalDeclaration (LexicalDeclaration (let) in BlockStatement)
+esid: sec-block-static-semantics-early-errors
+flags: [generated]
+negative:
+ phase: parse
+ type: SyntaxError
+info: |
+ Block : { StatementList }
+
+ It is a Syntax Error if the LexicallyDeclaredNames of StatementList contains
+ any duplicate entries.
+
+---*/
+
+
+$DONOTEVALUATE();
+
+{ let f; const f = 0 }
diff --git a/js/src/tests/test262/language/block-scope/syntax/redeclaration/let-name-redeclaration-attempt-with-function.js b/js/src/tests/test262/language/block-scope/syntax/redeclaration/let-name-redeclaration-attempt-with-function.js
new file mode 100644
index 0000000000..333ad27641
--- /dev/null
+++ b/js/src/tests/test262/language/block-scope/syntax/redeclaration/let-name-redeclaration-attempt-with-function.js
@@ -0,0 +1,23 @@
+// |reftest| error:SyntaxError
+// This file was procedurally generated from the following sources:
+// - src/declarations/function.case
+// - src/declarations/redeclare-allow-sloppy-function/block-attempt-to-redeclare-let-declaration.template
+/*---
+description: redeclaration with FunctionDeclaration (LexicalDeclaration (let) in BlockStatement)
+esid: sec-block-static-semantics-early-errors
+flags: [generated]
+negative:
+ phase: parse
+ type: SyntaxError
+info: |
+ Block : { StatementList }
+
+ It is a Syntax Error if the LexicallyDeclaredNames of StatementList contains
+ any duplicate entries.
+
+---*/
+
+
+$DONOTEVALUATE();
+
+{ let f; function f() {} }
diff --git a/js/src/tests/test262/language/block-scope/syntax/redeclaration/let-name-redeclaration-attempt-with-generator.js b/js/src/tests/test262/language/block-scope/syntax/redeclaration/let-name-redeclaration-attempt-with-generator.js
new file mode 100644
index 0000000000..04edfcad88
--- /dev/null
+++ b/js/src/tests/test262/language/block-scope/syntax/redeclaration/let-name-redeclaration-attempt-with-generator.js
@@ -0,0 +1,24 @@
+// |reftest| error:SyntaxError
+// This file was procedurally generated from the following sources:
+// - src/declarations/generator.case
+// - src/declarations/redeclare/block-attempt-to-redeclare-let-declaration.template
+/*---
+description: redeclaration with GeneratorDeclaration (LexicalDeclaration (let) in BlockStatement)
+esid: sec-block-static-semantics-early-errors
+features: [generators]
+flags: [generated]
+negative:
+ phase: parse
+ type: SyntaxError
+info: |
+ Block : { StatementList }
+
+ It is a Syntax Error if the LexicallyDeclaredNames of StatementList contains
+ any duplicate entries.
+
+---*/
+
+
+$DONOTEVALUATE();
+
+{ let f; function* f() {} }
diff --git a/js/src/tests/test262/language/block-scope/syntax/redeclaration/let-name-redeclaration-attempt-with-let.js b/js/src/tests/test262/language/block-scope/syntax/redeclaration/let-name-redeclaration-attempt-with-let.js
new file mode 100644
index 0000000000..b5fca41af8
--- /dev/null
+++ b/js/src/tests/test262/language/block-scope/syntax/redeclaration/let-name-redeclaration-attempt-with-let.js
@@ -0,0 +1,23 @@
+// |reftest| error:SyntaxError
+// This file was procedurally generated from the following sources:
+// - src/declarations/let.case
+// - src/declarations/redeclare/block-attempt-to-redeclare-let-declaration.template
+/*---
+description: redeclaration with let-LexicalDeclaration (LexicalDeclaration (let) in BlockStatement)
+esid: sec-block-static-semantics-early-errors
+flags: [generated]
+negative:
+ phase: parse
+ type: SyntaxError
+info: |
+ Block : { StatementList }
+
+ It is a Syntax Error if the LexicallyDeclaredNames of StatementList contains
+ any duplicate entries.
+
+---*/
+
+
+$DONOTEVALUATE();
+
+{ let f; let f }
diff --git a/js/src/tests/test262/language/block-scope/syntax/redeclaration/let-name-redeclaration-attempt-with-var.js b/js/src/tests/test262/language/block-scope/syntax/redeclaration/let-name-redeclaration-attempt-with-var.js
new file mode 100644
index 0000000000..6392dbe7e3
--- /dev/null
+++ b/js/src/tests/test262/language/block-scope/syntax/redeclaration/let-name-redeclaration-attempt-with-var.js
@@ -0,0 +1,23 @@
+// |reftest| error:SyntaxError
+// This file was procedurally generated from the following sources:
+// - src/declarations/var.case
+// - src/declarations/redeclare-allow-var/block-attempt-to-redeclare-let-declaration.template
+/*---
+description: redeclaration with VariableDeclaration (LexicalDeclaration (let) in BlockStatement)
+esid: sec-block-static-semantics-early-errors
+flags: [generated]
+negative:
+ phase: parse
+ type: SyntaxError
+info: |
+ Block : { StatementList }
+
+ It is a Syntax Error if any element of the LexicallyDeclaredNames of
+ StatementList also occurs in the VarDeclaredNames of StatementList.
+
+---*/
+
+
+$DONOTEVALUATE();
+
+{ let f; var f }
diff --git a/js/src/tests/test262/language/block-scope/syntax/redeclaration/shell.js b/js/src/tests/test262/language/block-scope/syntax/redeclaration/shell.js
new file mode 100644
index 0000000000..e69de29bb2
--- /dev/null
+++ b/js/src/tests/test262/language/block-scope/syntax/redeclaration/shell.js
diff --git a/js/src/tests/test262/language/block-scope/syntax/redeclaration/var-name-redeclaration-attempt-with-async-function.js b/js/src/tests/test262/language/block-scope/syntax/redeclaration/var-name-redeclaration-attempt-with-async-function.js
new file mode 100644
index 0000000000..eb00396e65
--- /dev/null
+++ b/js/src/tests/test262/language/block-scope/syntax/redeclaration/var-name-redeclaration-attempt-with-async-function.js
@@ -0,0 +1,24 @@
+// |reftest| error:SyntaxError
+// This file was procedurally generated from the following sources:
+// - src/declarations/async-function.case
+// - src/declarations/redeclare/block-attempt-to-redeclare-var-declaration.template
+/*---
+description: redeclaration with AsyncFunctionDeclaration (VariableDeclaration in BlockStatement)
+esid: sec-block-static-semantics-early-errors
+features: [async-functions]
+flags: [generated]
+negative:
+ phase: parse
+ type: SyntaxError
+info: |
+ Block : { StatementList }
+
+ It is a Syntax Error if any element of the LexicallyDeclaredNames of
+ StatementList also occurs in the VarDeclaredNames of StatementList.
+
+---*/
+
+
+$DONOTEVALUATE();
+
+{ var f; async function f() {} }
diff --git a/js/src/tests/test262/language/block-scope/syntax/redeclaration/var-name-redeclaration-attempt-with-async-generator.js b/js/src/tests/test262/language/block-scope/syntax/redeclaration/var-name-redeclaration-attempt-with-async-generator.js
new file mode 100644
index 0000000000..6dab6dafdd
--- /dev/null
+++ b/js/src/tests/test262/language/block-scope/syntax/redeclaration/var-name-redeclaration-attempt-with-async-generator.js
@@ -0,0 +1,24 @@
+// |reftest| error:SyntaxError
+// This file was procedurally generated from the following sources:
+// - src/declarations/async-generator.case
+// - src/declarations/redeclare/block-attempt-to-redeclare-var-declaration.template
+/*---
+description: redeclaration with AsyncGeneratorDeclaration (VariableDeclaration in BlockStatement)
+esid: sec-block-static-semantics-early-errors
+features: [async-iteration]
+flags: [generated]
+negative:
+ phase: parse
+ type: SyntaxError
+info: |
+ Block : { StatementList }
+
+ It is a Syntax Error if any element of the LexicallyDeclaredNames of
+ StatementList also occurs in the VarDeclaredNames of StatementList.
+
+---*/
+
+
+$DONOTEVALUATE();
+
+{ var f; async function* f() {} }
diff --git a/js/src/tests/test262/language/block-scope/syntax/redeclaration/var-name-redeclaration-attempt-with-class.js b/js/src/tests/test262/language/block-scope/syntax/redeclaration/var-name-redeclaration-attempt-with-class.js
new file mode 100644
index 0000000000..654bd6b30c
--- /dev/null
+++ b/js/src/tests/test262/language/block-scope/syntax/redeclaration/var-name-redeclaration-attempt-with-class.js
@@ -0,0 +1,23 @@
+// |reftest| error:SyntaxError
+// This file was procedurally generated from the following sources:
+// - src/declarations/class.case
+// - src/declarations/redeclare/block-attempt-to-redeclare-var-declaration.template
+/*---
+description: redeclaration with ClassDeclaration (VariableDeclaration in BlockStatement)
+esid: sec-block-static-semantics-early-errors
+flags: [generated]
+negative:
+ phase: parse
+ type: SyntaxError
+info: |
+ Block : { StatementList }
+
+ It is a Syntax Error if any element of the LexicallyDeclaredNames of
+ StatementList also occurs in the VarDeclaredNames of StatementList.
+
+---*/
+
+
+$DONOTEVALUATE();
+
+{ var f; class f {} }
diff --git a/js/src/tests/test262/language/block-scope/syntax/redeclaration/var-name-redeclaration-attempt-with-const.js b/js/src/tests/test262/language/block-scope/syntax/redeclaration/var-name-redeclaration-attempt-with-const.js
new file mode 100644
index 0000000000..60bbde7e91
--- /dev/null
+++ b/js/src/tests/test262/language/block-scope/syntax/redeclaration/var-name-redeclaration-attempt-with-const.js
@@ -0,0 +1,23 @@
+// |reftest| error:SyntaxError
+// This file was procedurally generated from the following sources:
+// - src/declarations/const.case
+// - src/declarations/redeclare/block-attempt-to-redeclare-var-declaration.template
+/*---
+description: redeclaration with const-LexicalDeclaration (VariableDeclaration in BlockStatement)
+esid: sec-block-static-semantics-early-errors
+flags: [generated]
+negative:
+ phase: parse
+ type: SyntaxError
+info: |
+ Block : { StatementList }
+
+ It is a Syntax Error if any element of the LexicallyDeclaredNames of
+ StatementList also occurs in the VarDeclaredNames of StatementList.
+
+---*/
+
+
+$DONOTEVALUATE();
+
+{ var f; const f = 0 }
diff --git a/js/src/tests/test262/language/block-scope/syntax/redeclaration/var-name-redeclaration-attempt-with-function.js b/js/src/tests/test262/language/block-scope/syntax/redeclaration/var-name-redeclaration-attempt-with-function.js
new file mode 100644
index 0000000000..71354827e1
--- /dev/null
+++ b/js/src/tests/test262/language/block-scope/syntax/redeclaration/var-name-redeclaration-attempt-with-function.js
@@ -0,0 +1,23 @@
+// |reftest| error:SyntaxError
+// This file was procedurally generated from the following sources:
+// - src/declarations/function.case
+// - src/declarations/redeclare-allow-sloppy-function/block-attempt-to-redeclare-var-declaration.template
+/*---
+description: redeclaration with FunctionDeclaration (VariableDeclaration in BlockStatement)
+esid: sec-block-static-semantics-early-errors
+flags: [generated]
+negative:
+ phase: parse
+ type: SyntaxError
+info: |
+ Block : { StatementList }
+
+ It is a Syntax Error if any element of the LexicallyDeclaredNames of
+ StatementList also occurs in the VarDeclaredNames of StatementList.
+
+---*/
+
+
+$DONOTEVALUATE();
+
+{ var f; function f() {} }
diff --git a/js/src/tests/test262/language/block-scope/syntax/redeclaration/var-name-redeclaration-attempt-with-generator.js b/js/src/tests/test262/language/block-scope/syntax/redeclaration/var-name-redeclaration-attempt-with-generator.js
new file mode 100644
index 0000000000..9646700107
--- /dev/null
+++ b/js/src/tests/test262/language/block-scope/syntax/redeclaration/var-name-redeclaration-attempt-with-generator.js
@@ -0,0 +1,24 @@
+// |reftest| error:SyntaxError
+// This file was procedurally generated from the following sources:
+// - src/declarations/generator.case
+// - src/declarations/redeclare/block-attempt-to-redeclare-var-declaration.template
+/*---
+description: redeclaration with GeneratorDeclaration (VariableDeclaration in BlockStatement)
+esid: sec-block-static-semantics-early-errors
+features: [generators]
+flags: [generated]
+negative:
+ phase: parse
+ type: SyntaxError
+info: |
+ Block : { StatementList }
+
+ It is a Syntax Error if any element of the LexicallyDeclaredNames of
+ StatementList also occurs in the VarDeclaredNames of StatementList.
+
+---*/
+
+
+$DONOTEVALUATE();
+
+{ var f; function* f() {} }
diff --git a/js/src/tests/test262/language/block-scope/syntax/redeclaration/var-name-redeclaration-attempt-with-let.js b/js/src/tests/test262/language/block-scope/syntax/redeclaration/var-name-redeclaration-attempt-with-let.js
new file mode 100644
index 0000000000..210531fa16
--- /dev/null
+++ b/js/src/tests/test262/language/block-scope/syntax/redeclaration/var-name-redeclaration-attempt-with-let.js
@@ -0,0 +1,23 @@
+// |reftest| error:SyntaxError
+// This file was procedurally generated from the following sources:
+// - src/declarations/let.case
+// - src/declarations/redeclare/block-attempt-to-redeclare-var-declaration.template
+/*---
+description: redeclaration with let-LexicalDeclaration (VariableDeclaration in BlockStatement)
+esid: sec-block-static-semantics-early-errors
+flags: [generated]
+negative:
+ phase: parse
+ type: SyntaxError
+info: |
+ Block : { StatementList }
+
+ It is a Syntax Error if any element of the LexicallyDeclaredNames of
+ StatementList also occurs in the VarDeclaredNames of StatementList.
+
+---*/
+
+
+$DONOTEVALUATE();
+
+{ var f; let f }
diff --git a/js/src/tests/test262/language/block-scope/syntax/redeclaration/var-name-redeclaration-attempt-with-var.js b/js/src/tests/test262/language/block-scope/syntax/redeclaration/var-name-redeclaration-attempt-with-var.js
new file mode 100644
index 0000000000..d020ff2b3d
--- /dev/null
+++ b/js/src/tests/test262/language/block-scope/syntax/redeclaration/var-name-redeclaration-attempt-with-var.js
@@ -0,0 +1,18 @@
+// This file was procedurally generated from the following sources:
+// - src/declarations/var.case
+// - src/declarations/redeclare-allow-var/block-attempt-to-redeclare-var-declaration.template
+/*---
+description: redeclaration with VariableDeclaration (VariableDeclaration in BlockStatement)
+esid: sec-block-static-semantics-early-errors
+flags: [generated]
+info: |
+ Block : { StatementList }
+
+ It is a Syntax Error if any element of the LexicallyDeclaredNames of
+ StatementList also occurs in the VarDeclaredNames of StatementList.
+---*/
+
+
+{ var f; var f }
+
+reportCompare(0, 0);
diff --git a/js/src/tests/test262/language/block-scope/syntax/redeclaration/var-redeclaration-attempt-after-async-function.js b/js/src/tests/test262/language/block-scope/syntax/redeclaration/var-redeclaration-attempt-after-async-function.js
new file mode 100644
index 0000000000..e109c7ef21
--- /dev/null
+++ b/js/src/tests/test262/language/block-scope/syntax/redeclaration/var-redeclaration-attempt-after-async-function.js
@@ -0,0 +1,24 @@
+// |reftest| error:SyntaxError
+// This file was procedurally generated from the following sources:
+// - src/declarations/async-function.case
+// - src/declarations/redeclare/block-attempt-to-redeclare-var-declaration-after.template
+/*---
+description: redeclaration with AsyncFunctionDeclaration (VariableDeclaration in BlockStatement)
+esid: sec-block-static-semantics-early-errors
+features: [async-functions]
+flags: [generated]
+negative:
+ phase: parse
+ type: SyntaxError
+info: |
+ Block : { StatementList }
+
+ It is a Syntax Error if any element of the LexicallyDeclaredNames of
+ StatementList also occurs in the VarDeclaredNames of StatementList.
+
+---*/
+
+
+$DONOTEVALUATE();
+
+{ async function f() {}; var f; }
diff --git a/js/src/tests/test262/language/block-scope/syntax/redeclaration/var-redeclaration-attempt-after-async-generator.js b/js/src/tests/test262/language/block-scope/syntax/redeclaration/var-redeclaration-attempt-after-async-generator.js
new file mode 100644
index 0000000000..44dd1f42b5
--- /dev/null
+++ b/js/src/tests/test262/language/block-scope/syntax/redeclaration/var-redeclaration-attempt-after-async-generator.js
@@ -0,0 +1,24 @@
+// |reftest| error:SyntaxError
+// This file was procedurally generated from the following sources:
+// - src/declarations/async-generator.case
+// - src/declarations/redeclare/block-attempt-to-redeclare-var-declaration-after.template
+/*---
+description: redeclaration with AsyncGeneratorDeclaration (VariableDeclaration in BlockStatement)
+esid: sec-block-static-semantics-early-errors
+features: [async-iteration]
+flags: [generated]
+negative:
+ phase: parse
+ type: SyntaxError
+info: |
+ Block : { StatementList }
+
+ It is a Syntax Error if any element of the LexicallyDeclaredNames of
+ StatementList also occurs in the VarDeclaredNames of StatementList.
+
+---*/
+
+
+$DONOTEVALUATE();
+
+{ async function* f() {}; var f; }
diff --git a/js/src/tests/test262/language/block-scope/syntax/redeclaration/var-redeclaration-attempt-after-class.js b/js/src/tests/test262/language/block-scope/syntax/redeclaration/var-redeclaration-attempt-after-class.js
new file mode 100644
index 0000000000..73545ef577
--- /dev/null
+++ b/js/src/tests/test262/language/block-scope/syntax/redeclaration/var-redeclaration-attempt-after-class.js
@@ -0,0 +1,23 @@
+// |reftest| error:SyntaxError
+// This file was procedurally generated from the following sources:
+// - src/declarations/class.case
+// - src/declarations/redeclare/block-attempt-to-redeclare-var-declaration-after.template
+/*---
+description: redeclaration with ClassDeclaration (VariableDeclaration in BlockStatement)
+esid: sec-block-static-semantics-early-errors
+flags: [generated]
+negative:
+ phase: parse
+ type: SyntaxError
+info: |
+ Block : { StatementList }
+
+ It is a Syntax Error if any element of the LexicallyDeclaredNames of
+ StatementList also occurs in the VarDeclaredNames of StatementList.
+
+---*/
+
+
+$DONOTEVALUATE();
+
+{ class f {}; var f; }
diff --git a/js/src/tests/test262/language/block-scope/syntax/redeclaration/var-redeclaration-attempt-after-const.js b/js/src/tests/test262/language/block-scope/syntax/redeclaration/var-redeclaration-attempt-after-const.js
new file mode 100644
index 0000000000..79a377240e
--- /dev/null
+++ b/js/src/tests/test262/language/block-scope/syntax/redeclaration/var-redeclaration-attempt-after-const.js
@@ -0,0 +1,23 @@
+// |reftest| error:SyntaxError
+// This file was procedurally generated from the following sources:
+// - src/declarations/const.case
+// - src/declarations/redeclare/block-attempt-to-redeclare-var-declaration-after.template
+/*---
+description: redeclaration with const-LexicalDeclaration (VariableDeclaration in BlockStatement)
+esid: sec-block-static-semantics-early-errors
+flags: [generated]
+negative:
+ phase: parse
+ type: SyntaxError
+info: |
+ Block : { StatementList }
+
+ It is a Syntax Error if any element of the LexicallyDeclaredNames of
+ StatementList also occurs in the VarDeclaredNames of StatementList.
+
+---*/
+
+
+$DONOTEVALUATE();
+
+{ const f = 0; var f; }
diff --git a/js/src/tests/test262/language/block-scope/syntax/redeclaration/var-redeclaration-attempt-after-function.js b/js/src/tests/test262/language/block-scope/syntax/redeclaration/var-redeclaration-attempt-after-function.js
new file mode 100644
index 0000000000..ea49a0be89
--- /dev/null
+++ b/js/src/tests/test262/language/block-scope/syntax/redeclaration/var-redeclaration-attempt-after-function.js
@@ -0,0 +1,23 @@
+// |reftest| error:SyntaxError
+// This file was procedurally generated from the following sources:
+// - src/declarations/function.case
+// - src/declarations/redeclare-allow-sloppy-function/block-attempt-to-redeclare-var-declaration-after.template
+/*---
+description: redeclaration with FunctionDeclaration (VariableDeclaration in BlockStatement)
+esid: sec-block-static-semantics-early-errors
+flags: [generated]
+negative:
+ phase: parse
+ type: SyntaxError
+info: |
+ Block : { StatementList }
+
+ It is a Syntax Error if any element of the LexicallyDeclaredNames of
+ StatementList also occurs in the VarDeclaredNames of StatementList.
+
+---*/
+
+
+$DONOTEVALUATE();
+
+{ function f() {}; var f; }
diff --git a/js/src/tests/test262/language/block-scope/syntax/redeclaration/var-redeclaration-attempt-after-generator.js b/js/src/tests/test262/language/block-scope/syntax/redeclaration/var-redeclaration-attempt-after-generator.js
new file mode 100644
index 0000000000..3a9d0015a1
--- /dev/null
+++ b/js/src/tests/test262/language/block-scope/syntax/redeclaration/var-redeclaration-attempt-after-generator.js
@@ -0,0 +1,24 @@
+// |reftest| error:SyntaxError
+// This file was procedurally generated from the following sources:
+// - src/declarations/generator.case
+// - src/declarations/redeclare/block-attempt-to-redeclare-var-declaration-after.template
+/*---
+description: redeclaration with GeneratorDeclaration (VariableDeclaration in BlockStatement)
+esid: sec-block-static-semantics-early-errors
+features: [generators]
+flags: [generated]
+negative:
+ phase: parse
+ type: SyntaxError
+info: |
+ Block : { StatementList }
+
+ It is a Syntax Error if any element of the LexicallyDeclaredNames of
+ StatementList also occurs in the VarDeclaredNames of StatementList.
+
+---*/
+
+
+$DONOTEVALUATE();
+
+{ function* f() {}; var f; }
diff --git a/js/src/tests/test262/language/block-scope/syntax/redeclaration/var-redeclaration-attempt-after-let.js b/js/src/tests/test262/language/block-scope/syntax/redeclaration/var-redeclaration-attempt-after-let.js
new file mode 100644
index 0000000000..a8b415ff28
--- /dev/null
+++ b/js/src/tests/test262/language/block-scope/syntax/redeclaration/var-redeclaration-attempt-after-let.js
@@ -0,0 +1,23 @@
+// |reftest| error:SyntaxError
+// This file was procedurally generated from the following sources:
+// - src/declarations/let.case
+// - src/declarations/redeclare/block-attempt-to-redeclare-var-declaration-after.template
+/*---
+description: redeclaration with let-LexicalDeclaration (VariableDeclaration in BlockStatement)
+esid: sec-block-static-semantics-early-errors
+flags: [generated]
+negative:
+ phase: parse
+ type: SyntaxError
+info: |
+ Block : { StatementList }
+
+ It is a Syntax Error if any element of the LexicallyDeclaredNames of
+ StatementList also occurs in the VarDeclaredNames of StatementList.
+
+---*/
+
+
+$DONOTEVALUATE();
+
+{ let f; var f; }