Index: src/scopes.h |
diff --git a/src/scopes.h b/src/scopes.h |
index fac8a5622d440d1a4a6db537839d297089d77091..f5a1bd97c6704521c721c3bc1a18a1233c036ce1 100644 |
--- a/src/scopes.h |
+++ b/src/scopes.h |
@@ -449,6 +449,7 @@ class Scope: public ZoneObject { |
// handled separately. |
void CollectStackAndContextLocals( |
ZoneList<Variable*>* stack_locals, ZoneList<Variable*>* context_locals, |
+ ZoneList<Variable*>* context_globals, |
ZoneList<Variable*>* strong_mode_free_variables = nullptr); |
// Current number of var or const locals. |
@@ -457,9 +458,11 @@ class Scope: public ZoneObject { |
// Result of variable allocation. |
int num_stack_slots() const { return num_stack_slots_; } |
int num_heap_slots() const { return num_heap_slots_; } |
+ int num_global_slots() const { return num_global_slots_; } |
int StackLocalCount() const; |
int ContextLocalCount() const; |
+ int ContextGlobalCount() const; |
// For script scopes, the number of module literals (including nested ones). |
int num_modules() const { return num_modules_; } |
@@ -626,6 +629,7 @@ class Scope: public ZoneObject { |
// Computed via AllocateVariables; function, block and catch scopes only. |
int num_stack_slots_; |
int num_heap_slots_; |
+ int num_global_slots_; |
// The number of modules (including nested ones). |
int num_modules_; |
@@ -722,7 +726,8 @@ class Scope: public ZoneObject { |
void AllocateHeapSlot(Variable* var); |
void AllocateParameterLocals(Isolate* isolate); |
void AllocateNonParameterLocal(Isolate* isolate, Variable* var); |
- void AllocateNonParameterLocals(Isolate* isolate); |
+ void AllocateDeclaredGlobal(Isolate* isolate, Variable* var); |
+ void AllocateNonParameterLocalsAndDeclaredGlobals(Isolate* isolate); |
void AllocateVariablesRecursively(Isolate* isolate); |
void AllocateParameter(Variable* var, int index); |
void AllocateReceiver(); |