diff --git a/test/built-ins/RegExp/named-groups/non-unicode-malformed.js b/test/built-ins/RegExp/named-groups/non-unicode-malformed.js
deleted file mode 100644
index 37d47a692a2acf2c8ad2b4db9d6c70de3828d52c..0000000000000000000000000000000000000000
--- a/test/built-ins/RegExp/named-groups/non-unicode-malformed.js
+++ /dev/null
@@ -1,35 +0,0 @@
-// Copyright 2017 the V8 project authors. All rights reserved.
-// This code is governed by the BSD license found in the LICENSE file.
-
-/*---
-description: >
-  Named groups in Unicode RegExps have some syntax errors and some
-  compatibility escape fallback behavior.
-esid: prod-GroupSpecifier
-features: [regexp-named-groups]
-includes: [compareArray.js]
----*/
-
-assert.throws(SyntaxError, () => eval("/(?<>a)/"));
-assert.throws(SyntaxError, () => eval("/(?<aa)/"));
-assert.throws(SyntaxError, () => eval("/(?<42a>a)/"));
-assert.throws(SyntaxError, () => eval("/(?<:a>a)/"));
-assert.throws(SyntaxError, () => eval("/(?<a:>a)/"));
-assert.throws(SyntaxError, () => eval("/(?<a>a)(?<a>a)/"));
-assert.throws(SyntaxError, () => eval("/(?<a>a)(?<b>b)(?<a>a)/"));
-
-assert.throws(SyntaxError, () => eval("/(?<a>.)\\k/"));
-assert.throws(SyntaxError, () => eval("/(?<a>.)\\k<a/"));
-assert.throws(SyntaxError, () => eval("/(?<a>.)\\k<>/"));
-assert.throws(SyntaxError, () => eval("/(?<a>.)\\k<b>/"));
-assert.throws(SyntaxError, () => eval("/(?<a>a)\\k<ab>/"));
-assert.throws(SyntaxError, () => eval("/(?<ab>a)\\k<a>/"));
-assert.throws(SyntaxError, () => eval("/\\k<a>(?<ab>a)/"));
-assert.throws(SyntaxError, () => eval("/\\k<a(?<a>a)/"));
-
-// A couple of corner cases around '\k' as named back-references vs. identity
-// escapes.
-assert(/\k<a>(?<a>x)/.test("x"));
-assert.throws(SyntaxError, () => eval("/\\k<a>(?<b>x)/"));
-assert.throws(SyntaxError, () => eval("/\\k<a(?<a>.)/"));
-assert.throws(SyntaxError, () => eval("/\\k(?<a>.)/"));
diff --git a/test/built-ins/RegExp/named-groups/non-unicode-property-names.js b/test/built-ins/RegExp/named-groups/non-unicode-property-names.js
index 9c02d0b5170be6aaa4aeaf060e11d09757e49988..4f062f7fb1b1f04bd86dad3c0cadbf524df02d8a 100644
--- a/test/built-ins/RegExp/named-groups/non-unicode-property-names.js
+++ b/test/built-ins/RegExp/named-groups/non-unicode-property-names.js
@@ -5,40 +5,19 @@
 description: Exotic named group names in non-Unicode RegExps
 esid: prod-GroupSpecifier
 features: [regexp-named-groups]
-includes: [compareArray.js]
 ---*/
 
 assert.sameValue("a", /(?<Ï€>a)/.exec("bab").groups.Ï€);
-assert.throws(SyntaxError, () => eval('/(?<\\u{03C0}>a)/'), "\\u{} escapes allowed only in Unicode mode");
 assert.sameValue("a", /(?<Ï€>a)/.exec("bab").groups.\u03C0);
 assert.sameValue("a", /(?<$>a)/.exec("bab").groups.$);
 assert.sameValue("a", /(?<_>a)/.exec("bab").groups._);
-assert.throws(SyntaxError, () => eval('/(?<$𐒤>a)/'), "Individual surrogates not in ID_Continue");
 assert.sameValue("a", /(?<_\u200C>a)/.exec("bab").groups._\u200C);
 assert.sameValue("a", /(?<_\u200D>a)/.exec("bab").groups._\u200D);
 assert.sameValue("a", /(?<ಠ_ಠ>a)/.exec("bab").groups.ಠ_ಠ);
-assert.throws(SyntaxError, () => eval('/(?<❤>a)/'));
-assert.throws(SyntaxError, () => eval('/(?<𐒤>a)/'), "Individual surrogate not in ID_Start.");
 
 // Unicode escapes in capture names.
-assert.throws(SyntaxError, () => eval("/(?<a\\uD801\uDCA4>.)/"));
-assert.throws(SyntaxError, () => eval("/(?<a\\uD801>.)/"));
-assert.throws(SyntaxError, () => eval("/(?<a\\uDCA4>.)/"));
 assert(/(?<\u0041>.)/.test("a"));
-assert.throws(SyntaxError, () => eval("/(?<a\\u{104A4}>.)/"));
-assert.throws(SyntaxError, () => eval("/(?<a\\u{10FFFF}>.)/"));
-assert.throws(SyntaxError, () => eval("/(?<a\uD801>.)/"), "Lea");
-assert.throws(SyntaxError, () => eval("/(?<a\uDCA4>.)/"), "Trai");
 assert(RegExp("(?<\u{0041}>.)").test("a"), "Non-surrogate");
 
-// Bracketed escapes are not allowed;
 // 4-char escapes must be the proper ID_Start/ID_Continue
-assert.throws(SyntaxError, () => eval("/(?<a\\uD801>.)/"), "Lead");
-assert.throws(SyntaxError, () => eval("/(?<a\\uDCA4>.)/"), "Trail");
-assert.throws(SyntaxError, () => eval("/(?<\\u{0041}>.)/"), "Non-surrogate");
-assert.throws(SyntaxError, () => eval("/(?<a\\u{104A4}>.)/"), "Surrogate, ID_Continue");
 assert(RegExp("(?<\\u0041>.)").test("a"), "Non-surrogate");
-
-// Backslash is not allowed as ID_Start and ID_Continue
-assert.throws(SyntaxError, () => eval("/(?<\\>.)/"), "'\' misclassified as ID_Start");
-assert.throws(SyntaxError, () => eval("/(?<a\\>.)/"), "'\' misclassified as ID_Continue");
diff --git a/test/built-ins/RegExp/named-groups/unicode-malformed.js b/test/built-ins/RegExp/named-groups/unicode-malformed.js
deleted file mode 100644
index 5c9c131a4857aec2ff24b9f1d580b4d218c87cdb..0000000000000000000000000000000000000000
--- a/test/built-ins/RegExp/named-groups/unicode-malformed.js
+++ /dev/null
@@ -1,29 +0,0 @@
-// Copyright 2017 the V8 project authors. All rights reserved.
-// This code is governed by the BSD license found in the LICENSE file.
-
-/*---
-description: Various syntax errors for Unicode RegExps containing named groups
-esid: prod-GroupSpecifier
-features: [regexp-named-groups]
----*/
-
-assert.throws(SyntaxError, () => eval("/(?<>a)/u"), "Empty name");
-assert.throws(SyntaxError, () => eval("/(?<aa)/u"), "Unterminated name");
-assert.throws(SyntaxError, () => eval("/(?<42a>a)/u"), "Name starting with digits");
-assert.throws(SyntaxError, () => eval("/(?<:a>a)/u"), "Name starting with invalid char");
-assert.throws(SyntaxError, () => eval("/(?<a:>a)/u"), "Name containing with invalid char");
-assert.throws(SyntaxError, () => eval("/(?<a>a)(?<a>a)/u"), "Duplicate name");
-assert.throws(SyntaxError, () => eval("/(?<a>a)(?<b>b)(?<a>a)/u"), "Duplicate name");
-assert.throws(SyntaxError, () => eval("/\\k<a>/u"), "Invalid reference");
-assert.throws(SyntaxError, () => eval("/\\k<a/u"), "Unterminated reference");
-assert.throws(SyntaxError, () => eval("/\\k<>/u"), "Empty reference");
-assert.throws(SyntaxError, () => eval("/\\k/u"), "Lone \k");
-assert.throws(SyntaxError, () => eval("/(?<a>.)\\k/u"), "Lone \k");
-assert.throws(SyntaxError, () => eval("/(?<a>.)\\k<a/u"), "Unterminated reference");
-assert.throws(SyntaxError, () => eval("/(?<a>.)\\k<>/u"), "Empty reference");
-assert.throws(SyntaxError, () => eval("/(?<a>.)\\k<b>/u"), "Invalid reference");
-assert.throws(SyntaxError, () => eval("/(?<a>a)\\k<ab>/u"), "Invalid reference");
-assert.throws(SyntaxError, () => eval("/(?<ab>a)\\k<a>/u"), "Invalid reference");
-assert.throws(SyntaxError, () => eval("/\\k<a>(?<ab>a)/u"), "Invalid reference");
-assert.throws(SyntaxError, () => eval("/(?<a>\\a)/u"), "Identity escape in capture");
-
diff --git a/test/built-ins/RegExp/named-groups/unicode-property-names.js b/test/built-ins/RegExp/named-groups/unicode-property-names.js
index 24e4a6ade9c9dace21ea165a0127464768c30b3e..27bf125746ce83d6166eb858985e237a23cf96e3 100644
--- a/test/built-ins/RegExp/named-groups/unicode-property-names.js
+++ b/test/built-ins/RegExp/named-groups/unicode-property-names.js
@@ -17,30 +17,14 @@ assert.sameValue("a", /(?<$𐒤>a)/u.exec("bab").groups.$𐒤);
 assert.sameValue("a", /(?<_\u200C>a)/u.exec("bab").groups._\u200C);
 assert.sameValue("a", /(?<_\u200D>a)/u.exec("bab").groups._\u200D);
 assert.sameValue("a", /(?<ಠ_ಠ>a)/u.exec("bab").groups.ಠ_ಠ);
-assert.throws(SyntaxError, () => eval('/(?<❤>a)/u'));
-assert.throws(SyntaxError, () => eval('/(?<𐒤>a)/u'), "ID_Continue but not ID_Start.");
 
 // Unicode escapes in capture names.
 assert(/(?<a\uD801\uDCA4>.)/u.test("a"), "\\u Lead \\u Trail");
-assert.throws(SyntaxError, () => eval("/(?<a\\uD801>.)/u"), "\\u Lea");
-assert.throws(SyntaxError, () => eval("/(?<a\\uDCA4>.)/u"), "\\u Trai");
 assert(/(?<\u0041>.)/u.test("a"), "\\u NonSurrogate");
 assert(/(?<\u{0041}>.)/u.test("a"), "\\u{ Non-surrogate }");
 assert(/(?<a\u{104A4}>.)/u.test("a"), "\\u{ Surrogate, ID_Continue }");
-assert.throws(SyntaxError, () => eval("/(?<a\\u{110000}>.)/u"), "\\u{ Out-of-bounds ");
-assert.throws(SyntaxError, () => eval("/(?<a\uD801>.)/u"), "Lea");
-assert.throws(SyntaxError, () => eval("/(?<a\uDCA4>.)/u"), "Trai");
 assert(RegExp("(?<\u{0041}>.)", "u").test("a"), "Non-surrogate");
 assert(RegExp("(?<a\u{104A4}>.)", "u").test("a"), "Surrogate,ID_Continue");
-
-// Bracketed escapes are not allowed;
-// 4-char escapes must be the proper ID_Start/ID_Continue
-assert.throws(SyntaxError, () => eval("/(?<a\\uD801>.)/u"), "Lead");
-assert.throws(SyntaxError, () => eval("/(?<a\\uDCA4>.)/u"), "Trail");
 assert((/(?<\u{0041}>.)/u).test("a"), "Non-surrogate");
 assert(/(?<a\u{104A4}>.)/u.test("a"), "Surrogate, ID_Continue");
 assert(RegExp("(?<\\u0041>.)", "u").test("a"), "Non-surrogate");
-
-// Backslash is not allowed as ID_Start and ID_Continue
-assert.throws(SyntaxError, () => eval("/(?<\\>.)/u"), "'\' misclassified as ID_Start");
-assert.throws(SyntaxError, () => eval("/(?<a\\>.)/u"), "'\' misclassified as ID_Continue");
diff --git a/test/language/literals/regexp/named-groups/forward-reference.js b/test/language/literals/regexp/named-groups/forward-reference.js
new file mode 100644
index 0000000000000000000000000000000000000000..a6dd3c37f2a5cae179c46c2de617f5e93181808b
--- /dev/null
+++ b/test/language/literals/regexp/named-groups/forward-reference.js
@@ -0,0 +1,10 @@
+// Copyright 2017 the V8 project authors. All rights reserved.
+// This code is governed by the BSD license found in the LICENSE file.
+
+/*---
+description: Named groups can be forward references.
+esid: sec-atomescape
+features: [regexp-named-groups]
+---*/
+
+assert(/\k<a>(?<a>x)/.test("x"));
diff --git a/test/language/literals/regexp/named-groups/invalid-dangling-groupname-2-u.js b/test/language/literals/regexp/named-groups/invalid-dangling-groupname-2-u.js
new file mode 100644
index 0000000000000000000000000000000000000000..264709e7d98316bed4bcb528308353b5df933890
--- /dev/null
+++ b/test/language/literals/regexp/named-groups/invalid-dangling-groupname-2-u.js
@@ -0,0 +1,20 @@
+// Copyright 2017 the V8 project authors. All rights reserved.
+// This code is governed by the BSD license found in the LICENSE file.
+
+/*---
+description: Group reference must have corresponding group.
+info: |
+  It is a Syntax Error if the enclosing Pattern does not contain a
+  GroupSpecifier with an enclosed RegExpIdentifierName whose StringValue
+  equals the StringValue of the RegExpIdentifierName of this production's
+  GroupName.
+esid: sec-patterns-static-semantics-early-errors
+negative:
+  phase: parse
+  type: SyntaxError
+features: [regexp-named-groups]
+---*/
+
+throw "Test262: This statement should not be evaluated.";
+
+/(?<a>a)\k<ab>/u;
diff --git a/test/language/literals/regexp/named-groups/invalid-dangling-groupname-2.js b/test/language/literals/regexp/named-groups/invalid-dangling-groupname-2.js
new file mode 100644
index 0000000000000000000000000000000000000000..ec03c951d73b6f6fe6182f0b59093be86465da73
--- /dev/null
+++ b/test/language/literals/regexp/named-groups/invalid-dangling-groupname-2.js
@@ -0,0 +1,20 @@
+// Copyright 2017 the V8 project authors. All rights reserved.
+// This code is governed by the BSD license found in the LICENSE file.
+
+/*---
+description: Group reference must have corresponding group.
+info: |
+  It is a Syntax Error if the enclosing Pattern does not contain a
+  GroupSpecifier with an enclosed RegExpIdentifierName whose StringValue
+  equals the StringValue of the RegExpIdentifierName of this production's
+  GroupName.
+esid: sec-patterns-static-semantics-early-errors
+negative:
+  phase: parse
+  type: SyntaxError
+features: [regexp-named-groups]
+---*/
+
+throw "Test262: This statement should not be evaluated.";
+
+/(?<a>a)\k<ab>/;
diff --git a/test/language/literals/regexp/named-groups/invalid-dangling-groupname-3-u.js b/test/language/literals/regexp/named-groups/invalid-dangling-groupname-3-u.js
new file mode 100644
index 0000000000000000000000000000000000000000..b0690b51679191580fc10dceeb44c87680576a07
--- /dev/null
+++ b/test/language/literals/regexp/named-groups/invalid-dangling-groupname-3-u.js
@@ -0,0 +1,20 @@
+// Copyright 2017 the V8 project authors. All rights reserved.
+// This code is governed by the BSD license found in the LICENSE file.
+
+/*---
+description: Group reference must have corresponding group.
+info: |
+  It is a Syntax Error if the enclosing Pattern does not contain a
+  GroupSpecifier with an enclosed RegExpIdentifierName whose StringValue
+  equals the StringValue of the RegExpIdentifierName of this production's
+  GroupName.
+esid: sec-patterns-static-semantics-early-errors
+negative:
+  phase: parse
+  type: SyntaxError
+features: [regexp-named-groups]
+---*/
+
+throw "Test262: This statement should not be evaluated.";
+
+/(?<ab>a)\k<a>/u;
diff --git a/test/language/literals/regexp/named-groups/invalid-dangling-groupname-3.js b/test/language/literals/regexp/named-groups/invalid-dangling-groupname-3.js
new file mode 100644
index 0000000000000000000000000000000000000000..48489ff58924185cc458539e6a6ffa45b7332fa7
--- /dev/null
+++ b/test/language/literals/regexp/named-groups/invalid-dangling-groupname-3.js
@@ -0,0 +1,20 @@
+// Copyright 2017 the V8 project authors. All rights reserved.
+// This code is governed by the BSD license found in the LICENSE file.
+
+/*---
+description: Group reference must have corresponding group.
+info: |
+  It is a Syntax Error if the enclosing Pattern does not contain a
+  GroupSpecifier with an enclosed RegExpIdentifierName whose StringValue
+  equals the StringValue of the RegExpIdentifierName of this production's
+  GroupName.
+esid: sec-patterns-static-semantics-early-errors
+negative:
+  phase: parse
+  type: SyntaxError
+features: [regexp-named-groups]
+---*/
+
+throw "Test262: This statement should not be evaluated.";
+
+/(?<ab>a)\k<a>/;
diff --git a/test/language/literals/regexp/named-groups/invalid-dangling-groupname-4-u.js b/test/language/literals/regexp/named-groups/invalid-dangling-groupname-4-u.js
new file mode 100644
index 0000000000000000000000000000000000000000..fecebf654e2d78d605bad804b404b1218f206604
--- /dev/null
+++ b/test/language/literals/regexp/named-groups/invalid-dangling-groupname-4-u.js
@@ -0,0 +1,20 @@
+// Copyright 2017 the V8 project authors. All rights reserved.
+// This code is governed by the BSD license found in the LICENSE file.
+
+/*---
+description: Group reference must have corresponding group.
+info: |
+  It is a Syntax Error if the enclosing Pattern does not contain a
+  GroupSpecifier with an enclosed RegExpIdentifierName whose StringValue
+  equals the StringValue of the RegExpIdentifierName of this production's
+  GroupName.
+esid: sec-patterns-static-semantics-early-errors
+negative:
+  phase: parse
+  type: SyntaxError
+features: [regexp-named-groups]
+---*/
+
+throw "Test262: This statement should not be evaluated.";
+
+/\k<a>(?<ab>a)/u;
diff --git a/test/language/literals/regexp/named-groups/invalid-dangling-groupname-4.js b/test/language/literals/regexp/named-groups/invalid-dangling-groupname-4.js
new file mode 100644
index 0000000000000000000000000000000000000000..fac6cad35ee31c81d161288c1b6466e8e71db5cb
--- /dev/null
+++ b/test/language/literals/regexp/named-groups/invalid-dangling-groupname-4.js
@@ -0,0 +1,20 @@
+// Copyright 2017 the V8 project authors. All rights reserved.
+// This code is governed by the BSD license found in the LICENSE file.
+
+/*---
+description: Group reference must have corresponding group.
+info: |
+  It is a Syntax Error if the enclosing Pattern does not contain a
+  GroupSpecifier with an enclosed RegExpIdentifierName whose StringValue
+  equals the StringValue of the RegExpIdentifierName of this production's
+  GroupName.
+esid: sec-patterns-static-semantics-early-errors
+negative:
+  phase: parse
+  type: SyntaxError
+features: [regexp-named-groups]
+---*/
+
+throw "Test262: This statement should not be evaluated.";
+
+/\k<a>(?<ab>a)/;
diff --git a/test/language/literals/regexp/named-groups/invalid-dangling-groupname-5.js b/test/language/literals/regexp/named-groups/invalid-dangling-groupname-5.js
new file mode 100644
index 0000000000000000000000000000000000000000..582bf29d8a4d17492c77eec19ea2d43fd89459a0
--- /dev/null
+++ b/test/language/literals/regexp/named-groups/invalid-dangling-groupname-5.js
@@ -0,0 +1,20 @@
+// Copyright 2017 the V8 project authors. All rights reserved.
+// This code is governed by the BSD license found in the LICENSE file.
+
+/*---
+description: Group reference must have corresponding group.
+info: |
+  It is a Syntax Error if the enclosing Pattern does not contain a
+  GroupSpecifier with an enclosed RegExpIdentifierName whose StringValue
+  equals the StringValue of the RegExpIdentifierName of this production's
+  GroupName.
+esid: sec-patterns-static-semantics-early-errors
+negative:
+  phase: parse
+  type: SyntaxError
+features: [regexp-named-groups]
+---*/
+
+throw "Test262: This statement should not be evaluated.";
+
+/\k<a>(?<b>x)/;
diff --git a/test/language/literals/regexp/named-groups/invalid-dangling-groupname-u.js b/test/language/literals/regexp/named-groups/invalid-dangling-groupname-u.js
new file mode 100644
index 0000000000000000000000000000000000000000..dd14be10abaa1d4a2df32b2cc685f7b9d7c19718
--- /dev/null
+++ b/test/language/literals/regexp/named-groups/invalid-dangling-groupname-u.js
@@ -0,0 +1,20 @@
+// Copyright 2017 the V8 project authors. All rights reserved.
+// This code is governed by the BSD license found in the LICENSE file.
+
+/*---
+description: Group reference must have corresponding group.
+info: |
+  It is a Syntax Error if the enclosing Pattern does not contain a
+  GroupSpecifier with an enclosed RegExpIdentifierName whose StringValue
+  equals the StringValue of the RegExpIdentifierName of this production's
+  GroupName.
+esid: sec-patterns-static-semantics-early-errors
+negative:
+  phase: parse
+  type: SyntaxError
+features: [regexp-named-groups]
+---*/
+
+throw "Test262: This statement should not be evaluated.";
+
+/(?<a>.)\k<b>/u;
diff --git a/test/language/literals/regexp/named-groups/invalid-dangling-groupname-without-group-u.js b/test/language/literals/regexp/named-groups/invalid-dangling-groupname-without-group-u.js
new file mode 100644
index 0000000000000000000000000000000000000000..004618ede4a1e718e513a9c77935de83b5260644
--- /dev/null
+++ b/test/language/literals/regexp/named-groups/invalid-dangling-groupname-without-group-u.js
@@ -0,0 +1,20 @@
+// Copyright 2017 the V8 project authors. All rights reserved.
+// This code is governed by the BSD license found in the LICENSE file.
+
+/*---
+description: Group reference must have corresponding group.
+info: |
+  It is a Syntax Error if the enclosing Pattern does not contain a
+  GroupSpecifier with an enclosed RegExpIdentifierName whose StringValue
+  equals the StringValue of the RegExpIdentifierName of this production's
+  GroupName.
+esid: sec-patterns-static-semantics-early-errors
+negative:
+  phase: parse
+  type: SyntaxError
+features: [regexp-named-groups]
+---*/
+
+throw "Test262: This statement should not be evaluated.";
+
+/\k<a>/u;
diff --git a/test/language/literals/regexp/named-groups/invalid-dangling-groupname.js b/test/language/literals/regexp/named-groups/invalid-dangling-groupname.js
new file mode 100644
index 0000000000000000000000000000000000000000..b215f8c46b14f754246a49ac66bbb1fb9926855e
--- /dev/null
+++ b/test/language/literals/regexp/named-groups/invalid-dangling-groupname.js
@@ -0,0 +1,20 @@
+// Copyright 2017 the V8 project authors. All rights reserved.
+// This code is governed by the BSD license found in the LICENSE file.
+
+/*---
+description: Group reference must have corresponding group.
+info: |
+  It is a Syntax Error if the enclosing Pattern does not contain a
+  GroupSpecifier with an enclosed RegExpIdentifierName whose StringValue
+  equals the StringValue of the RegExpIdentifierName of this production's
+  GroupName.
+esid: sec-patterns-static-semantics-early-errors
+negative:
+  phase: parse
+  type: SyntaxError
+features: [regexp-named-groups]
+---*/
+
+throw "Test262: This statement should not be evaluated.";
+
+/(?<a>.)\k<b>/;
diff --git a/test/language/literals/regexp/named-groups/invalid-duplicate-groupspecifier-2-u.js b/test/language/literals/regexp/named-groups/invalid-duplicate-groupspecifier-2-u.js
new file mode 100644
index 0000000000000000000000000000000000000000..70707a499fc432a22ba6d64123b2c06025c166dd
--- /dev/null
+++ b/test/language/literals/regexp/named-groups/invalid-duplicate-groupspecifier-2-u.js
@@ -0,0 +1,18 @@
+// Copyright 2017 the V8 project authors. All rights reserved.
+// This code is governed by the BSD license found in the LICENSE file.
+
+/*---
+description: GroupSpecifiers must be unique.
+info: |
+  It is a Syntax Error if Pattern contains multiple GroupSpecifiers
+  whose enclosed RegExpIdentifierNames have the same StringValue.
+esid: sec-patterns-static-semantics-early-errors
+negative:
+  phase: parse
+  type: SyntaxError
+features: [regexp-named-groups]
+---*/
+
+throw "Test262: This statement should not be evaluated.";
+
+/(?<a>a)(?<b>b)(?<a>a)/u;
diff --git a/test/language/literals/regexp/named-groups/invalid-duplicate-groupspecifier-2.js b/test/language/literals/regexp/named-groups/invalid-duplicate-groupspecifier-2.js
new file mode 100644
index 0000000000000000000000000000000000000000..1ca18d9242acceb040bb91d078b79383ed23156b
--- /dev/null
+++ b/test/language/literals/regexp/named-groups/invalid-duplicate-groupspecifier-2.js
@@ -0,0 +1,18 @@
+// Copyright 2017 the V8 project authors. All rights reserved.
+// This code is governed by the BSD license found in the LICENSE file.
+
+/*---
+description: GroupSpecifiers must be unique.
+info: |
+  It is a Syntax Error if Pattern contains multiple GroupSpecifiers
+  whose enclosed RegExpIdentifierNames have the same StringValue.
+esid: sec-patterns-static-semantics-early-errors
+negative:
+  phase: parse
+  type: SyntaxError
+features: [regexp-named-groups]
+---*/
+
+throw "Test262: This statement should not be evaluated.";
+
+/(?<a>a)(?<b>b)(?<a>a)/;
diff --git a/test/language/literals/regexp/named-groups/invalid-duplicate-groupspecifier-u.js b/test/language/literals/regexp/named-groups/invalid-duplicate-groupspecifier-u.js
new file mode 100644
index 0000000000000000000000000000000000000000..bac92214902c96a082a73e31f057c9630f29d8bd
--- /dev/null
+++ b/test/language/literals/regexp/named-groups/invalid-duplicate-groupspecifier-u.js
@@ -0,0 +1,18 @@
+// Copyright 2017 the V8 project authors. All rights reserved.
+// This code is governed by the BSD license found in the LICENSE file.
+
+/*---
+description: GroupSpecifiers must be unique.
+info: |
+  It is a Syntax Error if Pattern contains multiple GroupSpecifiers
+  whose enclosed RegExpIdentifierNames have the same StringValue.
+esid: sec-patterns-static-semantics-early-errors
+negative:
+  phase: parse
+  type: SyntaxError
+features: [regexp-named-groups]
+---*/
+
+throw "Test262: This statement should not be evaluated.";
+
+/(?<a>a)(?<a>a)/u;
diff --git a/test/language/literals/regexp/named-groups/invalid-duplicate-groupspecifier.js b/test/language/literals/regexp/named-groups/invalid-duplicate-groupspecifier.js
new file mode 100644
index 0000000000000000000000000000000000000000..1cbc8c2e27ea97bb69d18042763895bfa3a48f39
--- /dev/null
+++ b/test/language/literals/regexp/named-groups/invalid-duplicate-groupspecifier.js
@@ -0,0 +1,18 @@
+// Copyright 2017 the V8 project authors. All rights reserved.
+// This code is governed by the BSD license found in the LICENSE file.
+
+/*---
+description: GroupSpecifiers must be unique.
+info: |
+  It is a Syntax Error if Pattern contains multiple GroupSpecifiers
+  whose enclosed RegExpIdentifierNames have the same StringValue.
+esid: sec-patterns-static-semantics-early-errors
+negative:
+  phase: parse
+  type: SyntaxError
+features: [regexp-named-groups]
+---*/
+
+throw "Test262: This statement should not be evaluated.";
+
+/(?<a>a)(?<a>a)/;
diff --git a/test/language/literals/regexp/named-groups/invalid-empty-groupspecifier-u.js b/test/language/literals/regexp/named-groups/invalid-empty-groupspecifier-u.js
new file mode 100644
index 0000000000000000000000000000000000000000..44a86c1c5a57f4933c76b1203a916be4b747aa36
--- /dev/null
+++ b/test/language/literals/regexp/named-groups/invalid-empty-groupspecifier-u.js
@@ -0,0 +1,15 @@
+// Copyright 2017 the V8 project authors. All rights reserved.
+// This code is governed by the BSD license found in the LICENSE file.
+
+/*---
+description: GroupSpecifier must be identifier-like.
+esid: prod-GroupSpecifier
+negative:
+  phase: parse
+  type: SyntaxError
+features: [regexp-named-groups]
+---*/
+
+throw "Test262: This statement should not be evaluated.";
+
+/(?<>a)/u;
diff --git a/test/language/literals/regexp/named-groups/invalid-empty-groupspecifier.js b/test/language/literals/regexp/named-groups/invalid-empty-groupspecifier.js
new file mode 100644
index 0000000000000000000000000000000000000000..1050d96060dc3a2ddb6bf6f011cd24a43b4b14d7
--- /dev/null
+++ b/test/language/literals/regexp/named-groups/invalid-empty-groupspecifier.js
@@ -0,0 +1,15 @@
+// Copyright 2017 the V8 project authors. All rights reserved.
+// This code is governed by the BSD license found in the LICENSE file.
+
+/*---
+description: GroupSpecifier must be identifier-like.
+esid: prod-GroupSpecifier
+negative:
+  phase: parse
+  type: SyntaxError
+features: [regexp-named-groups]
+---*/
+
+throw "Test262: This statement should not be evaluated.";
+
+/(?<>a)/;
diff --git a/test/language/literals/regexp/named-groups/invalid-identity-escape-in-capture-u.js b/test/language/literals/regexp/named-groups/invalid-identity-escape-in-capture-u.js
new file mode 100644
index 0000000000000000000000000000000000000000..0f46b0e1dcef6604bcddee64401e172d42eefb13
--- /dev/null
+++ b/test/language/literals/regexp/named-groups/invalid-identity-escape-in-capture-u.js
@@ -0,0 +1,15 @@
+// Copyright 2017 the V8 project authors. All rights reserved.
+// This code is governed by the BSD license found in the LICENSE file.
+
+/*---
+description: GroupName is `< RegExpIdentifierName >`.
+esid: prod-GroupName
+negative:
+  phase: parse
+  type: SyntaxError
+features: [regexp-named-groups]
+---*/
+
+throw "Test262: This statement should not be evaluated.";
+
+/(?<a>\a)/u;
diff --git a/test/language/literals/regexp/named-groups/invalid-incomplete-groupname-2-u.js b/test/language/literals/regexp/named-groups/invalid-incomplete-groupname-2-u.js
new file mode 100644
index 0000000000000000000000000000000000000000..ed0d2ff0197139902347c13c9f5ed3d62a09f391
--- /dev/null
+++ b/test/language/literals/regexp/named-groups/invalid-incomplete-groupname-2-u.js
@@ -0,0 +1,15 @@
+// Copyright 2017 the V8 project authors. All rights reserved.
+// This code is governed by the BSD license found in the LICENSE file.
+
+/*---
+description: GroupName is `< RegExpIdentifierName >`.
+esid: prod-GroupName
+negative:
+  phase: parse
+  type: SyntaxError
+features: [regexp-named-groups]
+---*/
+
+throw "Test262: This statement should not be evaluated.";
+
+/(?<a>.)\k<a/u;
diff --git a/test/language/literals/regexp/named-groups/invalid-incomplete-groupname-2.js b/test/language/literals/regexp/named-groups/invalid-incomplete-groupname-2.js
new file mode 100644
index 0000000000000000000000000000000000000000..a5532fea0d3959c1f6a1d12b504911444be4de9c
--- /dev/null
+++ b/test/language/literals/regexp/named-groups/invalid-incomplete-groupname-2.js
@@ -0,0 +1,15 @@
+// Copyright 2017 the V8 project authors. All rights reserved.
+// This code is governed by the BSD license found in the LICENSE file.
+
+/*---
+description: GroupName is `< RegExpIdentifierName >`.
+esid: prod-GroupName
+negative:
+  phase: parse
+  type: SyntaxError
+features: [regexp-named-groups]
+---*/
+
+throw "Test262: This statement should not be evaluated.";
+
+/(?<a>.)\k<a/;
diff --git a/test/language/literals/regexp/named-groups/invalid-incomplete-groupname-3-u.js b/test/language/literals/regexp/named-groups/invalid-incomplete-groupname-3-u.js
new file mode 100644
index 0000000000000000000000000000000000000000..883c3b0d8d7cbb5bf3bf28edfc5a7a7325372c7f
--- /dev/null
+++ b/test/language/literals/regexp/named-groups/invalid-incomplete-groupname-3-u.js
@@ -0,0 +1,15 @@
+// Copyright 2017 the V8 project authors. All rights reserved.
+// This code is governed by the BSD license found in the LICENSE file.
+
+/*---
+description: GroupName is `< RegExpIdentifierName >`.
+esid: prod-GroupName
+negative:
+  phase: parse
+  type: SyntaxError
+features: [regexp-named-groups]
+---*/
+
+throw "Test262: This statement should not be evaluated.";
+
+/(?<a>.)\k<>/u;
diff --git a/test/language/literals/regexp/named-groups/invalid-incomplete-groupname-3.js b/test/language/literals/regexp/named-groups/invalid-incomplete-groupname-3.js
new file mode 100644
index 0000000000000000000000000000000000000000..9fe83adaae0c6b6a55da04158be14a21c5c5bbb6
--- /dev/null
+++ b/test/language/literals/regexp/named-groups/invalid-incomplete-groupname-3.js
@@ -0,0 +1,15 @@
+// Copyright 2017 the V8 project authors. All rights reserved.
+// This code is governed by the BSD license found in the LICENSE file.
+
+/*---
+description: GroupName is `< RegExpIdentifierName >`.
+esid: prod-GroupName
+negative:
+  phase: parse
+  type: SyntaxError
+features: [regexp-named-groups]
+---*/
+
+throw "Test262: This statement should not be evaluated.";
+
+/(?<a>.)\k<>/;
diff --git a/test/language/literals/regexp/named-groups/invalid-incomplete-groupname-4.js b/test/language/literals/regexp/named-groups/invalid-incomplete-groupname-4.js
new file mode 100644
index 0000000000000000000000000000000000000000..0406bad50917e4eee8386ba18681fab6b4fbf0a8
--- /dev/null
+++ b/test/language/literals/regexp/named-groups/invalid-incomplete-groupname-4.js
@@ -0,0 +1,15 @@
+// Copyright 2017 the V8 project authors. All rights reserved.
+// This code is governed by the BSD license found in the LICENSE file.
+
+/*---
+description: GroupName is `< RegExpIdentifierName >`.
+esid: prod-GroupName
+negative:
+  phase: parse
+  type: SyntaxError
+features: [regexp-named-groups]
+---*/
+
+throw "Test262: This statement should not be evaluated.";
+
+/\k<a(?<a>a)/;
diff --git a/test/language/literals/regexp/named-groups/invalid-incomplete-groupname-5.js b/test/language/literals/regexp/named-groups/invalid-incomplete-groupname-5.js
new file mode 100644
index 0000000000000000000000000000000000000000..5f46988659700ed653ef8a9130cca2b3bb26abe4
--- /dev/null
+++ b/test/language/literals/regexp/named-groups/invalid-incomplete-groupname-5.js
@@ -0,0 +1,15 @@
+// Copyright 2017 the V8 project authors. All rights reserved.
+// This code is governed by the BSD license found in the LICENSE file.
+
+/*---
+description: GroupName is `< RegExpIdentifierName >`.
+esid: prod-GroupName
+negative:
+  phase: parse
+  type: SyntaxError
+features: [regexp-named-groups]
+---*/
+
+throw "Test262: This statement should not be evaluated.";
+
+/\k<a(?<a>.)/;
diff --git a/test/language/literals/regexp/named-groups/invalid-incomplete-groupname-6.js b/test/language/literals/regexp/named-groups/invalid-incomplete-groupname-6.js
new file mode 100644
index 0000000000000000000000000000000000000000..88f90393861c61bee7af32e12a3bcfc45c397f54
--- /dev/null
+++ b/test/language/literals/regexp/named-groups/invalid-incomplete-groupname-6.js
@@ -0,0 +1,15 @@
+// Copyright 2017 the V8 project authors. All rights reserved.
+// This code is governed by the BSD license found in the LICENSE file.
+
+/*---
+description: GroupName is `< RegExpIdentifierName >`.
+esid: prod-GroupName
+negative:
+  phase: parse
+  type: SyntaxError
+features: [regexp-named-groups]
+---*/
+
+throw "Test262: This statement should not be evaluated.";
+
+/\k(?<a>.)/;
diff --git a/test/language/literals/regexp/named-groups/invalid-incomplete-groupname-u.js b/test/language/literals/regexp/named-groups/invalid-incomplete-groupname-u.js
new file mode 100644
index 0000000000000000000000000000000000000000..636b69a5788cac3ab9c73747e184b6ea31aaecaa
--- /dev/null
+++ b/test/language/literals/regexp/named-groups/invalid-incomplete-groupname-u.js
@@ -0,0 +1,15 @@
+// Copyright 2017 the V8 project authors. All rights reserved.
+// This code is governed by the BSD license found in the LICENSE file.
+
+/*---
+description: GroupName is `< RegExpIdentifierName >`.
+esid: prod-GroupName
+negative:
+  phase: parse
+  type: SyntaxError
+features: [regexp-named-groups]
+---*/
+
+throw "Test262: This statement should not be evaluated.";
+
+/(?<a>.)\k/u;
diff --git a/test/language/literals/regexp/named-groups/invalid-incomplete-groupname-without-group-2-u.js b/test/language/literals/regexp/named-groups/invalid-incomplete-groupname-without-group-2-u.js
new file mode 100644
index 0000000000000000000000000000000000000000..d953a4287724c2ea43902afc7fd0f2a9f1591ad6
--- /dev/null
+++ b/test/language/literals/regexp/named-groups/invalid-incomplete-groupname-without-group-2-u.js
@@ -0,0 +1,15 @@
+// Copyright 2017 the V8 project authors. All rights reserved.
+// This code is governed by the BSD license found in the LICENSE file.
+
+/*---
+description: GroupName is `< RegExpIdentifierName >`.
+esid: prod-GroupName
+negative:
+  phase: parse
+  type: SyntaxError
+features: [regexp-named-groups]
+---*/
+
+throw "Test262: This statement should not be evaluated.";
+
+/\k<>/u;
diff --git a/test/language/literals/regexp/named-groups/invalid-incomplete-groupname-without-group-3-u.js b/test/language/literals/regexp/named-groups/invalid-incomplete-groupname-without-group-3-u.js
new file mode 100644
index 0000000000000000000000000000000000000000..f8c41abbfec67b7593251a78581faf11133c930b
--- /dev/null
+++ b/test/language/literals/regexp/named-groups/invalid-incomplete-groupname-without-group-3-u.js
@@ -0,0 +1,15 @@
+// Copyright 2017 the V8 project authors. All rights reserved.
+// This code is governed by the BSD license found in the LICENSE file.
+
+/*---
+description: GroupName is `< RegExpIdentifierName >`.
+esid: prod-GroupName
+negative:
+  phase: parse
+  type: SyntaxError
+features: [regexp-named-groups]
+---*/
+
+throw "Test262: This statement should not be evaluated.";
+
+/\k/u;
diff --git a/test/language/literals/regexp/named-groups/invalid-incomplete-groupname-without-group-u.js b/test/language/literals/regexp/named-groups/invalid-incomplete-groupname-without-group-u.js
new file mode 100644
index 0000000000000000000000000000000000000000..b7e22617e6ffeaa0f5dd958f941f322b980d10b4
--- /dev/null
+++ b/test/language/literals/regexp/named-groups/invalid-incomplete-groupname-without-group-u.js
@@ -0,0 +1,15 @@
+// Copyright 2017 the V8 project authors. All rights reserved.
+// This code is governed by the BSD license found in the LICENSE file.
+
+/*---
+description: GroupName is `< RegExpIdentifierName >`.
+esid: prod-GroupName
+negative:
+  phase: parse
+  type: SyntaxError
+features: [regexp-named-groups]
+---*/
+
+throw "Test262: This statement should not be evaluated.";
+
+/\k<a/u;
diff --git a/test/language/literals/regexp/named-groups/invalid-incomplete-groupname.js b/test/language/literals/regexp/named-groups/invalid-incomplete-groupname.js
new file mode 100644
index 0000000000000000000000000000000000000000..f660e1fa8d7d170cb861835fa8e4ecfe106e74ca
--- /dev/null
+++ b/test/language/literals/regexp/named-groups/invalid-incomplete-groupname.js
@@ -0,0 +1,15 @@
+// Copyright 2017 the V8 project authors. All rights reserved.
+// This code is governed by the BSD license found in the LICENSE file.
+
+/*---
+description: GroupName is `< RegExpIdentifierName >`.
+esid: prod-GroupName
+negative:
+  phase: parse
+  type: SyntaxError
+features: [regexp-named-groups]
+---*/
+
+throw "Test262: This statement should not be evaluated.";
+
+/(?<a>.)\k/;
diff --git a/test/language/literals/regexp/named-groups/invalid-lone-surrogate-groupname.js b/test/language/literals/regexp/named-groups/invalid-lone-surrogate-groupname.js
new file mode 100644
index 0000000000000000000000000000000000000000..7be757996b7b3e175999adf79c46560b4d50e117
--- /dev/null
+++ b/test/language/literals/regexp/named-groups/invalid-lone-surrogate-groupname.js
@@ -0,0 +1,13 @@
+// Copyright 2017 the V8 project authors. All rights reserved.
+// This code is governed by the BSD license found in the LICENSE file.
+
+/*---
+description: Lone surrogates in RegExp group names
+esid: prod-GroupSpecifier
+features: [regexp-named-groups]
+---*/
+
+assert.throws(SyntaxError, () => eval("/(?<a\uD801>.)/"), "Lead");
+assert.throws(SyntaxError, () => eval("/(?<a\uDCA4>.)/"), "Trail");
+assert.throws(SyntaxError, () => eval("/(?<a\uD801>.)/u"), "Lead with u flag");
+assert.throws(SyntaxError, () => eval("/(?<a\uDCA4>.)/u"), "Trail with u flag");
diff --git a/test/language/literals/regexp/named-groups/invalid-non-id-continue-groupspecifier-4-u.js b/test/language/literals/regexp/named-groups/invalid-non-id-continue-groupspecifier-4-u.js
new file mode 100644
index 0000000000000000000000000000000000000000..45b1ca633395e7e593fa49755de4a34c230e7b7e
--- /dev/null
+++ b/test/language/literals/regexp/named-groups/invalid-non-id-continue-groupspecifier-4-u.js
@@ -0,0 +1,15 @@
+// Copyright 2017 the V8 project authors. All rights reserved.
+// This code is governed by the BSD license found in the LICENSE file.
+
+/*---
+description: GroupSpecifier must be identifier-like.
+esid: prod-GroupSpecifier
+negative:
+  phase: parse
+  type: SyntaxError
+features: [regexp-named-groups]
+---*/
+
+throw "Test262: This statement should not be evaluated.";
+
+/(?<a\>.)/u;
diff --git a/test/language/literals/regexp/named-groups/invalid-non-id-continue-groupspecifier-4.js b/test/language/literals/regexp/named-groups/invalid-non-id-continue-groupspecifier-4.js
new file mode 100644
index 0000000000000000000000000000000000000000..027cac11ecf05044d23b580367ec38e122a156c3
--- /dev/null
+++ b/test/language/literals/regexp/named-groups/invalid-non-id-continue-groupspecifier-4.js
@@ -0,0 +1,15 @@
+// Copyright 2017 the V8 project authors. All rights reserved.
+// This code is governed by the BSD license found in the LICENSE file.
+
+/*---
+description: GroupSpecifier must be identifier-like.
+esid: prod-GroupSpecifier
+negative:
+  phase: parse
+  type: SyntaxError
+features: [regexp-named-groups]
+---*/
+
+throw "Test262: This statement should not be evaluated.";
+
+/(?<a\>.)/;
diff --git a/test/language/literals/regexp/named-groups/invalid-non-id-continue-groupspecifier.js b/test/language/literals/regexp/named-groups/invalid-non-id-continue-groupspecifier.js
new file mode 100644
index 0000000000000000000000000000000000000000..4e2096a35eba188f09a2bb2a84bdee6042b7e915
--- /dev/null
+++ b/test/language/literals/regexp/named-groups/invalid-non-id-continue-groupspecifier.js
@@ -0,0 +1,15 @@
+// Copyright 2017 the V8 project authors. All rights reserved.
+// This code is governed by the BSD license found in the LICENSE file.
+
+/*---
+description: GroupSpecifier must be identifier-like.
+esid: prod-GroupSpecifier
+negative:
+  phase: parse
+  type: SyntaxError
+features: [regexp-named-groups]
+---*/
+
+throw "Test262: This statement should not be evaluated.";
+
+/(?<$𐒤>a)/;
diff --git a/test/language/literals/regexp/named-groups/invalid-non-id-start-groupspecifier-2-u.js b/test/language/literals/regexp/named-groups/invalid-non-id-start-groupspecifier-2-u.js
new file mode 100644
index 0000000000000000000000000000000000000000..fdc877557281f9a32e83ce0375221b12851dc1e8
--- /dev/null
+++ b/test/language/literals/regexp/named-groups/invalid-non-id-start-groupspecifier-2-u.js
@@ -0,0 +1,15 @@
+// Copyright 2017 the V8 project authors. All rights reserved.
+// This code is governed by the BSD license found in the LICENSE file.
+
+/*---
+description: GroupSpecifier must be identifier-like.
+esid: prod-GroupSpecifier
+negative:
+  phase: parse
+  type: SyntaxError
+features: [regexp-named-groups]
+---*/
+
+throw "Test262: This statement should not be evaluated.";
+
+/(?<𐒤>a)/u;
diff --git a/test/language/literals/regexp/named-groups/invalid-non-id-start-groupspecifier-2.js b/test/language/literals/regexp/named-groups/invalid-non-id-start-groupspecifier-2.js
new file mode 100644
index 0000000000000000000000000000000000000000..64637b6a1c12add4f11d93b3e78c24f26e881530
--- /dev/null
+++ b/test/language/literals/regexp/named-groups/invalid-non-id-start-groupspecifier-2.js
@@ -0,0 +1,15 @@
+// Copyright 2017 the V8 project authors. All rights reserved.
+// This code is governed by the BSD license found in the LICENSE file.
+
+/*---
+description: GroupSpecifier must be identifier-like.
+esid: prod-GroupSpecifier
+negative:
+  phase: parse
+  type: SyntaxError
+features: [regexp-named-groups]
+---*/
+
+throw "Test262: This statement should not be evaluated.";
+
+/(?<𐒤>a)/;
diff --git a/test/language/literals/regexp/named-groups/invalid-non-id-start-groupspecifier-3.js b/test/language/literals/regexp/named-groups/invalid-non-id-start-groupspecifier-3.js
new file mode 100644
index 0000000000000000000000000000000000000000..a4644b015bb5e0c59da98796a67a523f116e3657
--- /dev/null
+++ b/test/language/literals/regexp/named-groups/invalid-non-id-start-groupspecifier-3.js
@@ -0,0 +1,15 @@
+// Copyright 2017 the V8 project authors. All rights reserved.
+// This code is governed by the BSD license found in the LICENSE file.
+
+/*---
+description: GroupSpecifier must be identifier-like.
+esid: prod-GroupSpecifier
+negative:
+  phase: parse
+  type: SyntaxError
+features: [regexp-named-groups]
+---*/
+
+throw "Test262: This statement should not be evaluated.";
+
+/(?<a\uD801\uDCA4>.)/;
diff --git a/test/language/literals/regexp/named-groups/invalid-non-id-start-groupspecifier-4-u.js b/test/language/literals/regexp/named-groups/invalid-non-id-start-groupspecifier-4-u.js
new file mode 100644
index 0000000000000000000000000000000000000000..af260334dbf103ab4826b1aa8a5b8a9d29bb683d
--- /dev/null
+++ b/test/language/literals/regexp/named-groups/invalid-non-id-start-groupspecifier-4-u.js
@@ -0,0 +1,15 @@
+// Copyright 2017 the V8 project authors. All rights reserved.
+// This code is governed by the BSD license found in the LICENSE file.
+
+/*---
+description: GroupSpecifier must be identifier-like.
+esid: prod-GroupSpecifier
+negative:
+  phase: parse
+  type: SyntaxError
+features: [regexp-named-groups]
+---*/
+
+throw "Test262: This statement should not be evaluated.";
+
+/(?<a\uD801>.)/u;
diff --git a/test/language/literals/regexp/named-groups/invalid-non-id-start-groupspecifier-4.js b/test/language/literals/regexp/named-groups/invalid-non-id-start-groupspecifier-4.js
new file mode 100644
index 0000000000000000000000000000000000000000..e840db055376e9310144e5b2aaf780976e2ce723
--- /dev/null
+++ b/test/language/literals/regexp/named-groups/invalid-non-id-start-groupspecifier-4.js
@@ -0,0 +1,15 @@
+// Copyright 2017 the V8 project authors. All rights reserved.
+// This code is governed by the BSD license found in the LICENSE file.
+
+/*---
+description: GroupSpecifier must be identifier-like.
+esid: prod-GroupSpecifier
+negative:
+  phase: parse
+  type: SyntaxError
+features: [regexp-named-groups]
+---*/
+
+throw "Test262: This statement should not be evaluated.";
+
+/(?<a\uD801>.)/;
diff --git a/test/language/literals/regexp/named-groups/invalid-non-id-start-groupspecifier-5-u.js b/test/language/literals/regexp/named-groups/invalid-non-id-start-groupspecifier-5-u.js
new file mode 100644
index 0000000000000000000000000000000000000000..fb3d9c414b928a4b474b04325bce57e6f90d78e2
--- /dev/null
+++ b/test/language/literals/regexp/named-groups/invalid-non-id-start-groupspecifier-5-u.js
@@ -0,0 +1,15 @@
+// Copyright 2017 the V8 project authors. All rights reserved.
+// This code is governed by the BSD license found in the LICENSE file.
+
+/*---
+description: GroupSpecifier must be identifier-like.
+esid: prod-GroupSpecifier
+negative:
+  phase: parse
+  type: SyntaxError
+features: [regexp-named-groups]
+---*/
+
+throw "Test262: This statement should not be evaluated.";
+
+/(?<a\uDCA4>.)/u;
diff --git a/test/language/literals/regexp/named-groups/invalid-non-id-start-groupspecifier-5.js b/test/language/literals/regexp/named-groups/invalid-non-id-start-groupspecifier-5.js
new file mode 100644
index 0000000000000000000000000000000000000000..38f70fc6dedfd08f1913c1395e046fe7b28e30cd
--- /dev/null
+++ b/test/language/literals/regexp/named-groups/invalid-non-id-start-groupspecifier-5.js
@@ -0,0 +1,15 @@
+// Copyright 2017 the V8 project authors. All rights reserved.
+// This code is governed by the BSD license found in the LICENSE file.
+
+/*---
+description: GroupSpecifier must be identifier-like.
+esid: prod-GroupSpecifier
+negative:
+  phase: parse
+  type: SyntaxError
+features: [regexp-named-groups]
+---*/
+
+throw "Test262: This statement should not be evaluated.";
+
+/(?<a\uDCA4>.)/;
diff --git a/test/language/literals/regexp/named-groups/invalid-non-id-start-groupspecifier-6.js b/test/language/literals/regexp/named-groups/invalid-non-id-start-groupspecifier-6.js
new file mode 100644
index 0000000000000000000000000000000000000000..f5cca3d30984afac7852ee9c0ce4a6bb7c6fd22b
--- /dev/null
+++ b/test/language/literals/regexp/named-groups/invalid-non-id-start-groupspecifier-6.js
@@ -0,0 +1,15 @@
+// Copyright 2017 the V8 project authors. All rights reserved.
+// This code is governed by the BSD license found in the LICENSE file.
+
+/*---
+description: GroupSpecifier must be identifier-like.
+esid: prod-GroupSpecifier
+negative:
+  phase: parse
+  type: SyntaxError
+features: [regexp-named-groups]
+---*/
+
+throw "Test262: This statement should not be evaluated.";
+
+/(?<a\u{104A4}>.)/;
diff --git a/test/language/literals/regexp/named-groups/invalid-non-id-start-groupspecifier-7.js b/test/language/literals/regexp/named-groups/invalid-non-id-start-groupspecifier-7.js
new file mode 100644
index 0000000000000000000000000000000000000000..59b7ded3467123d2c1530acd55ba155fd13c73f7
--- /dev/null
+++ b/test/language/literals/regexp/named-groups/invalid-non-id-start-groupspecifier-7.js
@@ -0,0 +1,15 @@
+// Copyright 2017 the V8 project authors. All rights reserved.
+// This code is governed by the BSD license found in the LICENSE file.
+
+/*---
+description: GroupSpecifier must be identifier-like.
+esid: prod-GroupSpecifier
+negative:
+  phase: parse
+  type: SyntaxError
+features: [regexp-named-groups]
+---*/
+
+throw "Test262: This statement should not be evaluated.";
+
+/(?<a\u{10FFFF}>.)/;
diff --git a/test/language/literals/regexp/named-groups/invalid-non-id-start-groupspecifier-8-u.js b/test/language/literals/regexp/named-groups/invalid-non-id-start-groupspecifier-8-u.js
new file mode 100644
index 0000000000000000000000000000000000000000..7796572c74aa050f84eb57c977a70dd2967e8aca
--- /dev/null
+++ b/test/language/literals/regexp/named-groups/invalid-non-id-start-groupspecifier-8-u.js
@@ -0,0 +1,15 @@
+// Copyright 2017 the V8 project authors. All rights reserved.
+// This code is governed by the BSD license found in the LICENSE file.
+
+/*---
+description: GroupSpecifier must be identifier-like.
+esid: prod-GroupSpecifier
+negative:
+  phase: parse
+  type: SyntaxError
+features: [regexp-named-groups]
+---*/
+
+throw "Test262: This statement should not be evaluated.";
+
+/(?<\>.)/u;
diff --git a/test/language/literals/regexp/named-groups/invalid-non-id-start-groupspecifier-8.js b/test/language/literals/regexp/named-groups/invalid-non-id-start-groupspecifier-8.js
new file mode 100644
index 0000000000000000000000000000000000000000..22f8452ce7cf0502e81ab732ff16bdd7203d89dd
--- /dev/null
+++ b/test/language/literals/regexp/named-groups/invalid-non-id-start-groupspecifier-8.js
@@ -0,0 +1,15 @@
+// Copyright 2017 the V8 project authors. All rights reserved.
+// This code is governed by the BSD license found in the LICENSE file.
+
+/*---
+description: GroupSpecifier must be identifier-like.
+esid: prod-GroupSpecifier
+negative:
+  phase: parse
+  type: SyntaxError
+features: [regexp-named-groups]
+---*/
+
+throw "Test262: This statement should not be evaluated.";
+
+/(?<\>.)/;
diff --git a/test/language/literals/regexp/named-groups/invalid-non-id-start-groupspecifier-9-u.js b/test/language/literals/regexp/named-groups/invalid-non-id-start-groupspecifier-9-u.js
new file mode 100644
index 0000000000000000000000000000000000000000..7fff1ae7905f1bebd0cc37d37f9dcca8a756e8af
--- /dev/null
+++ b/test/language/literals/regexp/named-groups/invalid-non-id-start-groupspecifier-9-u.js
@@ -0,0 +1,15 @@
+// Copyright 2017 the V8 project authors. All rights reserved.
+// This code is governed by the BSD license found in the LICENSE file.
+
+/*---
+description: GroupSpecifier must be identifier-like.
+esid: prod-GroupSpecifier
+negative:
+  phase: parse
+  type: SyntaxError
+features: [regexp-named-groups]
+---*/
+
+throw "Test262: This statement should not be evaluated.";
+
+/(?<a\u{110000}>.)/u;
diff --git a/test/language/literals/regexp/named-groups/invalid-non-id-start-groupspecifier-u.js b/test/language/literals/regexp/named-groups/invalid-non-id-start-groupspecifier-u.js
new file mode 100644
index 0000000000000000000000000000000000000000..ea4a41b5f83c877b18e26f5be02d44bf8fd6c31f
--- /dev/null
+++ b/test/language/literals/regexp/named-groups/invalid-non-id-start-groupspecifier-u.js
@@ -0,0 +1,15 @@
+// Copyright 2017 the V8 project authors. All rights reserved.
+// This code is governed by the BSD license found in the LICENSE file.
+
+/*---
+description: GroupSpecifier must be identifier-like.
+esid: prod-GroupSpecifier
+negative:
+  phase: parse
+  type: SyntaxError
+features: [regexp-named-groups]
+---*/
+
+throw "Test262: This statement should not be evaluated.";
+
+/(?<❤>a)/u;
diff --git a/test/language/literals/regexp/named-groups/invalid-non-id-start-groupspecifier.js b/test/language/literals/regexp/named-groups/invalid-non-id-start-groupspecifier.js
new file mode 100644
index 0000000000000000000000000000000000000000..cdaff4016ea94459e0da1e2d003d996308a587b0
--- /dev/null
+++ b/test/language/literals/regexp/named-groups/invalid-non-id-start-groupspecifier.js
@@ -0,0 +1,15 @@
+// Copyright 2017 the V8 project authors. All rights reserved.
+// This code is governed by the BSD license found in the LICENSE file.
+
+/*---
+description: GroupSpecifier must be identifier-like.
+esid: prod-GroupSpecifier
+negative:
+  phase: parse
+  type: SyntaxError
+features: [regexp-named-groups]
+---*/
+
+throw "Test262: This statement should not be evaluated.";
+
+/(?<❤>a)/;
diff --git a/test/language/literals/regexp/named-groups/invalid-numeric-groupspecifier-u.js b/test/language/literals/regexp/named-groups/invalid-numeric-groupspecifier-u.js
new file mode 100644
index 0000000000000000000000000000000000000000..c5ede73e6f9942cb135c2ea9fe2296499b28bb32
--- /dev/null
+++ b/test/language/literals/regexp/named-groups/invalid-numeric-groupspecifier-u.js
@@ -0,0 +1,15 @@
+// Copyright 2017 the V8 project authors. All rights reserved.
+// This code is governed by the BSD license found in the LICENSE file.
+
+/*---
+description: GroupSpecifier must be identifier-like.
+esid: prod-GroupSpecifier
+negative:
+  phase: parse
+  type: SyntaxError
+features: [regexp-named-groups]
+---*/
+
+throw "Test262: This statement should not be evaluated.";
+
+/(?<42a>a)/u;
diff --git a/test/language/literals/regexp/named-groups/invalid-numeric-groupspecifier.js b/test/language/literals/regexp/named-groups/invalid-numeric-groupspecifier.js
new file mode 100644
index 0000000000000000000000000000000000000000..235e780734a1685ec9983bcb9b42e46d66701a0e
--- /dev/null
+++ b/test/language/literals/regexp/named-groups/invalid-numeric-groupspecifier.js
@@ -0,0 +1,15 @@
+// Copyright 2017 the V8 project authors. All rights reserved.
+// This code is governed by the BSD license found in the LICENSE file.
+
+/*---
+description: GroupSpecifier must be identifier-like.
+esid: prod-GroupSpecifier
+negative:
+  phase: parse
+  type: SyntaxError
+features: [regexp-named-groups]
+---*/
+
+throw "Test262: This statement should not be evaluated.";
+
+/(?<42a>a)/;
diff --git a/test/language/literals/regexp/named-groups/invalid-punctuator-starting-groupspecifier-u.js b/test/language/literals/regexp/named-groups/invalid-punctuator-starting-groupspecifier-u.js
new file mode 100644
index 0000000000000000000000000000000000000000..b55f2b5453486179edc535492e4aafda831b36c7
--- /dev/null
+++ b/test/language/literals/regexp/named-groups/invalid-punctuator-starting-groupspecifier-u.js
@@ -0,0 +1,15 @@
+// Copyright 2017 the V8 project authors. All rights reserved.
+// This code is governed by the BSD license found in the LICENSE file.
+
+/*---
+description: GroupSpecifier must be identifier-like.
+esid: prod-GroupSpecifier
+negative:
+  phase: parse
+  type: SyntaxError
+features: [regexp-named-groups]
+---*/
+
+throw "Test262: This statement should not be evaluated.";
+
+/(?<:a>a)/u;
diff --git a/test/language/literals/regexp/named-groups/invalid-punctuator-starting-groupspecifier.js b/test/language/literals/regexp/named-groups/invalid-punctuator-starting-groupspecifier.js
new file mode 100644
index 0000000000000000000000000000000000000000..3e646904a103cd4dec747e9e2aec3077e02ad3a1
--- /dev/null
+++ b/test/language/literals/regexp/named-groups/invalid-punctuator-starting-groupspecifier.js
@@ -0,0 +1,15 @@
+// Copyright 2017 the V8 project authors. All rights reserved.
+// This code is governed by the BSD license found in the LICENSE file.
+
+/*---
+description: GroupSpecifier must be identifier-like.
+esid: prod-GroupSpecifier
+negative:
+  phase: parse
+  type: SyntaxError
+features: [regexp-named-groups]
+---*/
+
+throw "Test262: This statement should not be evaluated.";
+
+/(?<:a>a)/;
diff --git a/test/language/literals/regexp/named-groups/invalid-punctuator-within-groupspecifier-u.js b/test/language/literals/regexp/named-groups/invalid-punctuator-within-groupspecifier-u.js
new file mode 100644
index 0000000000000000000000000000000000000000..1419cddb5f41eb0523a9d5935a2fba960c276245
--- /dev/null
+++ b/test/language/literals/regexp/named-groups/invalid-punctuator-within-groupspecifier-u.js
@@ -0,0 +1,15 @@
+// Copyright 2017 the V8 project authors. All rights reserved.
+// This code is governed by the BSD license found in the LICENSE file.
+
+/*---
+description: GroupSpecifier must be identifier-like.
+esid: prod-GroupSpecifier
+negative:
+  phase: parse
+  type: SyntaxError
+features: [regexp-named-groups]
+---*/
+
+throw "Test262: This statement should not be evaluated.";
+
+/(?<a:>a)/u;
diff --git a/test/language/literals/regexp/named-groups/invalid-punctuator-within-groupspecifier.js b/test/language/literals/regexp/named-groups/invalid-punctuator-within-groupspecifier.js
new file mode 100644
index 0000000000000000000000000000000000000000..8fec9b8ff91ada92161765abf218b80e0f14bd72
--- /dev/null
+++ b/test/language/literals/regexp/named-groups/invalid-punctuator-within-groupspecifier.js
@@ -0,0 +1,15 @@
+// Copyright 2017 the V8 project authors. All rights reserved.
+// This code is governed by the BSD license found in the LICENSE file.
+
+/*---
+description: GroupSpecifier must be identifier-like.
+esid: prod-GroupSpecifier
+negative:
+  phase: parse
+  type: SyntaxError
+features: [regexp-named-groups]
+---*/
+
+throw "Test262: This statement should not be evaluated.";
+
+/(?<a:>a)/;
diff --git a/test/language/literals/regexp/named-groups/invalid-u-escape-in-groupspecifier-2.js b/test/language/literals/regexp/named-groups/invalid-u-escape-in-groupspecifier-2.js
new file mode 100644
index 0000000000000000000000000000000000000000..7d58dc86b01c962b116e100c3e6b4eb27eb468e9
--- /dev/null
+++ b/test/language/literals/regexp/named-groups/invalid-u-escape-in-groupspecifier-2.js
@@ -0,0 +1,15 @@
+// Copyright 2017 the V8 project authors. All rights reserved.
+// This code is governed by the BSD license found in the LICENSE file.
+
+/*---
+description: \u{} escapes in GroupSpecifier allowed only in Unicode mode
+esid: prod-GroupSpecifier
+negative:
+  phase: parse
+  type: SyntaxError
+features: [regexp-named-groups]
+---*/
+
+throw "Test262: This statement should not be evaluated.";
+
+/(?<\u{03C0}>a)/;
diff --git a/test/language/literals/regexp/named-groups/invalid-u-escape-in-groupspecifier.js b/test/language/literals/regexp/named-groups/invalid-u-escape-in-groupspecifier.js
new file mode 100644
index 0000000000000000000000000000000000000000..53f7b96bf68335e00d1e8fd0220c367662784dfc
--- /dev/null
+++ b/test/language/literals/regexp/named-groups/invalid-u-escape-in-groupspecifier.js
@@ -0,0 +1,15 @@
+// Copyright 2017 the V8 project authors. All rights reserved.
+// This code is governed by the BSD license found in the LICENSE file.
+
+/*---
+description: \u{} escapes in GroupSpecifier allowed only in Unicode mode
+esid: prod-GroupSpecifier
+negative:
+  phase: parse
+  type: SyntaxError
+features: [regexp-named-groups]
+---*/
+
+throw "Test262: This statement should not be evaluated.";
+
+/(?<\u{0041}>.)/;
diff --git a/test/language/literals/regexp/named-groups/invalid-unterminated-groupspecifier-u.js b/test/language/literals/regexp/named-groups/invalid-unterminated-groupspecifier-u.js
new file mode 100644
index 0000000000000000000000000000000000000000..d84c30e4dc1d9d63e307f6e3723344c94d5759d1
--- /dev/null
+++ b/test/language/literals/regexp/named-groups/invalid-unterminated-groupspecifier-u.js
@@ -0,0 +1,15 @@
+// Copyright 2017 the V8 project authors. All rights reserved.
+// This code is governed by the BSD license found in the LICENSE file.
+
+/*---
+description: GroupSpecifier must be identifier-like.
+esid: prod-GroupSpecifier
+negative:
+  phase: parse
+  type: SyntaxError
+features: [regexp-named-groups]
+---*/
+
+throw "Test262: This statement should not be evaluated.";
+
+/(?<aa)/u;
diff --git a/test/language/literals/regexp/named-groups/invalid-unterminated-groupspecifier.js b/test/language/literals/regexp/named-groups/invalid-unterminated-groupspecifier.js
new file mode 100644
index 0000000000000000000000000000000000000000..6ccac1ce1eb58d3ae3741217512e7430154e2f65
--- /dev/null
+++ b/test/language/literals/regexp/named-groups/invalid-unterminated-groupspecifier.js
@@ -0,0 +1,15 @@
+// Copyright 2017 the V8 project authors. All rights reserved.
+// This code is governed by the BSD license found in the LICENSE file.
+
+/*---
+description: GroupSpecifier must be identifier-like.
+esid: prod-GroupSpecifier
+negative:
+  phase: parse
+  type: SyntaxError
+features: [regexp-named-groups]
+---*/
+
+throw "Test262: This statement should not be evaluated.";
+
+/(?<aa)/;