Commit | Line | Data |
---|---|---|
d09b2d29 IZ |
1 | /* !!!!!!! DO NOT EDIT THIS FILE !!!!!!! |
2 | This file is built by regcomp.pl from regcomp.sym. | |
3 | Any changes made here will be lost! | |
4 | */ | |
5 | ||
6 | #define END 0 /* 0 End of program. */ | |
7 | #define SUCCEED 1 /* 0x1 Return from a subroutine, basically. */ | |
8 | #define BOL 2 /* 0x2 Match "" at beginning of line. */ | |
9 | #define MBOL 3 /* 0x3 Same, assuming multiline. */ | |
10 | #define SBOL 4 /* 0x4 Same, assuming singleline. */ | |
b85d18e9 IZ |
11 | #define EOS 5 /* 0x5 Match "" at end of string. */ |
12 | #define EOL 6 /* 0x6 Match "" at end of line. */ | |
13 | #define MEOL 7 /* 0x7 Same, assuming multiline. */ | |
14 | #define SEOL 8 /* 0x8 Same, assuming singleline. */ | |
15 | #define BOUND 9 /* 0x9 Match "" at any word boundary */ | |
16 | #define BOUNDL 10 /* 0xa Match "" at any word boundary */ | |
17 | #define NBOUND 11 /* 0xb Match "" at any word non-boundary */ | |
18 | #define NBOUNDL 12 /* 0xc Match "" at any word non-boundary */ | |
19 | #define GPOS 13 /* 0xd Matches where last m//g left off. */ | |
20 | #define ANY 14 /* 0xe Match any one character (except newline). */ | |
21 | #define SANY 15 /* 0xf Match any one character. */ | |
22 | #define ANYOF 16 /* 0x10 Match character in (or not in) this class. */ | |
23 | #define ALNUM 17 /* 0x11 Match any alphanumeric character */ | |
24 | #define ALNUML 18 /* 0x12 Match any alphanumeric char in locale */ | |
25 | #define NALNUM 19 /* 0x13 Match any non-alphanumeric character */ | |
26 | #define NALNUML 20 /* 0x14 Match any non-alphanumeric char in locale */ | |
27 | #define SPACE 21 /* 0x15 Match any whitespace character */ | |
28 | #define SPACEL 22 /* 0x16 Match any whitespace char in locale */ | |
29 | #define NSPACE 23 /* 0x17 Match any non-whitespace character */ | |
30 | #define NSPACEL 24 /* 0x18 Match any non-whitespace char in locale */ | |
31 | #define DIGIT 25 /* 0x19 Match any numeric character */ | |
32 | #define NDIGIT 26 /* 0x1a Match any non-numeric character */ | |
33 | #define BRANCH 27 /* 0x1b Match this alternative, or the next... */ | |
34 | #define BACK 28 /* 0x1c Match "", "next" ptr points backward. */ | |
35 | #define EXACT 29 /* 0x1d Match this string (preceded by length). */ | |
36 | #define EXACTF 30 /* 0x1e Match this string, folded (prec. by length). */ | |
37 | #define EXACTFL 31 /* 0x1f Match this string, folded in locale (w/len). */ | |
38 | #define NOTHING 32 /* 0x20 Match empty string. */ | |
39 | #define TAIL 33 /* 0x21 Match empty string. Can jump here from outside. */ | |
40 | #define STAR 34 /* 0x22 Match this (simple) thing 0 or more times. */ | |
41 | #define PLUS 35 /* 0x23 Match this (simple) thing 1 or more times. */ | |
42 | #define CURLY 36 /* 0x24 Match this simple thing {n,m} times. */ | |
43 | #define CURLYN 37 /* 0x25 Match next-after-this simple thing */ | |
44 | #define CURLYM 38 /* 0x26 Match this medium-complex thing {n,m} times. */ | |
45 | #define CURLYX 39 /* 0x27 Match this complex thing {n,m} times. */ | |
46 | #define WHILEM 40 /* 0x28 Do curly processing and see if rest matches. */ | |
47 | #define OPEN 41 /* 0x29 Mark this point in input as start of #n. */ | |
48 | #define CLOSE 42 /* 0x2a Analogous to OPEN. */ | |
49 | #define REF 43 /* 0x2b Match some already matched string */ | |
50 | #define REFF 44 /* 0x2c Match already matched string, folded */ | |
51 | #define REFFL 45 /* 0x2d Match already matched string, folded in loc. */ | |
52 | #define IFMATCH 46 /* 0x2e Succeeds if the following matches. */ | |
53 | #define UNLESSM 47 /* 0x2f Fails if the following matches. */ | |
54 | #define SUSPEND 48 /* 0x30 "Independent" sub-RE. */ | |
55 | #define IFTHEN 49 /* 0x31 Switch, should be preceeded by switcher . */ | |
56 | #define GROUPP 50 /* 0x32 Whether the group matched. */ | |
57 | #define LONGJMP 51 /* 0x33 Jump far away. */ | |
58 | #define BRANCHJ 52 /* 0x34 BRANCH with long offset. */ | |
59 | #define EVAL 53 /* 0x35 Execute some Perl code. */ | |
60 | #define MINMOD 54 /* 0x36 Next operator is not greedy. */ | |
61 | #define LOGICAL 55 /* 0x37 Next opcode should set the flag only. */ | |
62 | #define RENUM 56 /* 0x38 Group with independently numbered parens. */ | |
63 | #define OPTIMIZED 57 /* 0x39 Placeholder for dump. */ | |
d09b2d29 IZ |
64 | |
65 | #ifndef DOINIT | |
66 | EXTCONST U8 regkind[]; | |
67 | #else | |
68 | EXTCONST U8 regkind[] = { | |
69 | END, /* END */ | |
70 | END, /* SUCCEED */ | |
71 | BOL, /* BOL */ | |
72 | BOL, /* MBOL */ | |
73 | BOL, /* SBOL */ | |
b85d18e9 | 74 | EOL, /* EOS */ |
d09b2d29 IZ |
75 | EOL, /* EOL */ |
76 | EOL, /* MEOL */ | |
77 | EOL, /* SEOL */ | |
78 | BOUND, /* BOUND */ | |
79 | BOUND, /* BOUNDL */ | |
80 | NBOUND, /* NBOUND */ | |
81 | NBOUND, /* NBOUNDL */ | |
82 | GPOS, /* GPOS */ | |
83 | ANY, /* ANY */ | |
84 | ANY, /* SANY */ | |
85 | ANYOF, /* ANYOF */ | |
86 | ALNUM, /* ALNUM */ | |
87 | ALNUM, /* ALNUML */ | |
88 | NALNUM, /* NALNUM */ | |
89 | NALNUM, /* NALNUML */ | |
90 | SPACE, /* SPACE */ | |
91 | SPACE, /* SPACEL */ | |
92 | NSPACE, /* NSPACE */ | |
93 | NSPACE, /* NSPACEL */ | |
94 | DIGIT, /* DIGIT */ | |
95 | NDIGIT, /* NDIGIT */ | |
96 | BRANCH, /* BRANCH */ | |
97 | BACK, /* BACK */ | |
98 | EXACT, /* EXACT */ | |
99 | EXACT, /* EXACTF */ | |
100 | EXACT, /* EXACTFL */ | |
101 | NOTHING, /* NOTHING */ | |
102 | NOTHING, /* TAIL */ | |
103 | STAR, /* STAR */ | |
104 | PLUS, /* PLUS */ | |
105 | CURLY, /* CURLY */ | |
106 | CURLY, /* CURLYN */ | |
107 | CURLY, /* CURLYM */ | |
108 | CURLY, /* CURLYX */ | |
109 | WHILEM, /* WHILEM */ | |
110 | OPEN, /* OPEN */ | |
111 | CLOSE, /* CLOSE */ | |
112 | REF, /* REF */ | |
113 | REF, /* REFF */ | |
114 | REF, /* REFFL */ | |
115 | BRANCHJ, /* IFMATCH */ | |
116 | BRANCHJ, /* UNLESSM */ | |
117 | BRANCHJ, /* SUSPEND */ | |
118 | BRANCHJ, /* IFTHEN */ | |
119 | GROUPP, /* GROUPP */ | |
120 | LONGJMP, /* LONGJMP */ | |
121 | BRANCHJ, /* BRANCHJ */ | |
122 | EVAL, /* EVAL */ | |
123 | MINMOD, /* MINMOD */ | |
124 | LOGICAL, /* LOGICAL */ | |
125 | BRANCHJ, /* RENUM */ | |
126 | NOTHING, /* OPTIMIZED */ | |
127 | }; | |
128 | #endif | |
129 | ||
130 | ||
131 | #ifdef REG_COMP_C | |
132 | const static U8 regarglen[] = { | |
133 | 0, /* END */ | |
134 | 0, /* SUCCEED */ | |
135 | 0, /* BOL */ | |
136 | 0, /* MBOL */ | |
137 | 0, /* SBOL */ | |
b85d18e9 | 138 | 0, /* EOS */ |
d09b2d29 IZ |
139 | 0, /* EOL */ |
140 | 0, /* MEOL */ | |
141 | 0, /* SEOL */ | |
142 | 0, /* BOUND */ | |
143 | 0, /* BOUNDL */ | |
144 | 0, /* NBOUND */ | |
145 | 0, /* NBOUNDL */ | |
146 | 0, /* GPOS */ | |
147 | 0, /* ANY */ | |
148 | 0, /* SANY */ | |
149 | 0, /* ANYOF */ | |
150 | 0, /* ALNUM */ | |
151 | 0, /* ALNUML */ | |
152 | 0, /* NALNUM */ | |
153 | 0, /* NALNUML */ | |
154 | 0, /* SPACE */ | |
155 | 0, /* SPACEL */ | |
156 | 0, /* NSPACE */ | |
157 | 0, /* NSPACEL */ | |
158 | 0, /* DIGIT */ | |
159 | 0, /* NDIGIT */ | |
160 | 0, /* BRANCH */ | |
161 | 0, /* BACK */ | |
162 | 0, /* EXACT */ | |
163 | 0, /* EXACTF */ | |
164 | 0, /* EXACTFL */ | |
165 | 0, /* NOTHING */ | |
166 | 0, /* TAIL */ | |
167 | 0, /* STAR */ | |
168 | 0, /* PLUS */ | |
169 | EXTRA_SIZE(struct regnode_2), /* CURLY */ | |
170 | EXTRA_SIZE(struct regnode_2), /* CURLYN */ | |
171 | EXTRA_SIZE(struct regnode_2), /* CURLYM */ | |
172 | EXTRA_SIZE(struct regnode_2), /* CURLYX */ | |
173 | 0, /* WHILEM */ | |
174 | EXTRA_SIZE(struct regnode_1), /* OPEN */ | |
175 | EXTRA_SIZE(struct regnode_1), /* CLOSE */ | |
176 | EXTRA_SIZE(struct regnode_1), /* REF */ | |
177 | EXTRA_SIZE(struct regnode_1), /* REFF */ | |
178 | EXTRA_SIZE(struct regnode_1), /* REFFL */ | |
179 | EXTRA_SIZE(struct regnode_1), /* IFMATCH */ | |
180 | EXTRA_SIZE(struct regnode_1), /* UNLESSM */ | |
181 | EXTRA_SIZE(struct regnode_1), /* SUSPEND */ | |
182 | EXTRA_SIZE(struct regnode_1), /* IFTHEN */ | |
183 | EXTRA_SIZE(struct regnode_1), /* GROUPP */ | |
184 | EXTRA_SIZE(struct regnode_1), /* LONGJMP */ | |
185 | EXTRA_SIZE(struct regnode_1), /* BRANCHJ */ | |
186 | EXTRA_SIZE(struct regnode_1), /* EVAL */ | |
187 | 0, /* MINMOD */ | |
188 | 0, /* LOGICAL */ | |
189 | EXTRA_SIZE(struct regnode_1), /* RENUM */ | |
190 | 0, /* OPTIMIZED */ | |
191 | }; | |
192 | ||
193 | const static char reg_off_by_arg[] = { | |
194 | 0, /* END */ | |
195 | 0, /* SUCCEED */ | |
196 | 0, /* BOL */ | |
197 | 0, /* MBOL */ | |
198 | 0, /* SBOL */ | |
b85d18e9 | 199 | 0, /* EOS */ |
d09b2d29 IZ |
200 | 0, /* EOL */ |
201 | 0, /* MEOL */ | |
202 | 0, /* SEOL */ | |
203 | 0, /* BOUND */ | |
204 | 0, /* BOUNDL */ | |
205 | 0, /* NBOUND */ | |
206 | 0, /* NBOUNDL */ | |
207 | 0, /* GPOS */ | |
208 | 0, /* ANY */ | |
209 | 0, /* SANY */ | |
210 | 0, /* ANYOF */ | |
211 | 0, /* ALNUM */ | |
212 | 0, /* ALNUML */ | |
213 | 0, /* NALNUM */ | |
214 | 0, /* NALNUML */ | |
215 | 0, /* SPACE */ | |
216 | 0, /* SPACEL */ | |
217 | 0, /* NSPACE */ | |
218 | 0, /* NSPACEL */ | |
219 | 0, /* DIGIT */ | |
220 | 0, /* NDIGIT */ | |
221 | 0, /* BRANCH */ | |
222 | 0, /* BACK */ | |
223 | 0, /* EXACT */ | |
224 | 0, /* EXACTF */ | |
225 | 0, /* EXACTFL */ | |
226 | 0, /* NOTHING */ | |
227 | 0, /* TAIL */ | |
228 | 0, /* STAR */ | |
229 | 0, /* PLUS */ | |
230 | 0, /* CURLY */ | |
231 | 0, /* CURLYN */ | |
232 | 0, /* CURLYM */ | |
233 | 0, /* CURLYX */ | |
234 | 0, /* WHILEM */ | |
235 | 0, /* OPEN */ | |
236 | 0, /* CLOSE */ | |
237 | 0, /* REF */ | |
238 | 0, /* REFF */ | |
239 | 0, /* REFFL */ | |
240 | 2, /* IFMATCH */ | |
241 | 2, /* UNLESSM */ | |
242 | 1, /* SUSPEND */ | |
243 | 1, /* IFTHEN */ | |
244 | 0, /* GROUPP */ | |
245 | 1, /* LONGJMP */ | |
246 | 1, /* BRANCHJ */ | |
247 | 0, /* EVAL */ | |
248 | 0, /* MINMOD */ | |
249 | 0, /* LOGICAL */ | |
250 | 1, /* RENUM */ | |
251 | 0, /* OPTIMIZED */ | |
252 | }; | |
253 | #endif /* REG_COMP_C */ | |
254 |