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

Issue 2661933003: [ESnext] Parse dynamic import expression (Closed)

Created:
3 years, 10 months ago by gsathya
Modified:
3 years, 10 months ago
Reviewers:
neis, adamk, vogelheim
CC:
v8-reviews_googlegroups.com
Target Ref:
refs/pending/heads/master
Project:
v8
Visibility:
Public.

Description

[ESnext] Parse dynamic import expression Rewrites import expression into a runtime call. Uses peekahead to determine if parsing an import declaration or import expression. The runtime call doesn't actually do the import yet, will be added in follow on patch. Adds a new --harmony-dynamic-import flag. Adds a ignore_error_msg parameter to the test runner to ignore the discrepancy in the error messages while parsing import expression with parser and pre parser. This discrepancy will actually never happen in real code. BUG=v8:5785 Review-Url: https://codereview.chromium.org/2661933003 Cr-Commit-Position: refs/heads/master@{#42820} Committed: https://chromium.googlesource.com/v8/v8/+/e791ded4cdbe8c4d3f4e4a65e62f61e2b5a1c196

Patch Set 1 #

Patch Set 2 : Add flag + tests #

Patch Set 3 : add dcheck #

Patch Set 4 : fix #

Patch Set 5 : use diff runtime call #

Total comments: 4

Patch Set 6 : review fixes #

Total comments: 8

Patch Set 7 : fix #

Unified diffs Side-by-side diffs Delta from patch set Stats (+231 lines, -48 lines) Patch
M src/bootstrapper.cc View 1 2 chunks +2 lines, -0 lines 0 comments Download
M src/flag-definitions.h View 1 1 chunk +11 lines, -10 lines 0 comments Download
M src/parsing/parser.cc View 1 2 3 4 5 6 3 chunks +16 lines, -8 lines 0 comments Download
M src/parsing/parser-base.h View 1 2 3 4 5 6 7 chunks +26 lines, -2 lines 0 comments Download
M src/parsing/preparser.h View 1 chunk +6 lines, -0 lines 0 comments Download
M src/runtime/runtime.h View 1 2 3 4 1 chunk +1 line, -0 lines 0 comments Download
M src/runtime/runtime-module.cc View 1 2 3 4 5 6 1 chunk +7 lines, -0 lines 0 comments Download
M test/cctest/test-parsing.cc View 1 2 3 4 5 6 10 chunks +162 lines, -28 lines 0 comments Download

Messages

Total messages: 32 (22 generated)
gsathya
3 years, 10 months ago (2017-01-31 00:24:25 UTC) #11
adamk
https://codereview.chromium.org/2661933003/diff/80001/src/parsing/parser-base.h File src/parsing/parser-base.h (right): https://codereview.chromium.org/2661933003/diff/80001/src/parsing/parser-base.h#newcode3424 src/parsing/parser-base.h:3424: int pos = position(); I think you want peek_position() ...
3 years, 10 months ago (2017-01-31 00:29:33 UTC) #12
gsathya
https://codereview.chromium.org/2661933003/diff/80001/src/parsing/parser-base.h File src/parsing/parser-base.h (right): https://codereview.chromium.org/2661933003/diff/80001/src/parsing/parser-base.h#newcode3424 src/parsing/parser-base.h:3424: int pos = position(); On 2017/01/31 00:29:33, adamk wrote: ...
3 years, 10 months ago (2017-01-31 00:35:09 UTC) #15
adamk
lgtm
3 years, 10 months ago (2017-01-31 00:36:40 UTC) #16
neis
lgtm with minor comments https://codereview.chromium.org/2661933003/diff/100001/src/parsing/parser.cc File src/parsing/parser.cc (right): https://codereview.chromium.org/2661933003/diff/100001/src/parsing/parser.cc#newcode984 src/parsing/parser.cc:984: } Nit: I find this ...
3 years, 10 months ago (2017-01-31 10:47:57 UTC) #19
neis
https://codereview.chromium.org/2661933003/diff/100001/src/parsing/parser-base.h File src/parsing/parser-base.h (right): https://codereview.chromium.org/2661933003/diff/100001/src/parsing/parser-base.h#newcode3357 src/parsing/parser-base.h:3357: Please update the comment. I'm a bit confused, though, ...
3 years, 10 months ago (2017-01-31 11:20:09 UTC) #20
gsathya
https://codereview.chromium.org/2661933003/diff/100001/src/parsing/parser-base.h File src/parsing/parser-base.h (right): https://codereview.chromium.org/2661933003/diff/100001/src/parsing/parser-base.h#newcode3357 src/parsing/parser-base.h:3357: On 2017/01/31 11:20:09, neis wrote: > Please update the ...
3 years, 10 months ago (2017-01-31 18:26:08 UTC) #23
neis
lgtm
3 years, 10 months ago (2017-01-31 18:40:28 UTC) #24
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/2661933003/120001
3 years, 10 months ago (2017-01-31 18:57:16 UTC) #29
commit-bot: I haz the power
3 years, 10 months ago (2017-01-31 18:59:01 UTC) #32
Message was sent while issue was closed.
Committed patchset #7 (id:120001) as
https://chromium.googlesource.com/v8/v8/+/e791ded4cdbe8c4d3f4e4a65e62f61e2b5a...

Powered by Google App Engine
This is Rietveld 408576698