| 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_PARSER_H_ | 5 #ifndef V8_PARSER_H_ |
| 6 #define V8_PARSER_H_ | 6 #define V8_PARSER_H_ |
| 7 | 7 |
| 8 #include "src/allocation.h" | 8 #include "src/allocation.h" |
| 9 #include "src/ast.h" | 9 #include "src/ast.h" |
| 10 #include "src/compiler.h" // For CachedDataMode | 10 #include "src/compiler.h" // For CachedDataMode |
| (...skipping 560 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 571 | 571 |
| 572 // Temporary glue; these functions will move to ParserBase. | 572 // Temporary glue; these functions will move to ParserBase. |
| 573 Expression* ParseV8Intrinsic(bool* ok); | 573 Expression* ParseV8Intrinsic(bool* ok); |
| 574 FunctionLiteral* ParseFunctionLiteral( | 574 FunctionLiteral* ParseFunctionLiteral( |
| 575 Handle<String> name, | 575 Handle<String> name, |
| 576 Scanner::Location function_name_location, | 576 Scanner::Location function_name_location, |
| 577 bool name_is_strict_reserved, | 577 bool name_is_strict_reserved, |
| 578 bool is_generator, | 578 bool is_generator, |
| 579 int function_token_position, | 579 int function_token_position, |
| 580 FunctionLiteral::FunctionType type, | 580 FunctionLiteral::FunctionType type, |
| 581 FunctionLiteral::ArityRestriction arity_restriction, |
| 581 bool* ok); | 582 bool* ok); |
| 582 | 583 |
| 583 private: | 584 private: |
| 584 Parser* parser_; | 585 Parser* parser_; |
| 585 }; | 586 }; |
| 586 | 587 |
| 587 | 588 |
| 588 class Parser : public ParserBase<ParserTraits> { | 589 class Parser : public ParserBase<ParserTraits> { |
| 589 public: | 590 public: |
| 590 explicit Parser(CompilationInfo* info); | 591 explicit Parser(CompilationInfo* info); |
| (...skipping 132 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 723 Statement* init, Expression* cond, Statement* next, Statement* body, | 724 Statement* init, Expression* cond, Statement* next, Statement* body, |
| 724 bool* ok); | 725 bool* ok); |
| 725 | 726 |
| 726 FunctionLiteral* ParseFunctionLiteral( | 727 FunctionLiteral* ParseFunctionLiteral( |
| 727 Handle<String> name, | 728 Handle<String> name, |
| 728 Scanner::Location function_name_location, | 729 Scanner::Location function_name_location, |
| 729 bool name_is_strict_reserved, | 730 bool name_is_strict_reserved, |
| 730 bool is_generator, | 731 bool is_generator, |
| 731 int function_token_position, | 732 int function_token_position, |
| 732 FunctionLiteral::FunctionType type, | 733 FunctionLiteral::FunctionType type, |
| 734 FunctionLiteral::ArityRestriction arity_restriction, |
| 733 bool* ok); | 735 bool* ok); |
| 734 | 736 |
| 735 // Magical syntax support. | 737 // Magical syntax support. |
| 736 Expression* ParseV8Intrinsic(bool* ok); | 738 Expression* ParseV8Intrinsic(bool* ok); |
| 737 | 739 |
| 738 bool CheckInOrOf(bool accept_OF, ForEachStatement::VisitMode* visit_mode); | 740 bool CheckInOrOf(bool accept_OF, ForEachStatement::VisitMode* visit_mode); |
| 739 | 741 |
| 740 // Get odd-ball literals. | 742 // Get odd-ball literals. |
| 741 Literal* GetLiteralUndefined(int position); | 743 Literal* GetLiteralUndefined(int position); |
| 742 | 744 |
| (...skipping 90 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 833 private: | 835 private: |
| 834 static const int kLiteralTypeSlot = 0; | 836 static const int kLiteralTypeSlot = 0; |
| 835 static const int kElementsSlot = 1; | 837 static const int kElementsSlot = 1; |
| 836 | 838 |
| 837 DISALLOW_IMPLICIT_CONSTRUCTORS(CompileTimeValue); | 839 DISALLOW_IMPLICIT_CONSTRUCTORS(CompileTimeValue); |
| 838 }; | 840 }; |
| 839 | 841 |
| 840 } } // namespace v8::internal | 842 } } // namespace v8::internal |
| 841 | 843 |
| 842 #endif // V8_PARSER_H_ | 844 #endif // V8_PARSER_H_ |
| OLD | NEW |