Chromium Code Reviews
chromiumcodereview-hr@appspot.gserviceaccount.com (chromiumcodereview-hr) | Please choose your nickname with Settings | Help | Chromium Project | Gerrit Changes | Sign out
(160)

Issue 2780173002: [regexp] Add support for dotAll flag (Closed)

Created:
3 years, 8 months ago by jgruber
Modified:
3 years, 8 months ago
Reviewers:
erikcorry, mathias, Yang, marja
CC:
v8-reviews_googlegroups.com, Michael Hablich, mathias
Target Ref:
refs/heads/master
Project:
v8
Visibility:
Public.

Description

[regexp] Add support for dotAll flag The dotAll flag changes behavior of the dot '.' character to match every possible single character instead of excluding certain line terminators. The implementation is staged behind --harmony-regexp-dotall. Spec proposal: https://github.com/mathiasbynens/es-regexp-dotall-flag BUG=v8:6172 Review-Url: https://codereview.chromium.org/2780173002 Cr-Commit-Position: refs/heads/master@{#44295} Committed: https://chromium.googlesource.com/v8/v8/+/cec39ad1ade5b38a7b203e9cc64cca867196f33a

Patch Set 1 #

Patch Set 2 : Rebase #

Patch Set 3 : Runtime check for --harmony-regexp-dotall in CSA #

Patch Set 4 : Reserve enough space for '.' character range #

Total comments: 2

Patch Set 5 : Test U+180E #

Patch Set 6 : Rebase and test disabled dotall #

Total comments: 2

Patch Set 7 : Address comments #

Unified diffs Side-by-side diffs Delta from patch set Stats (+316 lines, -13 lines) Patch
M include/v8.h View 1 2 3 4 5 1 chunk +6 lines, -5 lines 0 comments Download
M src/assembler.h View 1 2 1 chunk +3 lines, -0 lines 0 comments Download
M src/assembler.cc View 1 2 1 chunk +5 lines, -0 lines 0 comments Download
M src/bootstrapper.cc View 1 2 3 4 5 1 chunk +16 lines, -0 lines 0 comments Download
M src/builtins/builtins-definitions.h View 1 2 3 4 5 1 chunk +2 lines, -0 lines 0 comments Download
M src/builtins/builtins-regexp-gen.h View 1 2 1 chunk +4 lines, -2 lines 0 comments Download
M src/builtins/builtins-regexp-gen.cc View 1 2 8 chunks +48 lines, -4 lines 0 comments Download
M src/external-reference-table.cc View 1 2 1 chunk +3 lines, -0 lines 0 comments Download
M src/flag-definitions.h View 1 2 3 4 5 1 chunk +1 line, -0 lines 0 comments Download
M src/heap-symbols.h View 1 chunk +1 line, -0 lines 0 comments Download
M src/objects.h View 1 2 3 4 5 1 chunk +1 line, -0 lines 0 comments Download
M src/objects.cc View 1 2 3 4 5 1 chunk +7 lines, -0 lines 0 comments Download
M src/parsing/scanner.cc View 1 chunk +7 lines, -0 lines 0 comments Download
M src/regexp/regexp-parser.h View 2 chunks +2 lines, -0 lines 0 comments Download
M src/regexp/regexp-parser.cc View 1 2 3 3 chunks +12 lines, -2 lines 0 comments Download
A test/mjsunit/harmony/regexp-dotall.js View 1 2 3 4 5 1 chunk +129 lines, -0 lines 0 comments Download
A test/mjsunit/harmony/regexp-dotall-disabled.js View 1 2 3 4 5 6 1 chunk +69 lines, -0 lines 0 comments Download

Messages

Total messages: 48 (34 generated)
jgruber
3 years, 8 months ago (2017-03-29 15:26:27 UTC) #12
mathias
https://codereview.chromium.org/2780173002/diff/60001/test/mjsunit/harmony/regexp-dotall.js File test/mjsunit/harmony/regexp-dotall.js (right): https://codereview.chromium.org/2780173002/diff/60001/test/mjsunit/harmony/regexp-dotall.js#newcode73 test/mjsunit/harmony/regexp-dotall.js:73: assertFalse(re.test("\u2029")); Let’s test U+180E as well, since it used ...
3 years, 8 months ago (2017-03-29 16:10:42 UTC) #16
jgruber
https://codereview.chromium.org/2780173002/diff/60001/test/mjsunit/harmony/regexp-dotall.js File test/mjsunit/harmony/regexp-dotall.js (right): https://codereview.chromium.org/2780173002/diff/60001/test/mjsunit/harmony/regexp-dotall.js#newcode73 test/mjsunit/harmony/regexp-dotall.js:73: assertFalse(re.test("\u2029")); On 2017/03/29 16:10:42, mathias wrote: > Let’s test ...
3 years, 8 months ago (2017-03-30 07:32:39 UTC) #21
mathias
lgtm
3 years, 8 months ago (2017-03-30 07:34:59 UTC) #22
erikcorry
I think there should be a second test without the --harmony.... flag that tests that ...
3 years, 8 months ago (2017-03-30 13:02:19 UTC) #26
jgruber
On 2017/03/30 13:02:19, erikcorry wrote: > I think there should be a second test without ...
3 years, 8 months ago (2017-03-30 13:22:53 UTC) #29
jgruber
+marja@ for parsing/, PTAL
3 years, 8 months ago (2017-03-30 13:23:16 UTC) #31
erikcorry
https://codereview.chromium.org/2780173002/diff/100001/test/mjsunit/harmony/regexp-dotall-disabled.js File test/mjsunit/harmony/regexp-dotall-disabled.js (right): https://codereview.chromium.org/2780173002/diff/100001/test/mjsunit/harmony/regexp-dotall-disabled.js#newcode18 test/mjsunit/harmony/regexp-dotall-disabled.js:18: let re = /./gimyu; You could also check ("dotAll" ...
3 years, 8 months ago (2017-03-30 13:28:30 UTC) #32
erikcorry
lgtm
3 years, 8 months ago (2017-03-30 13:28:32 UTC) #33
Yang
On 2017/03/30 13:28:32, erikcorry wrote: > lgtm LGTM!
3 years, 8 months ago (2017-03-31 05:55:04 UTC) #40
marja
parsing lgtm
3 years, 8 months ago (2017-03-31 09:16:04 UTC) #41
jgruber
Thanks all, landing. https://codereview.chromium.org/2780173002/diff/100001/test/mjsunit/harmony/regexp-dotall-disabled.js File test/mjsunit/harmony/regexp-dotall-disabled.js (right): https://codereview.chromium.org/2780173002/diff/100001/test/mjsunit/harmony/regexp-dotall-disabled.js#newcode18 test/mjsunit/harmony/regexp-dotall-disabled.js:18: let re = /./gimyu; On 2017/03/30 ...
3 years, 8 months ago (2017-03-31 09:17:00 UTC) #42
commit-bot: I haz the power
CQ is trying da patch. Follow status at https://chromium-cq-status.appspot.com/v2/patch-status/codereview.chromium.org/2780173002/120001
3 years, 8 months ago (2017-03-31 09:17:20 UTC) #45
commit-bot: I haz the power
3 years, 8 months ago (2017-03-31 09:20:22 UTC) #48
Message was sent while issue was closed.
Committed patchset #7 (id:120001) as
https://chromium.googlesource.com/v8/v8/+/cec39ad1ade5b38a7b203e9cc64cca86719...

Powered by Google App Engine
This is Rietveld 408576698