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

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

Issue 1663773003: Remove redundant/unnecessary variables and checks in ParseForStatement (Closed) Base URL: https://chromium.googlesource.com/v8/v8.git@master
Patch Set: Created 4 years, 10 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/messages.h ('k') | src/parsing/parser.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 892 matching lines...) Expand 10 before | Expand all | Expand 10 after
903 // %ThrowIteratorResultNotAnObject(result) 903 // %ThrowIteratorResultNotAnObject(result)
904 Expression* BuildIteratorNextResult(Expression* iterator, Variable* result, 904 Expression* BuildIteratorNextResult(Expression* iterator, Variable* result,
905 int pos); 905 int pos);
906 906
907 907
908 // Initialize the components of a for-in / for-of statement. 908 // Initialize the components of a for-in / for-of statement.
909 void InitializeForEachStatement(ForEachStatement* stmt, Expression* each, 909 void InitializeForEachStatement(ForEachStatement* stmt, Expression* each,
910 Expression* subject, Statement* body, 910 Expression* subject, Statement* body,
911 bool is_destructuring); 911 bool is_destructuring);
912 Statement* DesugarLexicalBindingsInForStatement( 912 Statement* DesugarLexicalBindingsInForStatement(
913 Scope* inner_scope, bool is_const, ZoneList<const AstRawString*>* names, 913 Scope* inner_scope, VariableMode mode,
914 ForStatement* loop, Statement* init, Expression* cond, Statement* next, 914 ZoneList<const AstRawString*>* names, ForStatement* loop, Statement* init,
915 Statement* body, bool* ok); 915 Expression* cond, Statement* next, Statement* body, bool* ok);
916 916
917 void RewriteDoExpression(Expression* expr, bool* ok); 917 void RewriteDoExpression(Expression* expr, bool* ok);
918 918
919 FunctionLiteral* ParseFunctionLiteral( 919 FunctionLiteral* ParseFunctionLiteral(
920 const AstRawString* name, Scanner::Location function_name_location, 920 const AstRawString* name, Scanner::Location function_name_location,
921 FunctionNameValidity function_name_validity, FunctionKind kind, 921 FunctionNameValidity function_name_validity, FunctionKind kind,
922 int function_token_position, FunctionLiteral::FunctionType type, 922 int function_token_position, FunctionLiteral::FunctionType type,
923 FunctionLiteral::ArityRestriction arity_restriction, 923 FunctionLiteral::ArityRestriction arity_restriction,
924 LanguageMode language_mode, bool* ok); 924 LanguageMode language_mode, bool* ok);
925 925
(...skipping 286 matching lines...) Expand 10 before | Expand all | Expand 10 after
1212 1212
1213 DoExpression* ParserTraits::ParseDoExpression(bool* ok) { 1213 DoExpression* ParserTraits::ParseDoExpression(bool* ok) {
1214 return parser_->ParseDoExpression(ok); 1214 return parser_->ParseDoExpression(ok);
1215 } 1215 }
1216 1216
1217 1217
1218 } // namespace internal 1218 } // namespace internal
1219 } // namespace v8 1219 } // namespace v8
1220 1220
1221 #endif // V8_PARSING_PARSER_H_ 1221 #endif // V8_PARSING_PARSER_H_
OLDNEW
« no previous file with comments | « src/messages.h ('k') | src/parsing/parser.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698