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_PARSER_H_ | 5 #ifndef V8_PARSING_PARSER_H_ |
6 #define V8_PARSING_PARSER_H_ | 6 #define V8_PARSING_PARSER_H_ |
7 | 7 |
8 #include "src/allocation.h" | 8 #include "src/allocation.h" |
9 #include "src/ast/ast.h" | 9 #include "src/ast/ast.h" |
10 #include "src/ast/scopes.h" | 10 #include "src/ast/scopes.h" |
(...skipping 737 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
748 void DeserializeScopeChain(ParseInfo* info, Handle<Context> context, | 748 void DeserializeScopeChain(ParseInfo* info, Handle<Context> context, |
749 Scope::DeserializationMode deserialization_mode); | 749 Scope::DeserializationMode deserialization_mode); |
750 | 750 |
751 // Handle errors detected during parsing, move statistics to Isolate, | 751 // Handle errors detected during parsing, move statistics to Isolate, |
752 // internalize strings (move them to the heap). | 752 // internalize strings (move them to the heap). |
753 void Internalize(Isolate* isolate, Handle<Script> script, bool error); | 753 void Internalize(Isolate* isolate, Handle<Script> script, bool error); |
754 void HandleSourceURLComments(Isolate* isolate, Handle<Script> script); | 754 void HandleSourceURLComments(Isolate* isolate, Handle<Script> script); |
755 | 755 |
756 private: | 756 private: |
757 friend class ParserTraits; | 757 friend class ParserTraits; |
758 friend class DiscardableZoneScope; | |
759 | 758 |
760 // Runtime encoding of different completion modes. | 759 // Runtime encoding of different completion modes. |
761 enum CompletionKind { | 760 enum CompletionKind { |
762 kNormalCompletion, | 761 kNormalCompletion, |
763 kThrowCompletion, | 762 kThrowCompletion, |
764 kAbruptCompletion | 763 kAbruptCompletion |
765 }; | 764 }; |
766 | 765 |
767 // Limit the allowed number of local variables in a function. The hard limit | 766 // Limit the allowed number of local variables in a function. The hard limit |
768 // is that offsets computed by FullCodeGenerator::StackOperand and similar | 767 // is that offsets computed by FullCodeGenerator::StackOperand and similar |
(...skipping 586 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
1355 | 1354 |
1356 DoExpression* ParserTraits::ParseDoExpression(bool* ok) { | 1355 DoExpression* ParserTraits::ParseDoExpression(bool* ok) { |
1357 return parser_->ParseDoExpression(ok); | 1356 return parser_->ParseDoExpression(ok); |
1358 } | 1357 } |
1359 | 1358 |
1360 | 1359 |
1361 } // namespace internal | 1360 } // namespace internal |
1362 } // namespace v8 | 1361 } // namespace v8 |
1363 | 1362 |
1364 #endif // V8_PARSING_PARSER_H_ | 1363 #endif // V8_PARSING_PARSER_H_ |
OLD | NEW |