| OLD | NEW |
| 1 // Copyright 2016 the V8 project authors. All rights reserved. | 1 // Copyright 2016 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_REGEXP_REGEXP_PARSER_H_ | 5 #ifndef V8_REGEXP_REGEXP_PARSER_H_ |
| 6 #define V8_REGEXP_REGEXP_PARSER_H_ | 6 #define V8_REGEXP_REGEXP_PARSER_H_ |
| 7 | 7 |
| 8 #include "src/objects.h" | 8 #include "src/objects.h" |
| 9 #include "src/regexp/regexp-ast.h" | 9 #include "src/regexp/regexp-ast.h" |
| 10 #include "src/zone.h" | 10 #include "src/zone.h" |
| (...skipping 155 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 166 | 166 |
| 167 // Parses and returns a single escaped character. The character | 167 // Parses and returns a single escaped character. The character |
| 168 // must not be 'b' or 'B' since they are usually handle specially. | 168 // must not be 'b' or 'B' since they are usually handle specially. |
| 169 uc32 ParseClassCharacterEscape(); | 169 uc32 ParseClassCharacterEscape(); |
| 170 | 170 |
| 171 // Checks whether the following is a length-digit hexadecimal number, | 171 // Checks whether the following is a length-digit hexadecimal number, |
| 172 // and sets the value if it is. | 172 // and sets the value if it is. |
| 173 bool ParseHexEscape(int length, uc32* value); | 173 bool ParseHexEscape(int length, uc32* value); |
| 174 bool ParseUnicodeEscape(uc32* value); | 174 bool ParseUnicodeEscape(uc32* value); |
| 175 bool ParseUnlimitedLengthHexNumber(int max_value, uc32* value); | 175 bool ParseUnlimitedLengthHexNumber(int max_value, uc32* value); |
| 176 ZoneList<CharacterRange>* ParsePropertyClass(); |
| 176 | 177 |
| 177 uc32 ParseOctalLiteral(); | 178 uc32 ParseOctalLiteral(); |
| 178 | 179 |
| 179 // Tries to parse the input as a back reference. If successful it | 180 // Tries to parse the input as a back reference. If successful it |
| 180 // stores the result in the output parameter and returns true. If | 181 // stores the result in the output parameter and returns true. If |
| 181 // it fails it will push back the characters read so the same characters | 182 // it fails it will push back the characters read so the same characters |
| 182 // can be reparsed. | 183 // can be reparsed. |
| 183 bool ParseBackReferenceIndex(int* index_out); | 184 bool ParseBackReferenceIndex(int* index_out); |
| 184 | 185 |
| 185 CharacterRange ParseClassAtom(uc16* char_class); | 186 CharacterRange ParseClassAtom(uc16* char_class); |
| (...skipping 102 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 288 bool simple_; | 289 bool simple_; |
| 289 bool contains_anchor_; | 290 bool contains_anchor_; |
| 290 bool is_scanned_for_captures_; | 291 bool is_scanned_for_captures_; |
| 291 bool failed_; | 292 bool failed_; |
| 292 }; | 293 }; |
| 293 | 294 |
| 294 } // namespace internal | 295 } // namespace internal |
| 295 } // namespace v8 | 296 } // namespace v8 |
| 296 | 297 |
| 297 #endif // V8_REGEXP_REGEXP_PARSER_H_ | 298 #endif // V8_REGEXP_REGEXP_PARSER_H_ |
| OLD | NEW |