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_REGEXP_JSREGEXP_H_ | 5 #ifndef V8_REGEXP_JSREGEXP_H_ |
6 #define V8_REGEXP_JSREGEXP_H_ | 6 #define V8_REGEXP_JSREGEXP_H_ |
7 | 7 |
8 #include "src/allocation.h" | 8 #include "src/allocation.h" |
9 #include "src/assembler.h" | 9 #include "src/assembler.h" |
10 #include "src/regexp/regexp-ast.h" | 10 #include "src/regexp/regexp-ast.h" |
| 11 #include "src/regexp/regexp-macro-assembler.h" |
11 | 12 |
12 namespace v8 { | 13 namespace v8 { |
13 namespace internal { | 14 namespace internal { |
14 | 15 |
15 class NodeVisitor; | 16 class NodeVisitor; |
16 class RegExpCompiler; | 17 class RegExpCompiler; |
17 class RegExpMacroAssembler; | 18 class RegExpMacroAssembler; |
18 class RegExpNode; | 19 class RegExpNode; |
19 class RegExpTree; | 20 class RegExpTree; |
20 class BoyerMooreLookahead; | 21 class BoyerMooreLookahead; |
21 | 22 |
22 | |
23 static const uc32 kLeadSurrogateStart = 0xd800; | |
24 static const uc32 kLeadSurrogateEnd = 0xdbff; | |
25 static const uc32 kTrailSurrogateStart = 0xdc00; | |
26 static const uc32 kTrailSurrogateEnd = 0xdfff; | |
27 static const uc32 kNonBmpStart = 0x10000; | |
28 static const uc32 kNonBmpEnd = 0x10ffff; | |
29 | |
30 | |
31 class RegExpImpl { | 23 class RegExpImpl { |
32 public: | 24 public: |
33 // Whether V8 is compiled with native regexp support or not. | 25 // Whether V8 is compiled with native regexp support or not. |
34 static bool UsesNativeRegExp() { | 26 static bool UsesNativeRegExp() { |
35 #ifdef V8_INTERPRETED_REGEXP | 27 #ifdef V8_INTERPRETED_REGEXP |
36 return false; | 28 return false; |
37 #else | 29 #else |
38 return true; | 30 return true; |
39 #endif | 31 #endif |
40 } | 32 } |
(...skipping 1547 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
1588 static const int kStringOffset = 0; | 1580 static const int kStringOffset = 0; |
1589 static const int kPatternOffset = 1; | 1581 static const int kPatternOffset = 1; |
1590 static const int kArrayOffset = 2; | 1582 static const int kArrayOffset = 2; |
1591 static const int kLastMatchOffset = 3; | 1583 static const int kLastMatchOffset = 3; |
1592 }; | 1584 }; |
1593 | 1585 |
1594 } // namespace internal | 1586 } // namespace internal |
1595 } // namespace v8 | 1587 } // namespace v8 |
1596 | 1588 |
1597 #endif // V8_REGEXP_JSREGEXP_H_ | 1589 #endif // V8_REGEXP_JSREGEXP_H_ |
OLD | NEW |