| 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/bailout-reason.h" | 9 #include "src/bailout-reason.h" |
| 10 #include "src/hashmap.h" | 10 #include "src/hashmap.h" |
| (...skipping 842 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 853 | 853 |
| 854 static PreParserStatementList NewStatementList(int size, Zone* zone) { | 854 static PreParserStatementList NewStatementList(int size, Zone* zone) { |
| 855 return PreParserStatementList(); | 855 return PreParserStatementList(); |
| 856 } | 856 } |
| 857 | 857 |
| 858 static PreParserExpressionList NewPropertyList(int size, Zone* zone) { | 858 static PreParserExpressionList NewPropertyList(int size, Zone* zone) { |
| 859 return PreParserExpressionList(); | 859 return PreParserExpressionList(); |
| 860 } | 860 } |
| 861 | 861 |
| 862 static void AddParameterInitializationBlock( | 862 static void AddParameterInitializationBlock( |
| 863 const PreParserFormalParameters& parameters, | 863 const PreParserFormalParameters& parameters, PreParserStatementList list, |
| 864 PreParserStatementList list, bool* ok) {} | 864 bool is_async, bool* ok) {} |
| 865 | 865 |
| 866 V8_INLINE void SkipLazyFunctionBody(int* materialized_literal_count, | 866 V8_INLINE void SkipLazyFunctionBody(int* materialized_literal_count, |
| 867 int* expected_property_count, bool* ok) { | 867 int* expected_property_count, bool* ok) { |
| 868 UNREACHABLE(); | 868 UNREACHABLE(); |
| 869 } | 869 } |
| 870 | 870 |
| 871 V8_INLINE PreParserStatementList ParseEagerFunctionBody( | 871 V8_INLINE PreParserStatementList ParseEagerFunctionBody( |
| 872 PreParserIdentifier function_name, int pos, | 872 PreParserIdentifier function_name, int pos, |
| 873 const PreParserFormalParameters& parameters, FunctionKind kind, | 873 const PreParserFormalParameters& parameters, FunctionKind kind, |
| 874 FunctionLiteral::FunctionType function_type, bool* ok); | 874 FunctionLiteral::FunctionType function_type, bool* ok); |
| 875 | 875 |
| 876 V8_INLINE void ParseArrowFunctionFormalParameterList( | 876 V8_INLINE void ParseArrowFunctionFormalParameterList( |
| 877 PreParserFormalParameters* parameters, | 877 PreParserFormalParameters* parameters, |
| 878 PreParserExpression expression, const Scanner::Location& params_loc, | 878 PreParserExpression expression, const Scanner::Location& params_loc, |
| 879 Scanner::Location* duplicate_loc, bool* ok); | 879 Scanner::Location* duplicate_loc, bool* ok); |
| 880 | 880 |
| 881 void ParseAsyncArrowSingleExpressionBody( |
| 882 PreParserStatementList body, bool accept_IN, |
| 883 Type::ExpressionClassifier* classifier, int pos, bool* ok); |
| 884 |
| 881 V8_INLINE PreParserExpression ParseAsyncFunctionExpression(bool* ok); | 885 V8_INLINE PreParserExpression ParseAsyncFunctionExpression(bool* ok); |
| 882 | 886 |
| 883 void ReindexLiterals(const PreParserFormalParameters& paramaters) {} | 887 void ReindexLiterals(const PreParserFormalParameters& paramaters) {} |
| 884 | 888 |
| 885 struct TemplateLiteralState {}; | 889 struct TemplateLiteralState {}; |
| 886 | 890 |
| 887 TemplateLiteralState OpenTemplateLiteral(int pos) { | 891 TemplateLiteralState OpenTemplateLiteral(int pos) { |
| 888 return TemplateLiteralState(); | 892 return TemplateLiteralState(); |
| 889 } | 893 } |
| 890 void AddTemplateSpan(TemplateLiteralState*, bool) {} | 894 void AddTemplateSpan(TemplateLiteralState*, bool) {} |
| (...skipping 365 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 1256 const PreParserFormalParameters& parameters, FunctionKind kind, | 1260 const PreParserFormalParameters& parameters, FunctionKind kind, |
| 1257 FunctionLiteral::FunctionType function_type, bool* ok) { | 1261 FunctionLiteral::FunctionType function_type, bool* ok) { |
| 1258 return pre_parser_->ParseEagerFunctionBody(function_name, pos, parameters, | 1262 return pre_parser_->ParseEagerFunctionBody(function_name, pos, parameters, |
| 1259 kind, function_type, ok); | 1263 kind, function_type, ok); |
| 1260 } | 1264 } |
| 1261 | 1265 |
| 1262 } // namespace internal | 1266 } // namespace internal |
| 1263 } // namespace v8 | 1267 } // namespace v8 |
| 1264 | 1268 |
| 1265 #endif // V8_PARSING_PREPARSER_H | 1269 #endif // V8_PARSING_PREPARSER_H |
| OLD | NEW |