OLD | NEW |
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/parsing/parser-base.h" | 9 #include "src/parsing/parser-base.h" |
10 | 10 |
(...skipping 1180 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
1191 V8_INLINE static void PushVariableName(PreParserIdentifier id) {} | 1191 V8_INLINE static void PushVariableName(PreParserIdentifier id) {} |
1192 V8_INLINE void PushPropertyName(PreParserExpression expression) {} | 1192 V8_INLINE void PushPropertyName(PreParserExpression expression) {} |
1193 V8_INLINE void PushEnclosingName(PreParserIdentifier name) {} | 1193 V8_INLINE void PushEnclosingName(PreParserIdentifier name) {} |
1194 V8_INLINE static void AddFunctionForNameInference( | 1194 V8_INLINE static void AddFunctionForNameInference( |
1195 PreParserExpression expression) {} | 1195 PreParserExpression expression) {} |
1196 V8_INLINE static void InferFunctionName() {} | 1196 V8_INLINE static void InferFunctionName() {} |
1197 | 1197 |
1198 V8_INLINE static void CheckAssigningFunctionLiteralToProperty( | 1198 V8_INLINE static void CheckAssigningFunctionLiteralToProperty( |
1199 PreParserExpression left, PreParserExpression right) {} | 1199 PreParserExpression left, PreParserExpression right) {} |
1200 | 1200 |
1201 V8_INLINE static PreParserExpression MarkExpressionAsAssigned( | 1201 V8_INLINE static void MarkExpressionAsAssigned( |
1202 PreParserExpression expression) { | 1202 PreParserExpression expression) { |
1203 // TODO(marja): To be able to produce the same errors, the preparser needs | 1203 // TODO(marja): To be able to produce the same errors, the preparser needs |
1204 // to start tracking which expressions are variables and which are assigned. | 1204 // to start tracking which expressions are variables and which are assigned. |
1205 return expression; | |
1206 } | 1205 } |
1207 | 1206 |
1208 V8_INLINE bool ShortcutNumericLiteralBinaryExpression(PreParserExpression* x, | 1207 V8_INLINE bool ShortcutNumericLiteralBinaryExpression(PreParserExpression* x, |
1209 PreParserExpression y, | 1208 PreParserExpression y, |
1210 Token::Value op, | 1209 Token::Value op, |
1211 int pos) { | 1210 int pos) { |
1212 return false; | 1211 return false; |
1213 } | 1212 } |
1214 | 1213 |
1215 V8_INLINE PreParserExpression BuildUnaryExpression( | 1214 V8_INLINE PreParserExpression BuildUnaryExpression( |
(...skipping 335 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
1551 function_state_->NextMaterializedLiteralIndex(); | 1550 function_state_->NextMaterializedLiteralIndex(); |
1552 function_state_->NextMaterializedLiteralIndex(); | 1551 function_state_->NextMaterializedLiteralIndex(); |
1553 } | 1552 } |
1554 return EmptyExpression(); | 1553 return EmptyExpression(); |
1555 } | 1554 } |
1556 | 1555 |
1557 } // namespace internal | 1556 } // namespace internal |
1558 } // namespace v8 | 1557 } // namespace v8 |
1559 | 1558 |
1560 #endif // V8_PARSING_PREPARSER_H | 1559 #endif // V8_PARSING_PREPARSER_H |
OLD | NEW |