|
[es6] Correct parsing of regular expression literal flags.
ES6 section 12.2.8.1 states that flags for regular expression literals
must be checked during parsing and invalid flags are early errors. This
change adapts the Scanner and (Pre)Parser to act according to the spec.
This is also a prerequisite to unify the handling of literal creation
(for Objects, Arrays, Regexps, and at some point Classes).
R=yangguo@chromium.org
Committed: https://crrev.com/2732a6ad447b76ee0b74753c3452e28127d574d8
Cr-Commit-Position: refs/heads/master@{#32273}
|
Unified diffs |
Side-by-side diffs |
Delta from patch set |
Stats (+222 lines, -206 lines) |
Patch |
|
M |
src/api.cc
|
View
|
|
2 chunks |
+14 lines, -28 lines |
0 comments
|
Download
|
|
M |
src/ast.h
|
View
|
|
3 chunks |
+7 lines, -11 lines |
0 comments
|
Download
|
|
M |
src/factory.cc
|
View
|
|
2 chunks |
+2 lines, -2 lines |
0 comments
|
Download
|
|
M |
src/full-codegen/arm/full-codegen-arm.cc
|
View
|
|
1 chunk |
+1 line, -1 line |
0 comments
|
Download
|
|
M |
src/full-codegen/arm64/full-codegen-arm64.cc
|
View
|
|
1 chunk |
+1 line, -1 line |
0 comments
|
Download
|
|
M |
src/full-codegen/ia32/full-codegen-ia32.cc
|
View
|
|
1 chunk |
+1 line, -1 line |
0 comments
|
Download
|
|
M |
src/full-codegen/mips/full-codegen-mips.cc
|
View
|
|
1 chunk |
+1 line, -1 line |
0 comments
|
Download
|
|
M |
src/full-codegen/mips64/full-codegen-mips64.cc
|
View
|
|
1 chunk |
+1 line, -1 line |
0 comments
|
Download
|
|
M |
src/full-codegen/ppc/full-codegen-ppc.cc
|
View
|
|
1 chunk |
+1 line, -1 line |
0 comments
|
Download
|
|
M |
src/full-codegen/x64/full-codegen-x64.cc
|
View
|
|
1 chunk |
+1 line, -1 line |
0 comments
|
Download
|
|
M |
src/full-codegen/x87/full-codegen-x87.cc
|
View
|
|
1 chunk |
+1 line, -1 line |
0 comments
|
Download
|
|
M |
src/interpreter/bytecode-array-builder.h
|
View
|
|
1 chunk |
+1 line, -1 line |
0 comments
|
Download
|
|
M |
src/interpreter/bytecode-array-builder.cc
|
View
|
|
1 chunk |
+3 lines, -2 lines |
0 comments
|
Download
|
|
M |
src/interpreter/bytecode-generator.cc
|
View
|
|
1 chunk |
+2 lines, -5 lines |
0 comments
|
Download
|
|
M |
src/interpreter/bytecodes.h
|
View
|
1
|
1 chunk |
+1 line, -1 line |
0 comments
|
Download
|
|
M |
src/interpreter/interpreter.cc
|
View
|
|
2 chunks |
+10 lines, -19 lines |
0 comments
|
Download
|
|
M |
src/objects.h
|
View
|
|
4 chunks |
+14 lines, -20 lines |
0 comments
|
Download
|
|
M |
src/objects.cc
|
View
|
|
4 chunks |
+62 lines, -38 lines |
0 comments
|
Download
|
|
M |
src/preparser.h
|
View
|
|
2 chunks |
+5 lines, -6 lines |
0 comments
|
Download
|
|
M |
src/prettyprinter.cc
|
View
|
|
3 chunks |
+20 lines, -3 lines |
0 comments
|
Download
|
|
M |
src/regexp/jsregexp.cc
|
View
|
|
2 chunks |
+12 lines, -15 lines |
0 comments
|
Download
|
|
M |
src/runtime/runtime-literals.cc
|
View
|
|
1 chunk |
+3 lines, -3 lines |
0 comments
|
Download
|
|
M |
src/runtime/runtime-regexp.cc
|
View
|
|
2 chunks |
+2 lines, -2 lines |
0 comments
|
Download
|
|
M |
src/scanner.h
|
View
|
|
1 chunk |
+2 lines, -3 lines |
0 comments
|
Download
|
|
M |
src/scanner.cc
|
View
|
|
1 chunk |
+27 lines, -6 lines |
0 comments
|
Download
|
|
M |
test/cctest/interpreter/test-bytecode-generator.cc
|
View
|
|
1 chunk |
+21 lines, -26 lines |
0 comments
|
Download
|
|
M |
test/cctest/test-parsing.cc
|
View
|
|
2 chunks |
+1 line, -2 lines |
0 comments
|
Download
|
|
M |
test/mjsunit/messages.js
|
View
|
|
1 chunk |
+2 lines, -2 lines |
0 comments
|
Download
|
|
M |
test/unittests/interpreter/bytecode-array-builder-unittest.cc
|
View
|
|
1 chunk |
+1 line, -1 line |
0 comments
|
Download
|
|
M |
test/webkit/fast/regex/toString-expected.txt
|
View
|
|
1 chunk |
+2 lines, -2 lines |
0 comments
|
Download
|
Total messages: 8 (1 generated)
|