summaryrefslogtreecommitdiffstats
path: root/js/src/tests/test262/language/block-scope/syntax
diff options
context:
space:
mode:
Diffstat (limited to 'js/src/tests/test262/language/block-scope/syntax')
-rw-r--r--js/src/tests/test262/language/block-scope/syntax/browser.js0
-rw-r--r--js/src/tests/test262/language/block-scope/syntax/for-in/acquire-properties-from-array.js43
-rw-r--r--js/src/tests/test262/language/block-scope/syntax/for-in/acquire-properties-from-object.js43
-rw-r--r--js/src/tests/test262/language/block-scope/syntax/for-in/browser.js0
-rw-r--r--js/src/tests/test262/language/block-scope/syntax/for-in/disallow-initialization-assignment.js16
-rw-r--r--js/src/tests/test262/language/block-scope/syntax/for-in/disallow-multiple-lexical-bindings-with-and-without-initializer.js16
-rw-r--r--js/src/tests/test262/language/block-scope/syntax/for-in/disallow-multiple-lexical-bindings-with-initializer.js16
-rw-r--r--js/src/tests/test262/language/block-scope/syntax/for-in/disallow-multiple-lexical-bindings-without-and-with-initializer.js16
-rw-r--r--js/src/tests/test262/language/block-scope/syntax/for-in/disallow-multiple-lexical-bindings.js16
-rw-r--r--js/src/tests/test262/language/block-scope/syntax/for-in/mixed-values-in-iteration.js22
-rw-r--r--js/src/tests/test262/language/block-scope/syntax/for-in/shell.js0
-rw-r--r--js/src/tests/test262/language/block-scope/syntax/function-declarations/browser.js0
-rw-r--r--js/src/tests/test262/language/block-scope/syntax/function-declarations/in-statement-position-case-expression-statement-list.js12
-rw-r--r--js/src/tests/test262/language/block-scope/syntax/function-declarations/in-statement-position-default-statement-list.js12
-rw-r--r--js/src/tests/test262/language/block-scope/syntax/function-declarations/in-statement-position-do-statement-while-expression.js16
-rw-r--r--js/src/tests/test262/language/block-scope/syntax/function-declarations/in-statement-position-for-statement.js16
-rw-r--r--js/src/tests/test262/language/block-scope/syntax/function-declarations/in-statement-position-if-expression-statement-else-statement-strict.js18
-rw-r--r--js/src/tests/test262/language/block-scope/syntax/function-declarations/in-statement-position-if-expression-statement-strict.js18
-rw-r--r--js/src/tests/test262/language/block-scope/syntax/function-declarations/in-statement-position-while-expression-statement.js16
-rw-r--r--js/src/tests/test262/language/block-scope/syntax/function-declarations/shell.js0
-rw-r--r--js/src/tests/test262/language/block-scope/syntax/redeclaration-global/allowed-to-declare-function-with-function-declaration.js12
-rw-r--r--js/src/tests/test262/language/block-scope/syntax/redeclaration-global/allowed-to-redeclare-function-declaration-with-var.js12
-rw-r--r--js/src/tests/test262/language/block-scope/syntax/redeclaration-global/allowed-to-redeclare-var-with-function-declaration.js12
-rw-r--r--js/src/tests/test262/language/block-scope/syntax/redeclaration-global/browser.js0
-rw-r--r--js/src/tests/test262/language/block-scope/syntax/redeclaration-global/shell.js0
-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
-rw-r--r--js/src/tests/test262/language/block-scope/syntax/shell.js0
123 files changed, 2819 insertions, 0 deletions
diff --git a/js/src/tests/test262/language/block-scope/syntax/browser.js b/js/src/tests/test262/language/block-scope/syntax/browser.js
new file mode 100644
index 0000000000..e69de29bb2
--- /dev/null
+++ b/js/src/tests/test262/language/block-scope/syntax/browser.js
diff --git a/js/src/tests/test262/language/block-scope/syntax/for-in/acquire-properties-from-array.js b/js/src/tests/test262/language/block-scope/syntax/for-in/acquire-properties-from-array.js
new file mode 100644
index 0000000000..66a0be39dd
--- /dev/null
+++ b/js/src/tests/test262/language/block-scope/syntax/for-in/acquire-properties-from-array.js
@@ -0,0 +1,43 @@
+// Copyright (C) 2011 the V8 project authors. All rights reserved.
+// This code is governed by the BSD license found in the LICENSE file.
+/*---
+es6id: 13.1
+description: >
+ for-in to acquire properties from array
+---*/
+function props(x) {
+ var array = [];
+ for (let p in x) array.push(p);
+ return array;
+}
+var subject;
+
+subject = props([]);
+assert.sameValue(subject.length, 0, "[]: length");
+assert.sameValue(subject[0], undefined, "[]: first property");
+assert.sameValue(subject[1], undefined, "[]: second property");
+assert.sameValue(subject[2], undefined, "[]: third property");
+assert.sameValue(subject[3], undefined, "[]: fourth property");
+
+subject = props([1]);
+assert.sameValue(subject.length, 1, "[1]: length");
+assert.sameValue(subject[0], "0", "[1]: first property");
+assert.sameValue(subject[1], undefined, "[1]: second property");
+assert.sameValue(subject[2], undefined, "[1]: third property");
+assert.sameValue(subject[3], undefined, "[1]: fourth property");
+
+subject = props([1, 2]);
+assert.sameValue(subject.length, 2, "[1, 2]: length");
+assert.sameValue(subject[0], "0", "[1, 2]: first property");
+assert.sameValue(subject[1], "1", "[1, 2]: second property");
+assert.sameValue(subject[2], undefined, "[1, 2]: third property");
+assert.sameValue(subject[3], undefined, "[1, 2]: fourth property");
+
+subject = props([1, 2, 3]);
+assert.sameValue(subject.length, 3, "[1, 2, 3]: length");
+assert.sameValue(subject[0], "0", "[1, 2, 3]: first property");
+assert.sameValue(subject[1], "1", "[1, 2, 3]: second property");
+assert.sameValue(subject[2], "2", "[1, 2, 3]: third property");
+assert.sameValue(subject[3], undefined, "[1, 2, 3]: fourth property");
+
+reportCompare(0, 0);
diff --git a/js/src/tests/test262/language/block-scope/syntax/for-in/acquire-properties-from-object.js b/js/src/tests/test262/language/block-scope/syntax/for-in/acquire-properties-from-object.js
new file mode 100644
index 0000000000..9016fb3b1d
--- /dev/null
+++ b/js/src/tests/test262/language/block-scope/syntax/for-in/acquire-properties-from-object.js
@@ -0,0 +1,43 @@
+// Copyright (C) 2011 the V8 project authors. All rights reserved.
+// This code is governed by the BSD license found in the LICENSE file.
+/*---
+es6id: 13.1
+description: >
+ for-in to acquire properties from object
+---*/
+function props(x) {
+ var array = [];
+ for (let p in x) array.push(p);
+ return array;
+}
+var subject;
+
+subject = props({});
+assert.sameValue(subject.length, 0, "{}: length");
+assert.sameValue(subject[0], undefined, "{}: first property");
+assert.sameValue(subject[1], undefined, "{}: second property");
+assert.sameValue(subject[2], undefined, "{}: third property");
+assert.sameValue(subject[3], undefined, "{}: fourth property");
+
+subject = props({x:1});
+assert.sameValue(subject.length, 1, "{x:1}: length");
+assert.sameValue(subject[0], "x", "{x:1}: first property");
+assert.sameValue(subject[1], undefined, "{x:1}: second property");
+assert.sameValue(subject[2], undefined, "{x:1}: third property");
+assert.sameValue(subject[3], undefined, "{x:1}: fourth property");
+
+subject = props({x:1, y:2});
+assert.sameValue(subject.length, 2, "{x:1, y:2}: length");
+assert.sameValue(subject[0], "x", "{x:1, y:2}: first property");
+assert.sameValue(subject[1], "y", "{x:1, y:2}: second property");
+assert.sameValue(subject[2], undefined, "{x:1, y:2}: third property");
+assert.sameValue(subject[3], undefined, "{x:1, y:2}: fourth property");
+
+subject = props({x:1, y:2, zoom:3});
+assert.sameValue(subject.length, 3, "{x:1, y:2, zoom:3}: length");
+assert.sameValue(subject[0], "x", "{x:1, y:2, zoom:3}: first property");
+assert.sameValue(subject[1], "y", "{x:1, y:2, zoom:3}: second property");
+assert.sameValue(subject[2], "zoom", "{x:1, y:2, zoom:3}: third property");
+assert.sameValue(subject[3], undefined, "{x:1, y:2, zoom:3}: fourth property");
+
+reportCompare(0, 0);
diff --git a/js/src/tests/test262/language/block-scope/syntax/for-in/browser.js b/js/src/tests/test262/language/block-scope/syntax/for-in/browser.js
new file mode 100644
index 0000000000..e69de29bb2
--- /dev/null
+++ b/js/src/tests/test262/language/block-scope/syntax/for-in/browser.js
diff --git a/js/src/tests/test262/language/block-scope/syntax/for-in/disallow-initialization-assignment.js b/js/src/tests/test262/language/block-scope/syntax/for-in/disallow-initialization-assignment.js
new file mode 100644
index 0000000000..6eb679df1e
--- /dev/null
+++ b/js/src/tests/test262/language/block-scope/syntax/for-in/disallow-initialization-assignment.js
@@ -0,0 +1,16 @@
+// |reftest| error:SyntaxError
+// Copyright (C) 2011 the V8 project authors. All rights reserved.
+// This code is governed by the BSD license found in the LICENSE file.
+/*---
+es6id: 13.1
+description: >
+ for declaration:
+ disallow initialization assignment
+negative:
+ phase: parse
+ type: SyntaxError
+---*/
+
+$DONOTEVALUATE();
+for (let x = 3 in {}) { }
+
diff --git a/js/src/tests/test262/language/block-scope/syntax/for-in/disallow-multiple-lexical-bindings-with-and-without-initializer.js b/js/src/tests/test262/language/block-scope/syntax/for-in/disallow-multiple-lexical-bindings-with-and-without-initializer.js
new file mode 100644
index 0000000000..67383a0210
--- /dev/null
+++ b/js/src/tests/test262/language/block-scope/syntax/for-in/disallow-multiple-lexical-bindings-with-and-without-initializer.js
@@ -0,0 +1,16 @@
+// |reftest| error:SyntaxError
+// Copyright (C) 2011 the V8 project authors. All rights reserved.
+// This code is governed by the BSD license found in the LICENSE file.
+/*---
+es6id: 13.1
+description: >
+ for declaration:
+ disallow multiple lexical bindings, with and without initializer
+negative:
+ phase: parse
+ type: SyntaxError
+---*/
+
+$DONOTEVALUATE();
+for (let x = 3, y in {}) { }
+
diff --git a/js/src/tests/test262/language/block-scope/syntax/for-in/disallow-multiple-lexical-bindings-with-initializer.js b/js/src/tests/test262/language/block-scope/syntax/for-in/disallow-multiple-lexical-bindings-with-initializer.js
new file mode 100644
index 0000000000..36c2e9c22a
--- /dev/null
+++ b/js/src/tests/test262/language/block-scope/syntax/for-in/disallow-multiple-lexical-bindings-with-initializer.js
@@ -0,0 +1,16 @@
+// |reftest| error:SyntaxError
+// Copyright (C) 2011 the V8 project authors. All rights reserved.
+// This code is governed by the BSD license found in the LICENSE file.
+/*---
+es6id: 13.1
+description: >
+ for declaration:
+ disallow multiple lexical bindings, with initializer
+negative:
+ phase: parse
+ type: SyntaxError
+---*/
+
+$DONOTEVALUATE();
+for (let x = 3, y = 4 in {}) { }
+
diff --git a/js/src/tests/test262/language/block-scope/syntax/for-in/disallow-multiple-lexical-bindings-without-and-with-initializer.js b/js/src/tests/test262/language/block-scope/syntax/for-in/disallow-multiple-lexical-bindings-without-and-with-initializer.js
new file mode 100644
index 0000000000..84f9c83688
--- /dev/null
+++ b/js/src/tests/test262/language/block-scope/syntax/for-in/disallow-multiple-lexical-bindings-without-and-with-initializer.js
@@ -0,0 +1,16 @@
+// |reftest| error:SyntaxError
+// Copyright (C) 2011 the V8 project authors. All rights reserved.
+// This code is governed by the BSD license found in the LICENSE file.
+/*---
+es6id: 13.1
+description: >
+ for declaration:
+ disallow multiple lexical bindings, without and with initializer
+negative:
+ phase: parse
+ type: SyntaxError
+---*/
+
+$DONOTEVALUATE();
+for (let x, y = 4 in {}) { }
+
diff --git a/js/src/tests/test262/language/block-scope/syntax/for-in/disallow-multiple-lexical-bindings.js b/js/src/tests/test262/language/block-scope/syntax/for-in/disallow-multiple-lexical-bindings.js
new file mode 100644
index 0000000000..550974ced8
--- /dev/null
+++ b/js/src/tests/test262/language/block-scope/syntax/for-in/disallow-multiple-lexical-bindings.js
@@ -0,0 +1,16 @@
+// |reftest| error:SyntaxError
+// Copyright (C) 2011 the V8 project authors. All rights reserved.
+// This code is governed by the BSD license found in the LICENSE file.
+/*---
+es6id: 13.1
+description: >
+ for declaration:
+ disallow multiple lexical bindings
+negative:
+ phase: parse
+ type: SyntaxError
+---*/
+
+$DONOTEVALUATE();
+for (let x, y in {}) { }
+
diff --git a/js/src/tests/test262/language/block-scope/syntax/for-in/mixed-values-in-iteration.js b/js/src/tests/test262/language/block-scope/syntax/for-in/mixed-values-in-iteration.js
new file mode 100644
index 0000000000..85f2c0bf4e
--- /dev/null
+++ b/js/src/tests/test262/language/block-scope/syntax/for-in/mixed-values-in-iteration.js
@@ -0,0 +1,22 @@
+// Copyright (C) 2011 the V8 project authors. All rights reserved.
+// This code is governed by the BSD license found in the LICENSE file.
+/*---
+es6id: 13.1
+description: >
+ Mixed values in iteration
+---*/
+function fn(x) {
+ let a = [];
+ for (let p in x) {
+ a.push(function () { return p; });
+ }
+ let k = 0;
+ for (let q in x) {
+ assert.sameValue(q, a[k]());
+ ++k;
+ }
+}
+fn({a : [0], b : 1, c : {v : 1}, get d() {}, set e(x) {}});
+
+
+reportCompare(0, 0);
diff --git a/js/src/tests/test262/language/block-scope/syntax/for-in/shell.js b/js/src/tests/test262/language/block-scope/syntax/for-in/shell.js
new file mode 100644
index 0000000000..e69de29bb2
--- /dev/null
+++ b/js/src/tests/test262/language/block-scope/syntax/for-in/shell.js
diff --git a/js/src/tests/test262/language/block-scope/syntax/function-declarations/browser.js b/js/src/tests/test262/language/block-scope/syntax/function-declarations/browser.js
new file mode 100644
index 0000000000..e69de29bb2
--- /dev/null
+++ b/js/src/tests/test262/language/block-scope/syntax/function-declarations/browser.js
diff --git a/js/src/tests/test262/language/block-scope/syntax/function-declarations/in-statement-position-case-expression-statement-list.js b/js/src/tests/test262/language/block-scope/syntax/function-declarations/in-statement-position-case-expression-statement-list.js
new file mode 100644
index 0000000000..0d4a759993
--- /dev/null
+++ b/js/src/tests/test262/language/block-scope/syntax/function-declarations/in-statement-position-case-expression-statement-list.js
@@ -0,0 +1,12 @@
+// Copyright (C) 2011 the V8 project authors. All rights reserved.
+// This code is governed by the BSD license found in the LICENSE file.
+/*---
+es6id: 13.1
+description: >
+ function declarations in statement position in strict mode:
+ case Expression : StatementList
+---*/
+switch (true) { case true: function g() {} }
+
+
+reportCompare(0, 0);
diff --git a/js/src/tests/test262/language/block-scope/syntax/function-declarations/in-statement-position-default-statement-list.js b/js/src/tests/test262/language/block-scope/syntax/function-declarations/in-statement-position-default-statement-list.js
new file mode 100644
index 0000000000..cb656254c0
--- /dev/null
+++ b/js/src/tests/test262/language/block-scope/syntax/function-declarations/in-statement-position-default-statement-list.js
@@ -0,0 +1,12 @@
+// Copyright (C) 2011 the V8 project authors. All rights reserved.
+// This code is governed by the BSD license found in the LICENSE file.
+/*---
+es6id: 13.1
+description: >
+ function declarations in statement position in strict mode:
+ default : StatementList
+---*/
+switch (true) { default: function g() {} }
+
+
+reportCompare(0, 0);
diff --git a/js/src/tests/test262/language/block-scope/syntax/function-declarations/in-statement-position-do-statement-while-expression.js b/js/src/tests/test262/language/block-scope/syntax/function-declarations/in-statement-position-do-statement-while-expression.js
new file mode 100644
index 0000000000..7e21f7ff75
--- /dev/null
+++ b/js/src/tests/test262/language/block-scope/syntax/function-declarations/in-statement-position-do-statement-while-expression.js
@@ -0,0 +1,16 @@
+// |reftest| error:SyntaxError
+// Copyright (C) 2011 the V8 project authors. All rights reserved.
+// This code is governed by the BSD license found in the LICENSE file.
+/*---
+es6id: 13.1
+description: >
+ function declarations in statement position:
+ do Statement while ( Expression )
+negative:
+ phase: parse
+ type: SyntaxError
+---*/
+
+$DONOTEVALUATE();
+do function g() {} while (false)
+
diff --git a/js/src/tests/test262/language/block-scope/syntax/function-declarations/in-statement-position-for-statement.js b/js/src/tests/test262/language/block-scope/syntax/function-declarations/in-statement-position-for-statement.js
new file mode 100644
index 0000000000..f69e43ff18
--- /dev/null
+++ b/js/src/tests/test262/language/block-scope/syntax/function-declarations/in-statement-position-for-statement.js
@@ -0,0 +1,16 @@
+// |reftest| error:SyntaxError
+// Copyright (C) 2011 the V8 project authors. All rights reserved.
+// This code is governed by the BSD license found in the LICENSE file.
+/*---
+es6id: 13.1
+description: >
+ function declarations in statement position:
+ for ( ;;) Statement
+negative:
+ phase: parse
+ type: SyntaxError
+---*/
+
+$DONOTEVALUATE();
+for (;false;) function g() {}
+
diff --git a/js/src/tests/test262/language/block-scope/syntax/function-declarations/in-statement-position-if-expression-statement-else-statement-strict.js b/js/src/tests/test262/language/block-scope/syntax/function-declarations/in-statement-position-if-expression-statement-else-statement-strict.js
new file mode 100644
index 0000000000..548fffc8fb
--- /dev/null
+++ b/js/src/tests/test262/language/block-scope/syntax/function-declarations/in-statement-position-if-expression-statement-else-statement-strict.js
@@ -0,0 +1,18 @@
+// |reftest| error:SyntaxError
+'use strict';
+// Copyright (C) 2011 the V8 project authors. All rights reserved.
+// This code is governed by the BSD license found in the LICENSE file.
+/*---
+es6id: 13.1
+description: >
+ function declarations in statement position in strict mode:
+ if ( Expression ) Statement else Statement
+negative:
+ phase: parse
+ type: SyntaxError
+flags: [onlyStrict]
+---*/
+
+$DONOTEVALUATE();
+if (true) {} else function g() {}
+
diff --git a/js/src/tests/test262/language/block-scope/syntax/function-declarations/in-statement-position-if-expression-statement-strict.js b/js/src/tests/test262/language/block-scope/syntax/function-declarations/in-statement-position-if-expression-statement-strict.js
new file mode 100644
index 0000000000..63d057e96d
--- /dev/null
+++ b/js/src/tests/test262/language/block-scope/syntax/function-declarations/in-statement-position-if-expression-statement-strict.js
@@ -0,0 +1,18 @@
+// |reftest| error:SyntaxError
+'use strict';
+// Copyright (C) 2011 the V8 project authors. All rights reserved.
+// This code is governed by the BSD license found in the LICENSE file.
+/*---
+es6id: 13.1
+description: >
+ function declarations in statement position in strict mode:
+ if ( Expression ) Statement
+negative:
+ phase: parse
+ type: SyntaxError
+flags: [onlyStrict]
+---*/
+
+$DONOTEVALUATE();
+if (true) function g() {}
+
diff --git a/js/src/tests/test262/language/block-scope/syntax/function-declarations/in-statement-position-while-expression-statement.js b/js/src/tests/test262/language/block-scope/syntax/function-declarations/in-statement-position-while-expression-statement.js
new file mode 100644
index 0000000000..69063f05f3
--- /dev/null
+++ b/js/src/tests/test262/language/block-scope/syntax/function-declarations/in-statement-position-while-expression-statement.js
@@ -0,0 +1,16 @@
+// |reftest| error:SyntaxError
+// Copyright (C) 2011 the V8 project authors. All rights reserved.
+// This code is governed by the BSD license found in the LICENSE file.
+/*---
+es6id: 13.1
+description: >
+ function declarations in statement position:
+ while ( Expression ) Statement
+negative:
+ phase: parse
+ type: SyntaxError
+---*/
+
+$DONOTEVALUATE();
+while (false) function g() {}
+
diff --git a/js/src/tests/test262/language/block-scope/syntax/function-declarations/shell.js b/js/src/tests/test262/language/block-scope/syntax/function-declarations/shell.js
new file mode 100644
index 0000000000..e69de29bb2
--- /dev/null
+++ b/js/src/tests/test262/language/block-scope/syntax/function-declarations/shell.js
diff --git a/js/src/tests/test262/language/block-scope/syntax/redeclaration-global/allowed-to-declare-function-with-function-declaration.js b/js/src/tests/test262/language/block-scope/syntax/redeclaration-global/allowed-to-declare-function-with-function-declaration.js
new file mode 100644
index 0000000000..a690fce961
--- /dev/null
+++ b/js/src/tests/test262/language/block-scope/syntax/redeclaration-global/allowed-to-declare-function-with-function-declaration.js
@@ -0,0 +1,12 @@
+// Copyright (C) 2011 the V8 project authors. All rights reserved.
+// This code is governed by the BSD license found in the LICENSE file.
+/*---
+es6id: 13.1
+description: >
+ redeclaration outermost:
+ allowed to declare function with function declaration
+---*/
+function f() {}
+
+
+reportCompare(0, 0);
diff --git a/js/src/tests/test262/language/block-scope/syntax/redeclaration-global/allowed-to-redeclare-function-declaration-with-var.js b/js/src/tests/test262/language/block-scope/syntax/redeclaration-global/allowed-to-redeclare-function-declaration-with-var.js
new file mode 100644
index 0000000000..0a935e2eed
--- /dev/null
+++ b/js/src/tests/test262/language/block-scope/syntax/redeclaration-global/allowed-to-redeclare-function-declaration-with-var.js
@@ -0,0 +1,12 @@
+// Copyright (C) 2011 the V8 project authors. All rights reserved.
+// This code is governed by the BSD license found in the LICENSE file.
+/*---
+es6id: 13.1
+description: >
+ redeclaration outermost:
+ allowed to redeclare function declaration with var
+---*/
+function f() {} var f;
+
+
+reportCompare(0, 0);
diff --git a/js/src/tests/test262/language/block-scope/syntax/redeclaration-global/allowed-to-redeclare-var-with-function-declaration.js b/js/src/tests/test262/language/block-scope/syntax/redeclaration-global/allowed-to-redeclare-var-with-function-declaration.js
new file mode 100644
index 0000000000..84dc183b7f
--- /dev/null
+++ b/js/src/tests/test262/language/block-scope/syntax/redeclaration-global/allowed-to-redeclare-var-with-function-declaration.js
@@ -0,0 +1,12 @@
+// Copyright (C) 2011 the V8 project authors. All rights reserved.
+// This code is governed by the BSD license found in the LICENSE file.
+/*---
+es6id: 13.1
+description: >
+ redeclaration outermost:
+ allowed to redeclare var with function declaration
+---*/
+var f; function f() {}
+
+
+reportCompare(0, 0);
diff --git a/js/src/tests/test262/language/block-scope/syntax/redeclaration-global/browser.js b/js/src/tests/test262/language/block-scope/syntax/redeclaration-global/browser.js
new file mode 100644
index 0000000000..e69de29bb2
--- /dev/null
+++ b/js/src/tests/test262/language/block-scope/syntax/redeclaration-global/browser.js
diff --git a/js/src/tests/test262/language/block-scope/syntax/redeclaration-global/shell.js b/js/src/tests/test262/language/block-scope/syntax/redeclaration-global/shell.js
new file mode 100644
index 0000000000..e69de29bb2
--- /dev/null
+++ b/js/src/tests/test262/language/block-scope/syntax/redeclaration-global/shell.js
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; }
diff --git a/js/src/tests/test262/language/block-scope/syntax/shell.js b/js/src/tests/test262/language/block-scope/syntax/shell.js
new file mode 100644
index 0000000000..e69de29bb2
--- /dev/null
+++ b/js/src/tests/test262/language/block-scope/syntax/shell.js