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

Side by Side Diff: src/ast/scopes.h

Issue 2314483002: Store the ScopeInfo in WithContexts (Closed)
Patch Set: updates Created 4 years, 3 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 unified diff | Download patch
« no previous file with comments | « src/ast/scopeinfo.cc ('k') | src/ast/scopes.cc » ('j') | no next file with comments »
Toggle Intra-line Diffs ('i') | Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
OLDNEW
1 // Copyright 2012 the V8 project authors. All rights reserved. 1 // Copyright 2012 the V8 project authors. All rights reserved.
2 // Use of this source code is governed by a BSD-style license that can be 2 // Use of this source code is governed by a BSD-style license that can be
3 // found in the LICENSE file. 3 // found in the LICENSE file.
4 4
5 #ifndef V8_AST_SCOPES_H_ 5 #ifndef V8_AST_SCOPES_H_
6 #define V8_AST_SCOPES_H_ 6 #define V8_AST_SCOPES_H_
7 7
8 #include "src/ast/variables.h" 8 #include "src/ast/variables.h"
9 #include "src/base/hashmap.h" 9 #include "src/base/hashmap.h"
10 #include "src/globals.h" 10 #include "src/globals.h"
(...skipping 384 matching lines...) Expand 10 before | Expand all | Expand 10 after
395 395
396 // Check that all Scopes in the scope tree use the same Zone. 396 // Check that all Scopes in the scope tree use the same Zone.
397 void CheckZones(); 397 void CheckZones();
398 #endif 398 #endif
399 399
400 // Retrieve `IsSimpleParameterList` of current or outer function. 400 // Retrieve `IsSimpleParameterList` of current or outer function.
401 bool HasSimpleParameters(); 401 bool HasSimpleParameters();
402 void set_is_debug_evaluate_scope() { is_debug_evaluate_scope_ = true; } 402 void set_is_debug_evaluate_scope() { is_debug_evaluate_scope_ = true; }
403 403
404 protected: 404 protected:
405 explicit Scope(Zone* zone, ScopeType scope_type = SCRIPT_SCOPE); 405 explicit Scope(Zone* zone);
406 406
407 void set_language_mode(LanguageMode language_mode) { 407 void set_language_mode(LanguageMode language_mode) {
408 is_strict_ = is_strict(language_mode); 408 is_strict_ = is_strict(language_mode);
409 } 409 }
410 410
411 private: 411 private:
412 Variable* Declare(Zone* zone, Scope* scope, const AstRawString* name, 412 Variable* Declare(Zone* zone, Scope* scope, const AstRawString* name,
413 VariableMode mode, Variable::Kind kind, 413 VariableMode mode, Variable::Kind kind,
414 InitializationFlag initialization_flag, 414 InitializationFlag initialization_flag,
415 MaybeAssignedFlag maybe_assigned_flag = kNotAssigned) { 415 MaybeAssignedFlag maybe_assigned_flag = kNotAssigned) {
(...skipping 427 matching lines...) Expand 10 before | Expand all | Expand 10 after
843 void AllocateModuleVariables(); 843 void AllocateModuleVariables();
844 844
845 private: 845 private:
846 ModuleDescriptor* module_descriptor_; 846 ModuleDescriptor* module_descriptor_;
847 }; 847 };
848 848
849 } // namespace internal 849 } // namespace internal
850 } // namespace v8 850 } // namespace v8
851 851
852 #endif // V8_AST_SCOPES_H_ 852 #endif // V8_AST_SCOPES_H_
OLDNEW
« no previous file with comments | « src/ast/scopeinfo.cc ('k') | src/ast/scopes.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698