| Index: src/regexp/regexp-parser.cc
|
| diff --git a/src/regexp/regexp-parser.cc b/src/regexp/regexp-parser.cc
|
| index 68c5a6d2633cd31ee8ee17c0487ec87ea44d7b7d..3e5998719436e1cfe743e694b2eaf526b46bc377 100644
|
| --- a/src/regexp/regexp-parser.cc
|
| +++ b/src/regexp/regexp-parser.cc
|
| @@ -789,6 +789,12 @@ const ZoneVector<uc16>* RegExpParser::ParseCaptureGroupName() {
|
| }
|
| }
|
|
|
| + // The backslash char is misclassified as both ID_Start and ID_Continue.
|
| + if (c == '\\') {
|
| + ReportError(CStrVector("Invalid capture group name"));
|
| + return nullptr;
|
| + }
|
| +
|
| if (at_start) {
|
| if (!IdentifierStart::Is(c)) {
|
| ReportError(CStrVector("Invalid capture group name"));
|
|
|