Chromium Code Reviews

Issue 9615009: Basic interface inference for modules. (Closed)

Created:
8 years, 9 months ago by rossberg
Modified:
8 years, 9 months ago
Reviewers:
Sven Panne
CC:
v8-dev
Visibility:
Public.

Description

Basic interface inference for modules. All module expressions, and all variables that might refer to modules, are assigned interfaces (module types) that are resolved using unification. This is necessary to deal with the highly recursive nature of ES6 modules, which does not allow any kind of bottom-up strategy for resolving module names and paths. Error messages are rudimental right now. Probably need to track more information to make them nicer. R=svenpanne@chromium.org BUG=v8:1569 TEST= Committed: https://code.google.com/p/v8/source/detail?r=10966

Patch Set 1 #

Total comments: 20

Patch Set 2 : Addressed Sven's comments. #

Patch Set 3 : Eps. #

Unified diffs Side-by-side diffs Stats (+841 lines, -84 lines)
M src/SConscript View 1 chunk +1 line, -0 lines 0 comments
M src/ast.h View 10 chunks +33 lines, -12 lines 0 comments
M src/ast.cc View 2 chunks +6 lines, -3 lines 0 comments
M src/flag-definitions.h View 1 chunk +5 lines, -0 lines 0 comments
A src/interface.h View 1 chunk +156 lines, -0 lines 0 comments
A src/interface.cc View 1 chunk +226 lines, -0 lines 0 comments
M src/messages.js View 1 chunk +2 lines, -0 lines 0 comments
M src/parser.h View 2 chunks +4 lines, -1 line 0 comments
M src/parser.cc View 15 chunks +135 lines, -19 lines 0 comments
M src/scopes.h View 9 chunks +32 lines, -20 lines 0 comments
M src/scopes.cc View 14 chunks +71 lines, -18 lines 0 comments
M src/variables.h View 4 chunks +7 lines, -1 line 0 comments
M src/variables.cc View 2 chunks +4 lines, -2 lines 0 comments
M test/mjsunit/harmony/module-parsing.js View 8 chunks +18 lines, -8 lines 0 comments
A test/mjsunit/harmony/module-resolution.js View 1 chunk +139 lines, -0 lines 0 comments
M tools/gyp/v8.gyp View 1 chunk +2 lines, -0 lines 0 comments

Messages

Total messages: 4 (0 generated)
rossberg
8 years, 9 months ago (2012-03-06 10:23:53 UTC) #1
Sven Panne
http://codereview.chromium.org/9615009/diff/1/src/ast.h File src/ast.h (right): http://codereview.chromium.org/9615009/diff/1/src/ast.h#newcode614 src/ast.h:614: explicit ModuleLiteral(Block* body, Interface* interface) Remove "explicit". http://codereview.chromium.org/9615009/diff/1/src/ast.h#newcode2519 src/ast.h:2519: ...
8 years, 9 months ago (2012-03-08 08:55:00 UTC) #2
rossberg
https://chromiumcodereview.appspot.com/9615009/diff/1/src/ast.h File src/ast.h (right): https://chromiumcodereview.appspot.com/9615009/diff/1/src/ast.h#newcode614 src/ast.h:614: explicit ModuleLiteral(Block* body, Interface* interface) On 2012/03/08 08:55:00, Sven ...
8 years, 9 months ago (2012-03-08 10:47:06 UTC) #3
Sven Panne
8 years, 9 months ago (2012-03-08 12:12:15 UTC) #4
LGTM, potential stack overflow in unification will be handled in separate CL, as
discussed offline.

Powered by Google App Engine