| 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 221 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 232 // Parses a {...,...} quantifier and stores the range in the given | 232 // Parses a {...,...} quantifier and stores the range in the given |
| 233 // out parameters. | 233 // out parameters. |
| 234 bool ParseIntervalQuantifier(int* min_out, int* max_out); | 234 bool ParseIntervalQuantifier(int* min_out, int* max_out); |
| 235 | 235 |
| 236 // Parses and returns a single escaped character. The character | 236 // Parses and returns a single escaped character. The character |
| 237 // must not be 'b' or 'B' since they are usually handle specially. | 237 // must not be 'b' or 'B' since they are usually handle specially. |
| 238 uc32 ParseClassCharacterEscape(); | 238 uc32 ParseClassCharacterEscape(); |
| 239 | 239 |
| 240 // Checks whether the following is a length-digit hexadecimal number, | 240 // Checks whether the following is a length-digit hexadecimal number, |
| 241 // and sets the value if it is. | 241 // and sets the value if it is. |
| 242 bool ParseHexEscape(int length, uc32* value); | 242 bool ParseHexEscape(int length, uc32* value, bool allow_brace = false); |
| 243 | 243 |
| 244 uc32 ParseOctalLiteral(); | 244 uc32 ParseOctalLiteral(); |
| 245 | 245 |
| 246 // Tries to parse the input as a back reference. If successful it | 246 // Tries to parse the input as a back reference. If successful it |
| 247 // stores the result in the output parameter and returns true. If | 247 // stores the result in the output parameter and returns true. If |
| 248 // it fails it will push back the characters read so the same characters | 248 // it fails it will push back the characters read so the same characters |
| 249 // can be reparsed. | 249 // can be reparsed. |
| 250 bool ParseBackReferenceIndex(int* index_out); | 250 bool ParseBackReferenceIndex(int* index_out); |
| 251 | 251 |
| 252 CharacterRange ParseClassAtom(uc16* char_class); | 252 CharacterRange ParseClassAtom(uc16* char_class); |
| (...skipping 665 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 918 private: | 918 private: |
| 919 static const int kLiteralTypeSlot = 0; | 919 static const int kLiteralTypeSlot = 0; |
| 920 static const int kElementsSlot = 1; | 920 static const int kElementsSlot = 1; |
| 921 | 921 |
| 922 DISALLOW_IMPLICIT_CONSTRUCTORS(CompileTimeValue); | 922 DISALLOW_IMPLICIT_CONSTRUCTORS(CompileTimeValue); |
| 923 }; | 923 }; |
| 924 | 924 |
| 925 } } // namespace v8::internal | 925 } } // namespace v8::internal |
| 926 | 926 |
| 927 #endif // V8_PARSER_H_ | 927 #endif // V8_PARSER_H_ |
| OLD | NEW |