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

Side by Side Diff: src/parsing/parser.h

Issue 2111363004: Version 5.2.361.33 (cherry-pick) (Closed) Base URL: https://chromium.googlesource.com/v8/v8.git@5.2
Patch Set: Created 4 years, 5 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 | « include/v8-version.h ('k') | src/parsing/pattern-rewriter.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_PARSING_PARSER_H_ 5 #ifndef V8_PARSING_PARSER_H_
6 #define V8_PARSING_PARSER_H_ 6 #define V8_PARSING_PARSER_H_
7 7
8 #include "src/allocation.h" 8 #include "src/allocation.h"
9 #include "src/ast/ast.h" 9 #include "src/ast/ast.h"
10 #include "src/ast/scopes.h" 10 #include "src/ast/scopes.h"
(...skipping 879 matching lines...) Expand 10 before | Expand all | Expand 10 after
890 890
891 bool IsBindingContext() const { return IsBindingContext(context_); } 891 bool IsBindingContext() const { return IsBindingContext(context_); }
892 bool IsInitializerContext() const { return context_ != ASSIGNMENT; } 892 bool IsInitializerContext() const { return context_ != ASSIGNMENT; }
893 bool IsAssignmentContext() const { return IsAssignmentContext(context_); } 893 bool IsAssignmentContext() const { return IsAssignmentContext(context_); }
894 bool IsAssignmentContext(PatternContext c) const; 894 bool IsAssignmentContext(PatternContext c) const;
895 bool IsBindingContext(PatternContext c) const; 895 bool IsBindingContext(PatternContext c) const;
896 bool IsSubPattern() const { return recursion_level_ > 1; } 896 bool IsSubPattern() const { return recursion_level_ > 1; }
897 PatternContext SetAssignmentContextIfNeeded(Expression* node); 897 PatternContext SetAssignmentContextIfNeeded(Expression* node);
898 PatternContext SetInitializerContextIfNeeded(Expression* node); 898 PatternContext SetInitializerContextIfNeeded(Expression* node);
899 899
900 void RewriteParameterScopes(Expression* expr);
901
900 Variable* CreateTempVar(Expression* value = nullptr); 902 Variable* CreateTempVar(Expression* value = nullptr);
901 903
902 AstNodeFactory* factory() const { return parser_->factory(); } 904 AstNodeFactory* factory() const { return parser_->factory(); }
903 AstValueFactory* ast_value_factory() const { 905 AstValueFactory* ast_value_factory() const {
904 return parser_->ast_value_factory(); 906 return parser_->ast_value_factory();
905 } 907 }
906 Zone* zone() const { return parser_->zone(); } 908 Zone* zone() const { return parser_->zone(); }
907 Scope* scope() const { return scope_; } 909 Scope* scope() const { return scope_; }
908 910
909 Scope* scope_; 911 Scope* scope_;
(...skipping 381 matching lines...) Expand 10 before | Expand all | Expand 10 after
1291 1293
1292 DoExpression* ParserTraits::ParseDoExpression(bool* ok) { 1294 DoExpression* ParserTraits::ParseDoExpression(bool* ok) {
1293 return parser_->ParseDoExpression(ok); 1295 return parser_->ParseDoExpression(ok);
1294 } 1296 }
1295 1297
1296 1298
1297 } // namespace internal 1299 } // namespace internal
1298 } // namespace v8 1300 } // namespace v8
1299 1301
1300 #endif // V8_PARSING_PARSER_H_ 1302 #endif // V8_PARSING_PARSER_H_
OLDNEW
« no previous file with comments | « include/v8-version.h ('k') | src/parsing/pattern-rewriter.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698