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/base/hashmap.h" | 10 #include "src/base/hashmap.h" |
(...skipping 780 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
791 PreParserIdentifier GetSymbol(Scanner* scanner) const; | 791 PreParserIdentifier GetSymbol(Scanner* scanner) const; |
792 | 792 |
793 PreParserIdentifier GetNextSymbol(Scanner* scanner) const { | 793 PreParserIdentifier GetNextSymbol(Scanner* scanner) const { |
794 return PreParserIdentifier::Default(); | 794 return PreParserIdentifier::Default(); |
795 } | 795 } |
796 | 796 |
797 PreParserIdentifier GetNumberAsSymbol(Scanner* scanner) const { | 797 PreParserIdentifier GetNumberAsSymbol(Scanner* scanner) const { |
798 return PreParserIdentifier::Default(); | 798 return PreParserIdentifier::Default(); |
799 } | 799 } |
800 | 800 |
801 PreParserExpression ThisExpression(int pos = kNoSourcePosition) const { | 801 PreParserExpression ThisExpression(int pos = kNoSourcePosition) { |
802 return PreParserExpression::This(); | 802 return PreParserExpression::This(); |
803 } | 803 } |
804 | 804 |
805 PreParserExpression NewSuperPropertyReference(PreParserFactory* factory, | 805 PreParserExpression NewSuperPropertyReference(PreParserFactory* factory, |
806 int pos) const { | 806 int pos) { |
807 return PreParserExpression::Default(); | 807 return PreParserExpression::Default(); |
808 } | 808 } |
809 | 809 |
810 PreParserExpression NewSuperCallReference(PreParserFactory* factory, | 810 PreParserExpression NewSuperCallReference(PreParserFactory* factory, |
811 int pos) const { | 811 int pos) { |
812 return PreParserExpression::SuperCallReference(); | 812 return PreParserExpression::SuperCallReference(); |
813 } | 813 } |
814 | 814 |
815 PreParserExpression NewTargetExpression(int pos) const { | 815 PreParserExpression NewTargetExpression(int pos) { |
816 return PreParserExpression::Default(); | 816 return PreParserExpression::Default(); |
817 } | 817 } |
818 | 818 |
819 PreParserExpression FunctionSentExpression(PreParserFactory* factory, | 819 PreParserExpression FunctionSentExpression(PreParserFactory* factory, |
820 int pos) const { | 820 int pos) const { |
821 return PreParserExpression::Default(); | 821 return PreParserExpression::Default(); |
822 } | 822 } |
823 | 823 |
824 PreParserExpression ExpressionFromLiteral(Token::Value token, int pos, | 824 PreParserExpression ExpressionFromLiteral(Token::Value token, int pos, |
825 Scanner* scanner, | 825 Scanner* scanner, |
826 PreParserFactory* factory) const { | 826 PreParserFactory* factory) const { |
827 return PreParserExpression::Default(); | 827 return PreParserExpression::Default(); |
828 } | 828 } |
829 | 829 |
830 PreParserExpression ExpressionFromIdentifier( | 830 PreParserExpression ExpressionFromIdentifier(PreParserIdentifier name, |
831 PreParserIdentifier name, int start_position, int end_position, | 831 int start_position, |
832 InferName = InferName::kYes) const { | 832 int end_position, |
| 833 InferName = InferName::kYes) { |
833 return PreParserExpression::FromIdentifier(name); | 834 return PreParserExpression::FromIdentifier(name); |
834 } | 835 } |
835 | 836 |
836 PreParserExpression ExpressionFromString(int pos, Scanner* scanner, | 837 PreParserExpression ExpressionFromString(int pos, Scanner* scanner, |
837 PreParserFactory* factory) const; | 838 PreParserFactory* factory) const; |
838 | 839 |
839 PreParserExpression GetIterator(PreParserExpression iterable, | 840 PreParserExpression GetIterator(PreParserExpression iterable, |
840 PreParserFactory* factory, int pos) { | 841 PreParserFactory* factory, int pos) { |
841 return PreParserExpression::Default(); | 842 return PreParserExpression::Default(); |
842 } | 843 } |
843 | 844 |
844 PreParserExpressionList NewExpressionList(int size, Zone* zone) const { | 845 PreParserExpressionList NewExpressionList(int size, Zone* zone) const { |
845 return PreParserExpressionList(); | 846 return PreParserExpressionList(); |
846 } | 847 } |
847 | 848 |
848 PreParserExpressionList NewPropertyList(int size, Zone* zone) const { | 849 PreParserExpressionList NewPropertyList(int size, Zone* zone) const { |
849 return PreParserExpressionList(); | 850 return PreParserExpressionList(); |
850 } | 851 } |
851 | 852 |
852 PreParserStatementList NewStatementList(int size, Zone* zone) const { | 853 PreParserStatementList NewStatementList(int size, Zone* zone) const { |
853 return PreParserStatementList(); | 854 return PreParserStatementList(); |
854 } | 855 } |
855 | 856 |
856 void AddParameterInitializationBlock( | 857 void AddParameterInitializationBlock( |
857 const PreParserFormalParameters& parameters, PreParserStatementList body, | 858 const PreParserFormalParameters& parameters, PreParserStatementList body, |
858 bool is_async, bool* ok) const {} | 859 bool is_async, bool* ok) {} |
859 | 860 |
860 void ParseAsyncArrowSingleExpressionBody( | 861 void ParseAsyncArrowSingleExpressionBody( |
861 PreParserStatementList body, bool accept_IN, | 862 PreParserStatementList body, bool accept_IN, |
862 Type::ExpressionClassifier* classifier, int pos, bool* ok); | 863 Type::ExpressionClassifier* classifier, int pos, bool* ok); |
863 | 864 |
864 | 865 |
865 void AddFormalParameter(PreParserFormalParameters* parameters, | 866 void AddFormalParameter(PreParserFormalParameters* parameters, |
866 PreParserExpression pattern, | 867 PreParserExpression pattern, |
867 PreParserExpression initializer, | 868 PreParserExpression initializer, |
868 int initializer_end_position, bool is_rest) { | 869 int initializer_end_position, bool is_rest) { |
(...skipping 387 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
1256 pre_parser_->function_state_->NextMaterializedLiteralIndex(); | 1257 pre_parser_->function_state_->NextMaterializedLiteralIndex(); |
1257 pre_parser_->function_state_->NextMaterializedLiteralIndex(); | 1258 pre_parser_->function_state_->NextMaterializedLiteralIndex(); |
1258 } | 1259 } |
1259 return EmptyExpression(); | 1260 return EmptyExpression(); |
1260 } | 1261 } |
1261 | 1262 |
1262 } // namespace internal | 1263 } // namespace internal |
1263 } // namespace v8 | 1264 } // namespace v8 |
1264 | 1265 |
1265 #endif // V8_PARSING_PREPARSER_H | 1266 #endif // V8_PARSING_PREPARSER_H |
OLD | NEW |