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

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

Issue 1567603005: Set up rewriting triggers (Closed) Base URL: https://chromium.googlesource.com/v8/v8.git@master
Patch Set: Clean up and rename to RewriteNonPattern Created 4 years, 11 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/parsing/parser-base.h ('k') | no next file » | 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_PREPARSER_H 5 #ifndef V8_PARSING_PREPARSER_H
6 #define V8_PARSING_PREPARSER_H 6 #define V8_PARSING_PREPARSER_H
7 7
8 #include "src/ast/scopes.h" 8 #include "src/ast/scopes.h"
9 #include "src/bailout-reason.h" 9 #include "src/bailout-reason.h"
10 #include "src/hashmap.h" 10 #include "src/hashmap.h"
(...skipping 920 matching lines...) Expand 10 before | Expand all | Expand 10 after
931 PreParserExpressionList args, 931 PreParserExpressionList args,
932 int pos); 932 int pos);
933 933
934 inline void RewriteDestructuringAssignments() {} 934 inline void RewriteDestructuringAssignments() {}
935 935
936 inline void QueueDestructuringAssignmentForRewriting(PreParserExpression) {} 936 inline void QueueDestructuringAssignmentForRewriting(PreParserExpression) {}
937 937
938 void SetFunctionNameFromPropertyName(PreParserExpression, 938 void SetFunctionNameFromPropertyName(PreParserExpression,
939 PreParserIdentifier) {} 939 PreParserIdentifier) {}
940 940
941 inline PreParserExpression RewriteExpression( 941 inline PreParserExpression RewriteNonPattern(
942 PreParserExpression expr, const ExpressionClassifier* classifier, 942 PreParserExpression expr, const ExpressionClassifier* classifier,
943 bool* ok); 943 bool* ok);
944 inline PreParserExpression RewriteObjectLiteralProperty( 944 inline PreParserExpression RewriteObjectLiteralProperty(
945 PreParserExpression property, const ExpressionClassifier* classifier, 945 PreParserExpression property, const ExpressionClassifier* classifier,
946 bool* ok); 946 bool* ok);
947 947
948 private: 948 private:
949 PreParser* pre_parser_; 949 PreParser* pre_parser_;
950 }; 950 };
951 951
(...skipping 167 matching lines...) Expand 10 before | Expand all | Expand 10 after
1119 // TODO(wingo): Detect duplicated identifiers in paramlists. Detect parameter 1119 // TODO(wingo): Detect duplicated identifiers in paramlists. Detect parameter
1120 // lists that are too long. 1120 // lists that are too long.
1121 } 1121 }
1122 1122
1123 1123
1124 PreParserExpression PreParserTraits::ParseDoExpression(bool* ok) { 1124 PreParserExpression PreParserTraits::ParseDoExpression(bool* ok) {
1125 return pre_parser_->ParseDoExpression(ok); 1125 return pre_parser_->ParseDoExpression(ok);
1126 } 1126 }
1127 1127
1128 1128
1129 PreParserExpression PreParserTraits::RewriteExpression( 1129 PreParserExpression PreParserTraits::RewriteNonPattern(
1130 PreParserExpression expr, const ExpressionClassifier* classifier, 1130 PreParserExpression expr, const ExpressionClassifier* classifier,
1131 bool* ok) { 1131 bool* ok) {
1132 pre_parser_->ValidateExpression(classifier, ok); 1132 pre_parser_->ValidateExpression(classifier, ok);
1133 return expr; 1133 return expr;
1134 } 1134 }
1135 1135
1136 1136
1137 PreParserExpression PreParserTraits::RewriteObjectLiteralProperty( 1137 PreParserExpression PreParserTraits::RewriteObjectLiteralProperty(
1138 PreParserExpression property, const ExpressionClassifier* classifier, 1138 PreParserExpression property, const ExpressionClassifier* classifier,
1139 bool* ok) { 1139 bool* ok) {
(...skipping 21 matching lines...) Expand all
1161 const PreParserFormalParameters& parameters, FunctionKind kind, 1161 const PreParserFormalParameters& parameters, FunctionKind kind,
1162 FunctionLiteral::FunctionType function_type, bool* ok) { 1162 FunctionLiteral::FunctionType function_type, bool* ok) {
1163 return pre_parser_->ParseEagerFunctionBody(function_name, pos, parameters, 1163 return pre_parser_->ParseEagerFunctionBody(function_name, pos, parameters,
1164 kind, function_type, ok); 1164 kind, function_type, ok);
1165 } 1165 }
1166 1166
1167 } // namespace internal 1167 } // namespace internal
1168 } // namespace v8 1168 } // namespace v8
1169 1169
1170 #endif // V8_PARSING_PREPARSER_H 1170 #endif // V8_PARSING_PREPARSER_H
OLDNEW
« no previous file with comments | « src/parsing/parser-base.h ('k') | no next file » | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698