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

Unified Diff: src/globals.h

Issue 2199283002: [modules] Introduce new VariableLocation for module imports/exports. (Closed) Base URL: https://chromium.googlesource.com/v8/v8.git@master
Patch Set: Rebase. Created 4 years, 4 months ago
Use n/p to move between diff chunks; N/P to move between comments. Draft comments are only viewable by you.
Jump to:
View side-by-side diff with in-line comments
Download patch
« no previous file with comments | « src/full-codegen/x87/full-codegen-x87.cc ('k') | src/interpreter/bytecode-generator.cc » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: src/globals.h
diff --git a/src/globals.h b/src/globals.h
index 2bfb1eb84e258a0ed59d46a1d4f463d0624a9c9c..2956884d54aa39c89e26b04ac49171b04973a0f5 100644
--- a/src/globals.h
+++ b/src/globals.h
@@ -886,9 +886,6 @@ enum VariableMode {
LET, // declared via 'let' declarations (first lexical)
- // TODO(neis): Is it correct to make this one of the lexical modes?
- IMPORT, // declared via 'import' declarations (except namespace imports)
-
CONST, // declared via 'const' declarations (last lexical)
// Variables introduced by the compiler:
@@ -924,10 +921,9 @@ inline bool IsLexicalVariableMode(VariableMode mode) {
inline bool IsImmutableVariableMode(VariableMode mode) {
- return mode == CONST || mode == CONST_LEGACY || mode == IMPORT;
+ return mode == CONST || mode == CONST_LEGACY;
}
-
enum class VariableLocation {
// Before and during variable allocation, a variable whose location is
// not yet determined. After allocation, a variable looked up as a
@@ -958,9 +954,11 @@ enum class VariableLocation {
// A named slot in a heap context. name() is the variable name in the
// context object on the heap, with lookup starting at the current
// context. index() is invalid.
- LOOKUP
-};
+ LOOKUP,
+ // A named slot in a module's export table.
+ MODULE
+};
// ES6 Draft Rev3 10.2 specifies declarative environment records with mutable
// and immutable bindings that can be in two states: initialized and
« no previous file with comments | « src/full-codegen/x87/full-codegen-x87.cc ('k') | src/interpreter/bytecode-generator.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698