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 498 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
509 int pos); | 509 int pos); |
510 | 510 |
511 // Generic AST generator for throwing errors from compiled code. | 511 // Generic AST generator for throwing errors from compiled code. |
512 Expression* NewThrowError( | 512 Expression* NewThrowError( |
513 const AstString* constructor, const char* type, | 513 const AstString* constructor, const char* type, |
514 const AstString* arg, int pos); | 514 const AstString* arg, int pos); |
515 | 515 |
516 // Reporting errors. | 516 // Reporting errors. |
517 void ReportMessageAt(Scanner::Location source_location, | 517 void ReportMessageAt(Scanner::Location source_location, |
518 const char* message, | 518 const char* message, |
519 const char* arg, | 519 const char* arg = NULL, |
520 bool is_reference_error = false); | 520 bool is_reference_error = false); |
521 void ReportMessage(const char* message, | 521 void ReportMessage(const char* message, |
522 const char* arg = NULL, | 522 const char* arg = NULL, |
523 bool is_reference_error = false); | 523 bool is_reference_error = false); |
524 void ReportMessage(const char* message, | 524 void ReportMessage(const char* message, |
525 const AstString* arg, | 525 const AstString* arg, |
526 bool is_reference_error = false); | 526 bool is_reference_error = false); |
527 void ReportMessageAt(Scanner::Location source_location, | 527 void ReportMessageAt(Scanner::Location source_location, |
528 const char* message, | 528 const char* message, |
529 const AstString* arg, | 529 const AstString* arg, |
(...skipping 313 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
843 private: | 843 private: |
844 static const int kLiteralTypeSlot = 0; | 844 static const int kLiteralTypeSlot = 0; |
845 static const int kElementsSlot = 1; | 845 static const int kElementsSlot = 1; |
846 | 846 |
847 DISALLOW_IMPLICIT_CONSTRUCTORS(CompileTimeValue); | 847 DISALLOW_IMPLICIT_CONSTRUCTORS(CompileTimeValue); |
848 }; | 848 }; |
849 | 849 |
850 } } // namespace v8::internal | 850 } } // namespace v8::internal |
851 | 851 |
852 #endif // V8_PARSER_H_ | 852 #endif // V8_PARSER_H_ |
OLD | NEW |