Chromium Code Reviews| Index: src/scopes.h | 
| diff --git a/src/scopes.h b/src/scopes.h | 
| index 2868cdeecb37dd776f8386c813afe19338dc6b14..f13f57ead8afcdd8f82598bd9191610831238ebb 100644 | 
| --- a/src/scopes.h | 
| +++ b/src/scopes.h | 
| @@ -280,7 +280,8 @@ class Scope: public ZoneObject { | 
| bool is_block_scope() const { return type_ == BLOCK_SCOPE; } | 
| bool is_with_scope() const { return type_ == WITH_SCOPE; } | 
| bool is_declaration_scope() const { | 
| - return is_eval_scope() || is_function_scope() || is_global_scope(); | 
| + return is_eval_scope() || is_function_scope() || | 
| + is_module_scope() || is_global_scope(); | 
| } | 
| bool is_classic_mode() const { | 
| return language_mode() == CLASSIC_MODE; | 
| @@ -592,6 +593,13 @@ class Scope: public ZoneObject { | 
| bool AllocateVariables(CompilationInfo* info, | 
| AstNodeFactory<AstNullVisitor>* factory); | 
| + // Instance objects have to be created ahead of time (before code generation) | 
| + // because of potentially cyclic references between them. | 
| + // Linking also has to be a separate stage, since populating one object may | 
| + // may potentially requires (forward) references to others. | 
| 
 
Michael Starzinger
2012/07/06 10:53:22
Drop one "may" and "s/requires/require".
 
rossberg
2012/07/06 15:39:28
Done.
 
 | 
| + void AllocateModules(CompilationInfo* info); | 
| + void LinkModules(CompilationInfo* info); | 
| + | 
| private: | 
| // Construct a scope based on the scope info. | 
| Scope(Scope* inner_scope, ScopeType type, Handle<ScopeInfo> scope_info, |