This is a live mirror of the Perl 5 development currently hosted at https://github.com/perl/perl5
regen/regcomp.pl: Generate #defines for UTF8ness
[perl5.git] / regnodes.h
1 /* -*- buffer-read-only: t -*-
2    !!!!!!!   DO NOT EDIT THIS FILE   !!!!!!!
3    This file is built by regen/regcomp.pl from regcomp.sym.
4    Any changes made here will be lost!
5  */
6
7 /* Regops and State definitions */
8
9 #define REGNODE_MAX             109
10 #define REGMATCH_STATE_MAX      149
11
12 /* -- For regexec.c to switch on target being utf8 (t8) or not (tb, b='byte');
13  *    same with pattern (p8, pb) -- */
14 #define with_tp_UTF8ness(op, t_utf8, p_utf8)                        \
15                 (((op) << 2) + (cBOOL(t_utf8) << 1) + cBOOL(p_utf8))
16
17 /* The #defines below give both the basic regnode and the expanded version for
18    switching on utf8ness */
19 #define END                           0     /* 0x00 End of program. */
20 #define END_tb_pb                        0  /*      0x000 */
21 #define END_tb_p8                        1  /*      0x001 */
22 #define END_t8_pb                        2  /*      0x002 */
23 #define END_t8_p8                        3  /*      0x003 */
24
25 #define SUCCEED                       1     /* 0x01 Return from a subroutine,
26                                                basically. */
27 #define SUCCEED_tb_pb                    4  /*      0x004 */
28 #define SUCCEED_tb_p8                    5  /*      0x005 */
29 #define SUCCEED_t8_pb                    6  /*      0x006 */
30 #define SUCCEED_t8_p8                    7  /*      0x007 */
31
32 #define SBOL                          2     /* 0x02 Match "" at beginning of
33                                                line: /^/, /\A/ */
34 #define SBOL_tb_pb                       8  /*      0x008 */
35 #define SBOL_tb_p8                       9  /*      0x009 */
36 #define SBOL_t8_pb                      10  /*      0x00a */
37 #define SBOL_t8_p8                      11  /*      0x00b */
38
39 #define BOL                           2     /* 0x02 Match "" at beginning of
40                                                line: /^/, /\A/ */
41 #define BOL_tb_pb                        8  /*      0x008 */
42 #define BOL_tb_p8                        9  /*      0x009 */
43 #define BOL_t8_pb                       10  /*      0x00a */
44 #define BOL_t8_p8                       11  /*      0x00b */
45
46 #define MBOL                          3     /* 0x03 Same, assuming multiline:
47                                                /^/m */
48 #define MBOL_tb_pb                      12  /*      0x00c */
49 #define MBOL_tb_p8                      13  /*      0x00d */
50 #define MBOL_t8_pb                      14  /*      0x00e */
51 #define MBOL_t8_p8                      15  /*      0x00f */
52
53 #define SEOL                          4     /* 0x04 Match "" at end of line:
54                                                /$/ */
55 #define SEOL_tb_pb                      16  /*      0x010 */
56 #define SEOL_tb_p8                      17  /*      0x011 */
57 #define SEOL_t8_pb                      18  /*      0x012 */
58 #define SEOL_t8_p8                      19  /*      0x013 */
59
60 #define EOL                           4     /* 0x04 Match "" at end of line:
61                                                /$/ */
62 #define EOL_tb_pb                       16  /*      0x010 */
63 #define EOL_tb_p8                       17  /*      0x011 */
64 #define EOL_t8_pb                       18  /*      0x012 */
65 #define EOL_t8_p8                       19  /*      0x013 */
66
67 #define MEOL                          5     /* 0x05 Same, assuming multiline:
68                                                /$/m */
69 #define MEOL_tb_pb                      20  /*      0x014 */
70 #define MEOL_tb_p8                      21  /*      0x015 */
71 #define MEOL_t8_pb                      22  /*      0x016 */
72 #define MEOL_t8_p8                      23  /*      0x017 */
73
74 #define EOS                           6     /* 0x06 Match "" at end of string:
75                                                /\z/ */
76 #define EOS_tb_pb                       24  /*      0x018 */
77 #define EOS_tb_p8                       25  /*      0x019 */
78 #define EOS_t8_pb                       26  /*      0x01a */
79 #define EOS_t8_p8                       27  /*      0x01b */
80
81 #define GPOS                          7     /* 0x07 Matches where last m//g
82                                                left off. */
83 #define GPOS_tb_pb                      28  /*      0x01c */
84 #define GPOS_tb_p8                      29  /*      0x01d */
85 #define GPOS_t8_pb                      30  /*      0x01e */
86 #define GPOS_t8_p8                      31  /*      0x01f */
87
88 #define BOUND                         8     /* 0x08 Like BOUNDA for non-utf8,
89                                                otherwise like BOUNDU */
90 #define BOUND_tb_pb                     32  /*      0x020 */
91 #define BOUND_tb_p8                     33  /*      0x021 */
92 #define BOUND_t8_pb                     34  /*      0x022 */
93 #define BOUND_t8_p8                     35  /*      0x023 */
94
95 #define BOUNDL                        9     /* 0x09 Like BOUND/BOUNDU, but \w
96                                                and \W are defined by current
97                                                locale */
98 #define BOUNDL_tb_pb                    36  /*      0x024 */
99 #define BOUNDL_tb_p8                    37  /*      0x025 */
100 #define BOUNDL_t8_pb                    38  /*      0x026 */
101 #define BOUNDL_t8_p8                    39  /*      0x027 */
102
103 #define BOUNDU                       10     /* 0x0a Match "" at any boundary of
104                                                a given type using /u rules. */
105 #define BOUNDU_tb_pb                    40  /*      0x028 */
106 #define BOUNDU_tb_p8                    41  /*      0x029 */
107 #define BOUNDU_t8_pb                    42  /*      0x02a */
108 #define BOUNDU_t8_p8                    43  /*      0x02b */
109
110 #define BOUNDA                       11     /* 0x0b Match "" at any boundary
111                                                between \w\W or \W\w, where \w
112                                                is [_a-zA-Z0-9] */
113 #define BOUNDA_tb_pb                    44  /*      0x02c */
114 #define BOUNDA_tb_p8                    45  /*      0x02d */
115 #define BOUNDA_t8_pb                    46  /*      0x02e */
116 #define BOUNDA_t8_p8                    47  /*      0x02f */
117
118 #define NBOUND                       12     /* 0x0c Like NBOUNDA for non-utf8,
119                                                otherwise like BOUNDU */
120 #define NBOUND_tb_pb                    48  /*      0x030 */
121 #define NBOUND_tb_p8                    49  /*      0x031 */
122 #define NBOUND_t8_pb                    50  /*      0x032 */
123 #define NBOUND_t8_p8                    51  /*      0x033 */
124
125 #define NBOUNDL                      13     /* 0x0d Like NBOUND/NBOUNDU, but \w
126                                                and \W are defined by current
127                                                locale */
128 #define NBOUNDL_tb_pb                   52  /*      0x034 */
129 #define NBOUNDL_tb_p8                   53  /*      0x035 */
130 #define NBOUNDL_t8_pb                   54  /*      0x036 */
131 #define NBOUNDL_t8_p8                   55  /*      0x037 */
132
133 #define NBOUNDU                      14     /* 0x0e Match "" at any
134                                                non-boundary of a given type
135                                                using using /u rules. */
136 #define NBOUNDU_tb_pb                   56  /*      0x038 */
137 #define NBOUNDU_tb_p8                   57  /*      0x039 */
138 #define NBOUNDU_t8_pb                   58  /*      0x03a */
139 #define NBOUNDU_t8_p8                   59  /*      0x03b */
140
141 #define NBOUNDA                      15     /* 0x0f Match "" betweeen any \w\w
142                                                or \W\W, where \w is
143                                                [_a-zA-Z0-9] */
144 #define NBOUNDA_tb_pb                   60  /*      0x03c */
145 #define NBOUNDA_tb_p8                   61  /*      0x03d */
146 #define NBOUNDA_t8_pb                   62  /*      0x03e */
147 #define NBOUNDA_t8_p8                   63  /*      0x03f */
148
149 #define REG_ANY                      16     /* 0x10 Match any one character
150                                                (except newline). */
151 #define REG_ANY_tb_pb                   64  /*      0x040 */
152 #define REG_ANY_tb_p8                   65  /*      0x041 */
153 #define REG_ANY_t8_pb                   66  /*      0x042 */
154 #define REG_ANY_t8_p8                   67  /*      0x043 */
155
156 #define SANY                         17     /* 0x11 Match any one character. */
157 #define SANY_tb_pb                      68  /*      0x044 */
158 #define SANY_tb_p8                      69  /*      0x045 */
159 #define SANY_t8_pb                      70  /*      0x046 */
160 #define SANY_t8_p8                      71  /*      0x047 */
161
162 #define ANYOF                        18     /* 0x12 Match character in (or not
163                                                in) this class, single char
164                                                match only */
165 #define ANYOF_tb_pb                     72  /*      0x048 */
166 #define ANYOF_tb_p8                     73  /*      0x049 */
167 #define ANYOF_t8_pb                     74  /*      0x04a */
168 #define ANYOF_t8_p8                     75  /*      0x04b */
169
170 #define ANYOFD                       19     /* 0x13 Like ANYOF, but /d is in
171                                                effect */
172 #define ANYOFD_tb_pb                    76  /*      0x04c */
173 #define ANYOFD_tb_p8                    77  /*      0x04d */
174 #define ANYOFD_t8_pb                    78  /*      0x04e */
175 #define ANYOFD_t8_p8                    79  /*      0x04f */
176
177 #define ANYOFL                       20     /* 0x14 Like ANYOF, but /l is in
178                                                effect */
179 #define ANYOFL_tb_pb                    80  /*      0x050 */
180 #define ANYOFL_tb_p8                    81  /*      0x051 */
181 #define ANYOFL_t8_pb                    82  /*      0x052 */
182 #define ANYOFL_t8_p8                    83  /*      0x053 */
183
184 #define ANYOFPOSIXL                  21     /* 0x15 Like ANYOFL, but matches
185                                                [[:posix:]] classes */
186 #define ANYOFPOSIXL_tb_pb               84  /*      0x054 */
187 #define ANYOFPOSIXL_tb_p8               85  /*      0x055 */
188 #define ANYOFPOSIXL_t8_pb               86  /*      0x056 */
189 #define ANYOFPOSIXL_t8_p8               87  /*      0x057 */
190
191 #define ANYOFH                       22     /* 0x16 Like ANYOF, but only has
192                                                "High" matches, none in the
193                                                bitmap; the flags field contains
194                                                the lowest matchable UTF-8 start
195                                                byte */
196 #define ANYOFH_tb_pb                    88  /*      0x058 */
197 #define ANYOFH_tb_p8                    89  /*      0x059 */
198 #define ANYOFH_t8_pb                    90  /*      0x05a */
199 #define ANYOFH_t8_p8                    91  /*      0x05b */
200
201 #define ANYOFHb                      23     /* 0x17 Like ANYOFH, but all
202                                                matches share the same UTF-8
203                                                start byte, given in the flags
204                                                field */
205 #define ANYOFHb_tb_pb                   92  /*      0x05c */
206 #define ANYOFHb_tb_p8                   93  /*      0x05d */
207 #define ANYOFHb_t8_pb                   94  /*      0x05e */
208 #define ANYOFHb_t8_p8                   95  /*      0x05f */
209
210 #define ANYOFHr                      24     /* 0x18 Like ANYOFH, but the flags
211                                                field contains packed bounds for
212                                                all matchable UTF-8 start bytes.
213                                             */
214 #define ANYOFHr_tb_pb                   96  /*      0x060 */
215 #define ANYOFHr_tb_p8                   97  /*      0x061 */
216 #define ANYOFHr_t8_pb                   98  /*      0x062 */
217 #define ANYOFHr_t8_p8                   99  /*      0x063 */
218
219 #define ANYOFHs                      25     /* 0x19 Like ANYOFHb, but has a
220                                                string field that gives the
221                                                leading matchable UTF-8 bytes;
222                                                flags field is len */
223 #define ANYOFHs_tb_pb                  100  /*      0x064 */
224 #define ANYOFHs_tb_p8                  101  /*      0x065 */
225 #define ANYOFHs_t8_pb                  102  /*      0x066 */
226 #define ANYOFHs_t8_p8                  103  /*      0x067 */
227
228 #define ANYOFR                       26     /* 0x1a Matches any character in
229                                                the range given by its packed
230                                                args: upper 12 bits is the max
231                                                delta from the base lower 20;
232                                                the flags field contains the
233                                                lowest matchable UTF-8 start
234                                                byte */
235 #define ANYOFR_tb_pb                   104  /*      0x068 */
236 #define ANYOFR_tb_p8                   105  /*      0x069 */
237 #define ANYOFR_t8_pb                   106  /*      0x06a */
238 #define ANYOFR_t8_p8                   107  /*      0x06b */
239
240 #define ANYOFRb                      27     /* 0x1b Like ANYOFR, but all
241                                                matches share the same UTF-8
242                                                start byte, given in the flags
243                                                field */
244 #define ANYOFRb_tb_pb                  108  /*      0x06c */
245 #define ANYOFRb_tb_p8                  109  /*      0x06d */
246 #define ANYOFRb_t8_pb                  110  /*      0x06e */
247 #define ANYOFRb_t8_p8                  111  /*      0x06f */
248
249 #define ANYOFM                       28     /* 0x1c Like ANYOF, but matches an
250                                                invariant byte as determined by
251                                                the mask and arg */
252 #define ANYOFM_tb_pb                   112  /*      0x070 */
253 #define ANYOFM_tb_p8                   113  /*      0x071 */
254 #define ANYOFM_t8_pb                   114  /*      0x072 */
255 #define ANYOFM_t8_p8                   115  /*      0x073 */
256
257 #define NANYOFM                      29     /* 0x1d complement of ANYOFM */
258 #define NANYOFM_tb_pb                  116  /*      0x074 */
259 #define NANYOFM_tb_p8                  117  /*      0x075 */
260 #define NANYOFM_t8_pb                  118  /*      0x076 */
261 #define NANYOFM_t8_p8                  119  /*      0x077 */
262
263 #define POSIXD                       30     /* 0x1e Some [[:class:]] under /d;
264                                                the FLAGS field gives which one
265                                             */
266 #define POSIXD_tb_pb                   120  /*      0x078 */
267 #define POSIXD_tb_p8                   121  /*      0x079 */
268 #define POSIXD_t8_pb                   122  /*      0x07a */
269 #define POSIXD_t8_p8                   123  /*      0x07b */
270
271 #define POSIXL                       31     /* 0x1f Some [[:class:]] under /l;
272                                                the FLAGS field gives which one
273                                             */
274 #define POSIXL_tb_pb                   124  /*      0x07c */
275 #define POSIXL_tb_p8                   125  /*      0x07d */
276 #define POSIXL_t8_pb                   126  /*      0x07e */
277 #define POSIXL_t8_p8                   127  /*      0x07f */
278
279 #define POSIXU                       32     /* 0x20 Some [[:class:]] under /u;
280                                                the FLAGS field gives which one
281                                             */
282 #define POSIXU_tb_pb                   128  /*      0x080 */
283 #define POSIXU_tb_p8                   129  /*      0x081 */
284 #define POSIXU_t8_pb                   130  /*      0x082 */
285 #define POSIXU_t8_p8                   131  /*      0x083 */
286
287 #define POSIXA                       33     /* 0x21 Some [[:class:]] under /a;
288                                                the FLAGS field gives which one
289                                             */
290 #define POSIXA_tb_pb                   132  /*      0x084 */
291 #define POSIXA_tb_p8                   133  /*      0x085 */
292 #define POSIXA_t8_pb                   134  /*      0x086 */
293 #define POSIXA_t8_p8                   135  /*      0x087 */
294
295 #define NPOSIXD                      34     /* 0x22 complement of POSIXD,
296                                                [[:^class:]] */
297 #define NPOSIXD_tb_pb                  136  /*      0x088 */
298 #define NPOSIXD_tb_p8                  137  /*      0x089 */
299 #define NPOSIXD_t8_pb                  138  /*      0x08a */
300 #define NPOSIXD_t8_p8                  139  /*      0x08b */
301
302 #define NPOSIXL                      35     /* 0x23 complement of POSIXL,
303                                                [[:^class:]] */
304 #define NPOSIXL_tb_pb                  140  /*      0x08c */
305 #define NPOSIXL_tb_p8                  141  /*      0x08d */
306 #define NPOSIXL_t8_pb                  142  /*      0x08e */
307 #define NPOSIXL_t8_p8                  143  /*      0x08f */
308
309 #define NPOSIXU                      36     /* 0x24 complement of POSIXU,
310                                                [[:^class:]] */
311 #define NPOSIXU_tb_pb                  144  /*      0x090 */
312 #define NPOSIXU_tb_p8                  145  /*      0x091 */
313 #define NPOSIXU_t8_pb                  146  /*      0x092 */
314 #define NPOSIXU_t8_p8                  147  /*      0x093 */
315
316 #define NPOSIXA                      37     /* 0x25 complement of POSIXA,
317                                                [[:^class:]] */
318 #define NPOSIXA_tb_pb                  148  /*      0x094 */
319 #define NPOSIXA_tb_p8                  149  /*      0x095 */
320 #define NPOSIXA_t8_pb                  150  /*      0x096 */
321 #define NPOSIXA_t8_p8                  151  /*      0x097 */
322
323 #define CLUMP                        38     /* 0x26 Match any extended grapheme
324                                                cluster sequence */
325 #define CLUMP_tb_pb                    152  /*      0x098 */
326 #define CLUMP_tb_p8                    153  /*      0x099 */
327 #define CLUMP_t8_pb                    154  /*      0x09a */
328 #define CLUMP_t8_p8                    155  /*      0x09b */
329
330 #define BRANCH                       39     /* 0x27 Match this alternative, or
331                                                the next... */
332 #define BRANCH_tb_pb                   156  /*      0x09c */
333 #define BRANCH_tb_p8                   157  /*      0x09d */
334 #define BRANCH_t8_pb                   158  /*      0x09e */
335 #define BRANCH_t8_p8                   159  /*      0x09f */
336
337 #define EXACT                        40     /* 0x28 Match this string (flags
338                                                field is the length). */
339 #define EXACT_tb_pb                    160  /*      0x0a0 */
340 #define EXACT_tb_p8                    161  /*      0x0a1 */
341 #define EXACT_t8_pb                    162  /*      0x0a2 */
342 #define EXACT_t8_p8                    163  /*      0x0a3 */
343
344 #define LEXACT                       41     /* 0x29 Match this long string
345                                                (preceded by length; flags
346                                                unused). */
347 #define LEXACT_tb_pb                   164  /*      0x0a4 */
348 #define LEXACT_tb_p8                   165  /*      0x0a5 */
349 #define LEXACT_t8_pb                   166  /*      0x0a6 */
350 #define LEXACT_t8_p8                   167  /*      0x0a7 */
351
352 #define EXACTL                       42     /* 0x2a Like EXACT, but /l is in
353                                                effect (used so locale-related
354                                                warnings can be checked for) */
355 #define EXACTL_tb_pb                   168  /*      0x0a8 */
356 #define EXACTL_tb_p8                   169  /*      0x0a9 */
357 #define EXACTL_t8_pb                   170  /*      0x0aa */
358 #define EXACTL_t8_p8                   171  /*      0x0ab */
359
360 #define EXACTF                       43     /* 0x2b Like EXACT, but match using
361                                                /id rules; (string not UTF-8,
362                                                ASCII folded; non-ASCII not) */
363 #define EXACTF_tb_pb                   172  /*      0x0ac */
364 #define EXACTF_tb_p8                   173  /*      0x0ad */
365 #define EXACTF_t8_pb                   174  /*      0x0ae */
366 #define EXACTF_t8_p8                   175  /*      0x0af */
367
368 #define EXACTFL                      44     /* 0x2c Like EXACT, but match using
369                                                /il rules; (string not likely to
370                                                be folded) */
371 #define EXACTFL_tb_pb                  176  /*      0x0b0 */
372 #define EXACTFL_tb_p8                  177  /*      0x0b1 */
373 #define EXACTFL_t8_pb                  178  /*      0x0b2 */
374 #define EXACTFL_t8_p8                  179  /*      0x0b3 */
375
376 #define EXACTFU                      45     /* 0x2d Like EXACT, but match using
377                                                /iu rules; (string folded) */
378 #define EXACTFU_tb_pb                  180  /*      0x0b4 */
379 #define EXACTFU_tb_p8                  181  /*      0x0b5 */
380 #define EXACTFU_t8_pb                  182  /*      0x0b6 */
381 #define EXACTFU_t8_p8                  183  /*      0x0b7 */
382
383 #define EXACTFAA                     46     /* 0x2e Like EXACT, but match using
384                                                /iaa rules; (string folded
385                                                except in non-UTF8 patterns:
386                                                MICRO, SHARP S; folded length <=
387                                                unfolded) */
388 #define EXACTFAA_tb_pb                 184  /*      0x0b8 */
389 #define EXACTFAA_tb_p8                 185  /*      0x0b9 */
390 #define EXACTFAA_t8_pb                 186  /*      0x0ba */
391 #define EXACTFAA_t8_p8                 187  /*      0x0bb */
392
393 #define EXACTFUP                     47     /* 0x2f Like EXACT, but match using
394                                                /iu rules; (string not UTF-8,
395                                                folded except MICRO, SHARP S:
396                                                hence Problematic) */
397 #define EXACTFUP_tb_pb                 188  /*      0x0bc */
398 #define EXACTFUP_tb_p8                 189  /*      0x0bd */
399 #define EXACTFUP_t8_pb                 190  /*      0x0be */
400 #define EXACTFUP_t8_p8                 191  /*      0x0bf */
401
402 #define EXACTFLU8                    48     /* 0x30 Like EXACTFU, but use /il,
403                                                UTF-8, (string is folded, and
404                                                everything in it is above 255 */
405 #define EXACTFLU8_tb_pb                192  /*      0x0c0 */
406 #define EXACTFLU8_tb_p8                193  /*      0x0c1 */
407 #define EXACTFLU8_t8_pb                194  /*      0x0c2 */
408 #define EXACTFLU8_t8_p8                195  /*      0x0c3 */
409
410 #define EXACTFAA_NO_TRIE             49     /* 0x31 Like EXACT, but match using
411                                                /iaa rules (string not UTF-8,
412                                                not guaranteed to be folded, not
413                                                currently trie-able) */
414 #define EXACTFAA_NO_TRIE_tb_pb         196  /*      0x0c4 */
415 #define EXACTFAA_NO_TRIE_tb_p8         197  /*      0x0c5 */
416 #define EXACTFAA_NO_TRIE_t8_pb         198  /*      0x0c6 */
417 #define EXACTFAA_NO_TRIE_t8_p8         199  /*      0x0c7 */
418
419 #define EXACT_REQ8                   50     /* 0x32 Like EXACT, but only UTF-8
420                                                encoded targets can match */
421 #define EXACT_REQ8_tb_pb               200  /*      0x0c8 */
422 #define EXACT_REQ8_tb_p8               201  /*      0x0c9 */
423 #define EXACT_REQ8_t8_pb               202  /*      0x0ca */
424 #define EXACT_REQ8_t8_p8               203  /*      0x0cb */
425
426 #define LEXACT_REQ8                  51     /* 0x33 Like LEXACT, but only UTF-8
427                                                encoded targets can match */
428 #define LEXACT_REQ8_tb_pb              204  /*      0x0cc */
429 #define LEXACT_REQ8_tb_p8              205  /*      0x0cd */
430 #define LEXACT_REQ8_t8_pb              206  /*      0x0ce */
431 #define LEXACT_REQ8_t8_p8              207  /*      0x0cf */
432
433 #define EXACTFU_REQ8                 52     /* 0x34 Like EXACTFU, but only
434                                                UTF-8 encoded targets can match
435                                             */
436 #define EXACTFU_REQ8_tb_pb             208  /*      0x0d0 */
437 #define EXACTFU_REQ8_tb_p8             209  /*      0x0d1 */
438 #define EXACTFU_REQ8_t8_pb             210  /*      0x0d2 */
439 #define EXACTFU_REQ8_t8_p8             211  /*      0x0d3 */
440
441 #define EXACTFU_S_EDGE               53     /* 0x35 /di rules, but nothing in
442                                                it precludes /ui, except begins
443                                                and/or ends with [Ss]; (string
444                                                not UTF-8; compile-time only) */
445 #define EXACTFU_S_EDGE_tb_pb           212  /*      0x0d4 */
446 #define EXACTFU_S_EDGE_tb_p8           213  /*      0x0d5 */
447 #define EXACTFU_S_EDGE_t8_pb           214  /*      0x0d6 */
448 #define EXACTFU_S_EDGE_t8_p8           215  /*      0x0d7 */
449
450 #define LNBREAK                      54     /* 0x36 generic newline pattern */
451 #define LNBREAK_tb_pb                  216  /*      0x0d8 */
452 #define LNBREAK_tb_p8                  217  /*      0x0d9 */
453 #define LNBREAK_t8_pb                  218  /*      0x0da */
454 #define LNBREAK_t8_p8                  219  /*      0x0db */
455
456 #define TRIE                         55     /* 0x37 Match many EXACT(F[ALU]?)?
457                                                at once. flags==type */
458 #define TRIE_tb_pb                     220  /*      0x0dc */
459 #define TRIE_tb_p8                     221  /*      0x0dd */
460 #define TRIE_t8_pb                     222  /*      0x0de */
461 #define TRIE_t8_p8                     223  /*      0x0df */
462
463 #define TRIEC                        56     /* 0x38 Same as TRIE, but with
464                                                embedded charclass data */
465 #define TRIEC_tb_pb                    224  /*      0x0e0 */
466 #define TRIEC_tb_p8                    225  /*      0x0e1 */
467 #define TRIEC_t8_pb                    226  /*      0x0e2 */
468 #define TRIEC_t8_p8                    227  /*      0x0e3 */
469
470 #define AHOCORASICK                  57     /* 0x39 Aho Corasick stclass.
471                                                flags==type */
472 #define AHOCORASICK_tb_pb              228  /*      0x0e4 */
473 #define AHOCORASICK_tb_p8              229  /*      0x0e5 */
474 #define AHOCORASICK_t8_pb              230  /*      0x0e6 */
475 #define AHOCORASICK_t8_p8              231  /*      0x0e7 */
476
477 #define AHOCORASICKC                 58     /* 0x3a Same as AHOCORASICK, but
478                                                with embedded charclass data */
479 #define AHOCORASICKC_tb_pb             232  /*      0x0e8 */
480 #define AHOCORASICKC_tb_p8             233  /*      0x0e9 */
481 #define AHOCORASICKC_t8_pb             234  /*      0x0ea */
482 #define AHOCORASICKC_t8_p8             235  /*      0x0eb */
483
484 #define NOTHING                      59     /* 0x3b Match empty string. */
485 #define NOTHING_tb_pb                  236  /*      0x0ec */
486 #define NOTHING_tb_p8                  237  /*      0x0ed */
487 #define NOTHING_t8_pb                  238  /*      0x0ee */
488 #define NOTHING_t8_p8                  239  /*      0x0ef */
489
490 #define TAIL                         60     /* 0x3c Match empty string. Can
491                                                jump here from outside. */
492 #define TAIL_tb_pb                     240  /*      0x0f0 */
493 #define TAIL_tb_p8                     241  /*      0x0f1 */
494 #define TAIL_t8_pb                     242  /*      0x0f2 */
495 #define TAIL_t8_p8                     243  /*      0x0f3 */
496
497 #define STAR                         61     /* 0x3d Match this (simple) thing 0
498                                                or more times. */
499 #define STAR_tb_pb                     244  /*      0x0f4 */
500 #define STAR_tb_p8                     245  /*      0x0f5 */
501 #define STAR_t8_pb                     246  /*      0x0f6 */
502 #define STAR_t8_p8                     247  /*      0x0f7 */
503
504 #define PLUS                         62     /* 0x3e Match this (simple) thing 1
505                                                or more times. */
506 #define PLUS_tb_pb                     248  /*      0x0f8 */
507 #define PLUS_tb_p8                     249  /*      0x0f9 */
508 #define PLUS_t8_pb                     250  /*      0x0fa */
509 #define PLUS_t8_p8                     251  /*      0x0fb */
510
511 #define CURLY                        63     /* 0x3f Match this simple thing
512                                                {n,m} times. */
513 #define CURLY_tb_pb                    252  /*      0x0fc */
514 #define CURLY_tb_p8                    253  /*      0x0fd */
515 #define CURLY_t8_pb                    254  /*      0x0fe */
516 #define CURLY_t8_p8                    255  /*      0x0ff */
517
518 #define CURLYN                       64     /* 0x40 Capture next-after-this
519                                                simple thing */
520 #define CURLYN_tb_pb                   256  /*      0x100 */
521 #define CURLYN_tb_p8                   257  /*      0x101 */
522 #define CURLYN_t8_pb                   258  /*      0x102 */
523 #define CURLYN_t8_p8                   259  /*      0x103 */
524
525 #define CURLYM                       65     /* 0x41 Capture this medium-complex
526                                                thing {n,m} times. */
527 #define CURLYM_tb_pb                   260  /*      0x104 */
528 #define CURLYM_tb_p8                   261  /*      0x105 */
529 #define CURLYM_t8_pb                   262  /*      0x106 */
530 #define CURLYM_t8_p8                   263  /*      0x107 */
531
532 #define CURLYX                       66     /* 0x42 Match this complex thing
533                                                {n,m} times. */
534 #define CURLYX_tb_pb                   264  /*      0x108 */
535 #define CURLYX_tb_p8                   265  /*      0x109 */
536 #define CURLYX_t8_pb                   266  /*      0x10a */
537 #define CURLYX_t8_p8                   267  /*      0x10b */
538
539 #define WHILEM                       67     /* 0x43 Do curly processing and see
540                                                if rest matches. */
541 #define WHILEM_tb_pb                   268  /*      0x10c */
542 #define WHILEM_tb_p8                   269  /*      0x10d */
543 #define WHILEM_t8_pb                   270  /*      0x10e */
544 #define WHILEM_t8_p8                   271  /*      0x10f */
545
546 #define OPEN                         68     /* 0x44 Mark this point in input as
547                                                start of #n. */
548 #define OPEN_tb_pb                     272  /*      0x110 */
549 #define OPEN_tb_p8                     273  /*      0x111 */
550 #define OPEN_t8_pb                     274  /*      0x112 */
551 #define OPEN_t8_p8                     275  /*      0x113 */
552
553 #define CLOSE                        69     /* 0x45 Close corresponding OPEN of
554                                                #n. */
555 #define CLOSE_tb_pb                    276  /*      0x114 */
556 #define CLOSE_tb_p8                    277  /*      0x115 */
557 #define CLOSE_t8_pb                    278  /*      0x116 */
558 #define CLOSE_t8_p8                    279  /*      0x117 */
559
560 #define SROPEN                       70     /* 0x46 Same as OPEN, but for
561                                                script run */
562 #define SROPEN_tb_pb                   280  /*      0x118 */
563 #define SROPEN_tb_p8                   281  /*      0x119 */
564 #define SROPEN_t8_pb                   282  /*      0x11a */
565 #define SROPEN_t8_p8                   283  /*      0x11b */
566
567 #define SRCLOSE                      71     /* 0x47 Close preceding SROPEN */
568 #define SRCLOSE_tb_pb                  284  /*      0x11c */
569 #define SRCLOSE_tb_p8                  285  /*      0x11d */
570 #define SRCLOSE_t8_pb                  286  /*      0x11e */
571 #define SRCLOSE_t8_p8                  287  /*      0x11f */
572
573 #define REF                          72     /* 0x48 Match some already matched
574                                                string */
575 #define REF_tb_pb                      288  /*      0x120 */
576 #define REF_tb_p8                      289  /*      0x121 */
577 #define REF_t8_pb                      290  /*      0x122 */
578 #define REF_t8_p8                      291  /*      0x123 */
579
580 #define REFF                         73     /* 0x49 Match already matched
581                                                string, using /di rules. */
582 #define REFF_tb_pb                     292  /*      0x124 */
583 #define REFF_tb_p8                     293  /*      0x125 */
584 #define REFF_t8_pb                     294  /*      0x126 */
585 #define REFF_t8_p8                     295  /*      0x127 */
586
587 #define REFFL                        74     /* 0x4a Match already matched
588                                                string, using /li rules. */
589 #define REFFL_tb_pb                    296  /*      0x128 */
590 #define REFFL_tb_p8                    297  /*      0x129 */
591 #define REFFL_t8_pb                    298  /*      0x12a */
592 #define REFFL_t8_p8                    299  /*      0x12b */
593
594 #define REFFU                        75     /* 0x4b Match already matched
595                                                string, usng /ui. */
596 #define REFFU_tb_pb                    300  /*      0x12c */
597 #define REFFU_tb_p8                    301  /*      0x12d */
598 #define REFFU_t8_pb                    302  /*      0x12e */
599 #define REFFU_t8_p8                    303  /*      0x12f */
600
601 #define REFFA                        76     /* 0x4c Match already matched
602                                                string, using /aai rules. */
603 #define REFFA_tb_pb                    304  /*      0x130 */
604 #define REFFA_tb_p8                    305  /*      0x131 */
605 #define REFFA_t8_pb                    306  /*      0x132 */
606 #define REFFA_t8_p8                    307  /*      0x133 */
607
608 #define REFN                         77     /* 0x4d Match some already matched
609                                                string */
610 #define REFN_tb_pb                     308  /*      0x134 */
611 #define REFN_tb_p8                     309  /*      0x135 */
612 #define REFN_t8_pb                     310  /*      0x136 */
613 #define REFN_t8_p8                     311  /*      0x137 */
614
615 #define REFFN                        78     /* 0x4e Match already matched
616                                                string, using /di rules. */
617 #define REFFN_tb_pb                    312  /*      0x138 */
618 #define REFFN_tb_p8                    313  /*      0x139 */
619 #define REFFN_t8_pb                    314  /*      0x13a */
620 #define REFFN_t8_p8                    315  /*      0x13b */
621
622 #define REFFLN                       79     /* 0x4f Match already matched
623                                                string, using /li rules. */
624 #define REFFLN_tb_pb                   316  /*      0x13c */
625 #define REFFLN_tb_p8                   317  /*      0x13d */
626 #define REFFLN_t8_pb                   318  /*      0x13e */
627 #define REFFLN_t8_p8                   319  /*      0x13f */
628
629 #define REFFUN                       80     /* 0x50 Match already matched
630                                                string, using /ui rules. */
631 #define REFFUN_tb_pb                   320  /*      0x140 */
632 #define REFFUN_tb_p8                   321  /*      0x141 */
633 #define REFFUN_t8_pb                   322  /*      0x142 */
634 #define REFFUN_t8_p8                   323  /*      0x143 */
635
636 #define REFFAN                       81     /* 0x51 Match already matched
637                                                string, using /aai rules. */
638 #define REFFAN_tb_pb                   324  /*      0x144 */
639 #define REFFAN_tb_p8                   325  /*      0x145 */
640 #define REFFAN_t8_pb                   326  /*      0x146 */
641 #define REFFAN_t8_p8                   327  /*      0x147 */
642
643 #define LONGJMP                      82     /* 0x52 Jump far away. */
644 #define LONGJMP_tb_pb                  328  /*      0x148 */
645 #define LONGJMP_tb_p8                  329  /*      0x149 */
646 #define LONGJMP_t8_pb                  330  /*      0x14a */
647 #define LONGJMP_t8_p8                  331  /*      0x14b */
648
649 #define BRANCHJ                      83     /* 0x53 BRANCH with long offset. */
650 #define BRANCHJ_tb_pb                  332  /*      0x14c */
651 #define BRANCHJ_tb_p8                  333  /*      0x14d */
652 #define BRANCHJ_t8_pb                  334  /*      0x14e */
653 #define BRANCHJ_t8_p8                  335  /*      0x14f */
654
655 #define IFMATCH                      84     /* 0x54 Succeeds if the following
656                                                matches; non-zero flags "f",
657                                                next_off "o" means lookbehind
658                                                assertion starting "f..(f-o)"
659                                                characters before current */
660 #define IFMATCH_tb_pb                  336  /*      0x150 */
661 #define IFMATCH_tb_p8                  337  /*      0x151 */
662 #define IFMATCH_t8_pb                  338  /*      0x152 */
663 #define IFMATCH_t8_p8                  339  /*      0x153 */
664
665 #define UNLESSM                      85     /* 0x55 Fails if the following
666                                                matches; non-zero flags "f",
667                                                next_off "o" means lookbehind
668                                                assertion starting "f..(f-o)"
669                                                characters before current */
670 #define UNLESSM_tb_pb                  340  /*      0x154 */
671 #define UNLESSM_tb_p8                  341  /*      0x155 */
672 #define UNLESSM_t8_pb                  342  /*      0x156 */
673 #define UNLESSM_t8_p8                  343  /*      0x157 */
674
675 #define SUSPEND                      86     /* 0x56 "Independent" sub-RE. */
676 #define SUSPEND_tb_pb                  344  /*      0x158 */
677 #define SUSPEND_tb_p8                  345  /*      0x159 */
678 #define SUSPEND_t8_pb                  346  /*      0x15a */
679 #define SUSPEND_t8_p8                  347  /*      0x15b */
680
681 #define IFTHEN                       87     /* 0x57 Switch, should be preceded
682                                                by switcher. */
683 #define IFTHEN_tb_pb                   348  /*      0x15c */
684 #define IFTHEN_tb_p8                   349  /*      0x15d */
685 #define IFTHEN_t8_pb                   350  /*      0x15e */
686 #define IFTHEN_t8_p8                   351  /*      0x15f */
687
688 #define GROUPP                       88     /* 0x58 Whether the group matched.
689                                             */
690 #define GROUPP_tb_pb                   352  /*      0x160 */
691 #define GROUPP_tb_p8                   353  /*      0x161 */
692 #define GROUPP_t8_pb                   354  /*      0x162 */
693 #define GROUPP_t8_p8                   355  /*      0x163 */
694
695 #define EVAL                         89     /* 0x59 Execute some Perl code. */
696 #define EVAL_tb_pb                     356  /*      0x164 */
697 #define EVAL_tb_p8                     357  /*      0x165 */
698 #define EVAL_t8_pb                     358  /*      0x166 */
699 #define EVAL_t8_p8                     359  /*      0x167 */
700
701 #define MINMOD                       90     /* 0x5a Next operator is not
702                                                greedy. */
703 #define MINMOD_tb_pb                   360  /*      0x168 */
704 #define MINMOD_tb_p8                   361  /*      0x169 */
705 #define MINMOD_t8_pb                   362  /*      0x16a */
706 #define MINMOD_t8_p8                   363  /*      0x16b */
707
708 #define LOGICAL                      91     /* 0x5b Next opcode should set the
709                                                flag only. */
710 #define LOGICAL_tb_pb                  364  /*      0x16c */
711 #define LOGICAL_tb_p8                  365  /*      0x16d */
712 #define LOGICAL_t8_pb                  366  /*      0x16e */
713 #define LOGICAL_t8_p8                  367  /*      0x16f */
714
715 #define RENUM                        92     /* 0x5c Group with independently
716                                                numbered parens. */
717 #define RENUM_tb_pb                    368  /*      0x170 */
718 #define RENUM_tb_p8                    369  /*      0x171 */
719 #define RENUM_t8_pb                    370  /*      0x172 */
720 #define RENUM_t8_p8                    371  /*      0x173 */
721
722 #define GOSUB                        93     /* 0x5d recurse to paren arg1 at
723                                                (signed) ofs arg2 */
724 #define GOSUB_tb_pb                    372  /*      0x174 */
725 #define GOSUB_tb_p8                    373  /*      0x175 */
726 #define GOSUB_t8_pb                    374  /*      0x176 */
727 #define GOSUB_t8_p8                    375  /*      0x177 */
728
729 #define GROUPPN                      94     /* 0x5e Whether the group matched.
730                                             */
731 #define GROUPPN_tb_pb                  376  /*      0x178 */
732 #define GROUPPN_tb_p8                  377  /*      0x179 */
733 #define GROUPPN_t8_pb                  378  /*      0x17a */
734 #define GROUPPN_t8_p8                  379  /*      0x17b */
735
736 #define INSUBP                       95     /* 0x5f Whether we are in a
737                                                specific recurse. */
738 #define INSUBP_tb_pb                   380  /*      0x17c */
739 #define INSUBP_tb_p8                   381  /*      0x17d */
740 #define INSUBP_t8_pb                   382  /*      0x17e */
741 #define INSUBP_t8_p8                   383  /*      0x17f */
742
743 #define DEFINEP                      96     /* 0x60 Never execute directly. */
744 #define DEFINEP_tb_pb                  384  /*      0x180 */
745 #define DEFINEP_tb_p8                  385  /*      0x181 */
746 #define DEFINEP_t8_pb                  386  /*      0x182 */
747 #define DEFINEP_t8_p8                  387  /*      0x183 */
748
749 #define ENDLIKE                      97     /* 0x61 Used only for the type
750                                                field of verbs */
751 #define ENDLIKE_tb_pb                  388  /*      0x184 */
752 #define ENDLIKE_tb_p8                  389  /*      0x185 */
753 #define ENDLIKE_t8_pb                  390  /*      0x186 */
754 #define ENDLIKE_t8_p8                  391  /*      0x187 */
755
756 #define OPFAIL                       98     /* 0x62 Same as (?!), but with verb
757                                                arg */
758 #define OPFAIL_tb_pb                   392  /*      0x188 */
759 #define OPFAIL_tb_p8                   393  /*      0x189 */
760 #define OPFAIL_t8_pb                   394  /*      0x18a */
761 #define OPFAIL_t8_p8                   395  /*      0x18b */
762
763 #define ACCEPT                       99     /* 0x63 Accepts the current matched
764                                                string, with verbar */
765 #define ACCEPT_tb_pb                   396  /*      0x18c */
766 #define ACCEPT_tb_p8                   397  /*      0x18d */
767 #define ACCEPT_t8_pb                   398  /*      0x18e */
768 #define ACCEPT_t8_p8                   399  /*      0x18f */
769
770 #define VERB                        100     /* 0x64 Used only for the type
771                                                field of verbs */
772 #define VERB_tb_pb                     400  /*      0x190 */
773 #define VERB_tb_p8                     401  /*      0x191 */
774 #define VERB_t8_pb                     402  /*      0x192 */
775 #define VERB_t8_p8                     403  /*      0x193 */
776
777 #define PRUNE                       101     /* 0x65 Pattern fails at this
778                                                startpoint if no-backtracking
779                                                through this */
780 #define PRUNE_tb_pb                    404  /*      0x194 */
781 #define PRUNE_tb_p8                    405  /*      0x195 */
782 #define PRUNE_t8_pb                    406  /*      0x196 */
783 #define PRUNE_t8_p8                    407  /*      0x197 */
784
785 #define MARKPOINT                   102     /* 0x66 Push the current location
786                                                for rollback by cut. */
787 #define MARKPOINT_tb_pb                408  /*      0x198 */
788 #define MARKPOINT_tb_p8                409  /*      0x199 */
789 #define MARKPOINT_t8_pb                410  /*      0x19a */
790 #define MARKPOINT_t8_p8                411  /*      0x19b */
791
792 #define SKIP                        103     /* 0x67 On failure skip forward (to
793                                                the mark) before retrying */
794 #define SKIP_tb_pb                     412  /*      0x19c */
795 #define SKIP_tb_p8                     413  /*      0x19d */
796 #define SKIP_t8_pb                     414  /*      0x19e */
797 #define SKIP_t8_p8                     415  /*      0x19f */
798
799 #define COMMIT                      104     /* 0x68 Pattern fails outright if
800                                                backtracking through this */
801 #define COMMIT_tb_pb                   416  /*      0x1a0 */
802 #define COMMIT_tb_p8                   417  /*      0x1a1 */
803 #define COMMIT_t8_pb                   418  /*      0x1a2 */
804 #define COMMIT_t8_p8                   419  /*      0x1a3 */
805
806 #define CUTGROUP                    105     /* 0x69 On failure go to the next
807                                                alternation in the group */
808 #define CUTGROUP_tb_pb                 420  /*      0x1a4 */
809 #define CUTGROUP_tb_p8                 421  /*      0x1a5 */
810 #define CUTGROUP_t8_pb                 422  /*      0x1a6 */
811 #define CUTGROUP_t8_p8                 423  /*      0x1a7 */
812
813 #define KEEPS                       106     /* 0x6a $& begins here. */
814 #define KEEPS_tb_pb                    424  /*      0x1a8 */
815 #define KEEPS_tb_p8                    425  /*      0x1a9 */
816 #define KEEPS_t8_pb                    426  /*      0x1aa */
817 #define KEEPS_t8_p8                    427  /*      0x1ab */
818
819 #define OPTIMIZED                   107     /* 0x6b Placeholder for dump. */
820 #define OPTIMIZED_tb_pb                428  /*      0x1ac */
821 #define OPTIMIZED_tb_p8                429  /*      0x1ad */
822 #define OPTIMIZED_t8_pb                430  /*      0x1ae */
823 #define OPTIMIZED_t8_p8                431  /*      0x1af */
824
825 #define PSEUDO                      108     /* 0x6c Pseudo opcode for internal
826                                                use. */
827 #define PSEUDO_tb_pb                   432  /*      0x1b0 */
828 #define PSEUDO_tb_p8                   433  /*      0x1b1 */
829 #define PSEUDO_t8_pb                   434  /*      0x1b2 */
830 #define PSEUDO_t8_p8                   435  /*      0x1b3 */
831
832 #define REGEX_SET                   109     /* 0x6d Regex set, temporary node
833                                                used in pre-optimization
834                                                compilation */
835 #define REGEX_SET_tb_pb                436  /*      0x1b4 */
836 #define REGEX_SET_tb_p8                437  /*      0x1b5 */
837 #define REGEX_SET_t8_pb                438  /*      0x1b6 */
838 #define REGEX_SET_t8_p8                439  /*      0x1b7 */
839
840         /* ------------ States ------------- */
841 #define TRIE_next                   110     /* 0x6e state for TRIE */
842 #define TRIE_next_tb_pb                440  /*      0x1b8 */
843 #define TRIE_next_tb_p8                441  /*      0x1b9 */
844 #define TRIE_next_t8_pb                442  /*      0x1ba */
845 #define TRIE_next_t8_p8                443  /*      0x1bb */
846
847 #define TRIE_next_fail              111     /* 0x6f state for TRIE */
848 #define TRIE_next_fail_tb_pb           444  /*      0x1bc */
849 #define TRIE_next_fail_tb_p8           445  /*      0x1bd */
850 #define TRIE_next_fail_t8_pb           446  /*      0x1be */
851 #define TRIE_next_fail_t8_p8           447  /*      0x1bf */
852
853 #define EVAL_B                      112     /* 0x70 state for EVAL */
854 #define EVAL_B_tb_pb                   448  /*      0x1c0 */
855 #define EVAL_B_tb_p8                   449  /*      0x1c1 */
856 #define EVAL_B_t8_pb                   450  /*      0x1c2 */
857 #define EVAL_B_t8_p8                   451  /*      0x1c3 */
858
859 #define EVAL_B_fail                 113     /* 0x71 state for EVAL */
860 #define EVAL_B_fail_tb_pb              452  /*      0x1c4 */
861 #define EVAL_B_fail_tb_p8              453  /*      0x1c5 */
862 #define EVAL_B_fail_t8_pb              454  /*      0x1c6 */
863 #define EVAL_B_fail_t8_p8              455  /*      0x1c7 */
864
865 #define EVAL_postponed_AB           114     /* 0x72 state for EVAL */
866 #define EVAL_postponed_AB_tb_pb        456  /*      0x1c8 */
867 #define EVAL_postponed_AB_tb_p8        457  /*      0x1c9 */
868 #define EVAL_postponed_AB_t8_pb        458  /*      0x1ca */
869 #define EVAL_postponed_AB_t8_p8        459  /*      0x1cb */
870
871 #define EVAL_postponed_AB_fail      115     /* 0x73 state for EVAL */
872 #define EVAL_postponed_AB_fail_tb_pb   460  /*      0x1cc */
873 #define EVAL_postponed_AB_fail_tb_p8   461  /*      0x1cd */
874 #define EVAL_postponed_AB_fail_t8_pb   462  /*      0x1ce */
875 #define EVAL_postponed_AB_fail_t8_p8   463  /*      0x1cf */
876
877 #define CURLYX_end                  116     /* 0x74 state for CURLYX */
878 #define CURLYX_end_tb_pb               464  /*      0x1d0 */
879 #define CURLYX_end_tb_p8               465  /*      0x1d1 */
880 #define CURLYX_end_t8_pb               466  /*      0x1d2 */
881 #define CURLYX_end_t8_p8               467  /*      0x1d3 */
882
883 #define CURLYX_end_fail             117     /* 0x75 state for CURLYX */
884 #define CURLYX_end_fail_tb_pb          468  /*      0x1d4 */
885 #define CURLYX_end_fail_tb_p8          469  /*      0x1d5 */
886 #define CURLYX_end_fail_t8_pb          470  /*      0x1d6 */
887 #define CURLYX_end_fail_t8_p8          471  /*      0x1d7 */
888
889 #define WHILEM_A_pre                118     /* 0x76 state for WHILEM */
890 #define WHILEM_A_pre_tb_pb             472  /*      0x1d8 */
891 #define WHILEM_A_pre_tb_p8             473  /*      0x1d9 */
892 #define WHILEM_A_pre_t8_pb             474  /*      0x1da */
893 #define WHILEM_A_pre_t8_p8             475  /*      0x1db */
894
895 #define WHILEM_A_pre_fail           119     /* 0x77 state for WHILEM */
896 #define WHILEM_A_pre_fail_tb_pb        476  /*      0x1dc */
897 #define WHILEM_A_pre_fail_tb_p8        477  /*      0x1dd */
898 #define WHILEM_A_pre_fail_t8_pb        478  /*      0x1de */
899 #define WHILEM_A_pre_fail_t8_p8        479  /*      0x1df */
900
901 #define WHILEM_A_min                120     /* 0x78 state for WHILEM */
902 #define WHILEM_A_min_tb_pb             480  /*      0x1e0 */
903 #define WHILEM_A_min_tb_p8             481  /*      0x1e1 */
904 #define WHILEM_A_min_t8_pb             482  /*      0x1e2 */
905 #define WHILEM_A_min_t8_p8             483  /*      0x1e3 */
906
907 #define WHILEM_A_min_fail           121     /* 0x79 state for WHILEM */
908 #define WHILEM_A_min_fail_tb_pb        484  /*      0x1e4 */
909 #define WHILEM_A_min_fail_tb_p8        485  /*      0x1e5 */
910 #define WHILEM_A_min_fail_t8_pb        486  /*      0x1e6 */
911 #define WHILEM_A_min_fail_t8_p8        487  /*      0x1e7 */
912
913 #define WHILEM_A_max                122     /* 0x7a state for WHILEM */
914 #define WHILEM_A_max_tb_pb             488  /*      0x1e8 */
915 #define WHILEM_A_max_tb_p8             489  /*      0x1e9 */
916 #define WHILEM_A_max_t8_pb             490  /*      0x1ea */
917 #define WHILEM_A_max_t8_p8             491  /*      0x1eb */
918
919 #define WHILEM_A_max_fail           123     /* 0x7b state for WHILEM */
920 #define WHILEM_A_max_fail_tb_pb        492  /*      0x1ec */
921 #define WHILEM_A_max_fail_tb_p8        493  /*      0x1ed */
922 #define WHILEM_A_max_fail_t8_pb        494  /*      0x1ee */
923 #define WHILEM_A_max_fail_t8_p8        495  /*      0x1ef */
924
925 #define WHILEM_B_min                124     /* 0x7c state for WHILEM */
926 #define WHILEM_B_min_tb_pb             496  /*      0x1f0 */
927 #define WHILEM_B_min_tb_p8             497  /*      0x1f1 */
928 #define WHILEM_B_min_t8_pb             498  /*      0x1f2 */
929 #define WHILEM_B_min_t8_p8             499  /*      0x1f3 */
930
931 #define WHILEM_B_min_fail           125     /* 0x7d state for WHILEM */
932 #define WHILEM_B_min_fail_tb_pb        500  /*      0x1f4 */
933 #define WHILEM_B_min_fail_tb_p8        501  /*      0x1f5 */
934 #define WHILEM_B_min_fail_t8_pb        502  /*      0x1f6 */
935 #define WHILEM_B_min_fail_t8_p8        503  /*      0x1f7 */
936
937 #define WHILEM_B_max                126     /* 0x7e state for WHILEM */
938 #define WHILEM_B_max_tb_pb             504  /*      0x1f8 */
939 #define WHILEM_B_max_tb_p8             505  /*      0x1f9 */
940 #define WHILEM_B_max_t8_pb             506  /*      0x1fa */
941 #define WHILEM_B_max_t8_p8             507  /*      0x1fb */
942
943 #define WHILEM_B_max_fail           127     /* 0x7f state for WHILEM */
944 #define WHILEM_B_max_fail_tb_pb        508  /*      0x1fc */
945 #define WHILEM_B_max_fail_tb_p8        509  /*      0x1fd */
946 #define WHILEM_B_max_fail_t8_pb        510  /*      0x1fe */
947 #define WHILEM_B_max_fail_t8_p8        511  /*      0x1ff */
948
949 #define BRANCH_next                 128     /* 0x80 state for BRANCH */
950 #define BRANCH_next_tb_pb              512  /*      0x200 */
951 #define BRANCH_next_tb_p8              513  /*      0x201 */
952 #define BRANCH_next_t8_pb              514  /*      0x202 */
953 #define BRANCH_next_t8_p8              515  /*      0x203 */
954
955 #define BRANCH_next_fail            129     /* 0x81 state for BRANCH */
956 #define BRANCH_next_fail_tb_pb         516  /*      0x204 */
957 #define BRANCH_next_fail_tb_p8         517  /*      0x205 */
958 #define BRANCH_next_fail_t8_pb         518  /*      0x206 */
959 #define BRANCH_next_fail_t8_p8         519  /*      0x207 */
960
961 #define CURLYM_A                    130     /* 0x82 state for CURLYM */
962 #define CURLYM_A_tb_pb                 520  /*      0x208 */
963 #define CURLYM_A_tb_p8                 521  /*      0x209 */
964 #define CURLYM_A_t8_pb                 522  /*      0x20a */
965 #define CURLYM_A_t8_p8                 523  /*      0x20b */
966
967 #define CURLYM_A_fail               131     /* 0x83 state for CURLYM */
968 #define CURLYM_A_fail_tb_pb            524  /*      0x20c */
969 #define CURLYM_A_fail_tb_p8            525  /*      0x20d */
970 #define CURLYM_A_fail_t8_pb            526  /*      0x20e */
971 #define CURLYM_A_fail_t8_p8            527  /*      0x20f */
972
973 #define CURLYM_B                    132     /* 0x84 state for CURLYM */
974 #define CURLYM_B_tb_pb                 528  /*      0x210 */
975 #define CURLYM_B_tb_p8                 529  /*      0x211 */
976 #define CURLYM_B_t8_pb                 530  /*      0x212 */
977 #define CURLYM_B_t8_p8                 531  /*      0x213 */
978
979 #define CURLYM_B_fail               133     /* 0x85 state for CURLYM */
980 #define CURLYM_B_fail_tb_pb            532  /*      0x214 */
981 #define CURLYM_B_fail_tb_p8            533  /*      0x215 */
982 #define CURLYM_B_fail_t8_pb            534  /*      0x216 */
983 #define CURLYM_B_fail_t8_p8            535  /*      0x217 */
984
985 #define IFMATCH_A                   134     /* 0x86 state for IFMATCH */
986 #define IFMATCH_A_tb_pb                536  /*      0x218 */
987 #define IFMATCH_A_tb_p8                537  /*      0x219 */
988 #define IFMATCH_A_t8_pb                538  /*      0x21a */
989 #define IFMATCH_A_t8_p8                539  /*      0x21b */
990
991 #define IFMATCH_A_fail              135     /* 0x87 state for IFMATCH */
992 #define IFMATCH_A_fail_tb_pb           540  /*      0x21c */
993 #define IFMATCH_A_fail_tb_p8           541  /*      0x21d */
994 #define IFMATCH_A_fail_t8_pb           542  /*      0x21e */
995 #define IFMATCH_A_fail_t8_p8           543  /*      0x21f */
996
997 #define CURLY_B_min                 136     /* 0x88 state for CURLY */
998 #define CURLY_B_min_tb_pb              544  /*      0x220 */
999 #define CURLY_B_min_tb_p8              545  /*      0x221 */
1000 #define CURLY_B_min_t8_pb              546  /*      0x222 */
1001 #define CURLY_B_min_t8_p8              547  /*      0x223 */
1002
1003 #define CURLY_B_min_fail            137     /* 0x89 state for CURLY */
1004 #define CURLY_B_min_fail_tb_pb         548  /*      0x224 */
1005 #define CURLY_B_min_fail_tb_p8         549  /*      0x225 */
1006 #define CURLY_B_min_fail_t8_pb         550  /*      0x226 */
1007 #define CURLY_B_min_fail_t8_p8         551  /*      0x227 */
1008
1009 #define CURLY_B_max                 138     /* 0x8a state for CURLY */
1010 #define CURLY_B_max_tb_pb              552  /*      0x228 */
1011 #define CURLY_B_max_tb_p8              553  /*      0x229 */
1012 #define CURLY_B_max_t8_pb              554  /*      0x22a */
1013 #define CURLY_B_max_t8_p8              555  /*      0x22b */
1014
1015 #define CURLY_B_max_fail            139     /* 0x8b state for CURLY */
1016 #define CURLY_B_max_fail_tb_pb         556  /*      0x22c */
1017 #define CURLY_B_max_fail_tb_p8         557  /*      0x22d */
1018 #define CURLY_B_max_fail_t8_pb         558  /*      0x22e */
1019 #define CURLY_B_max_fail_t8_p8         559  /*      0x22f */
1020
1021 #define COMMIT_next                 140     /* 0x8c state for COMMIT */
1022 #define COMMIT_next_tb_pb              560  /*      0x230 */
1023 #define COMMIT_next_tb_p8              561  /*      0x231 */
1024 #define COMMIT_next_t8_pb              562  /*      0x232 */
1025 #define COMMIT_next_t8_p8              563  /*      0x233 */
1026
1027 #define COMMIT_next_fail            141     /* 0x8d state for COMMIT */
1028 #define COMMIT_next_fail_tb_pb         564  /*      0x234 */
1029 #define COMMIT_next_fail_tb_p8         565  /*      0x235 */
1030 #define COMMIT_next_fail_t8_pb         566  /*      0x236 */
1031 #define COMMIT_next_fail_t8_p8         567  /*      0x237 */
1032
1033 #define MARKPOINT_next              142     /* 0x8e state for MARKPOINT */
1034 #define MARKPOINT_next_tb_pb           568  /*      0x238 */
1035 #define MARKPOINT_next_tb_p8           569  /*      0x239 */
1036 #define MARKPOINT_next_t8_pb           570  /*      0x23a */
1037 #define MARKPOINT_next_t8_p8           571  /*      0x23b */
1038
1039 #define MARKPOINT_next_fail         143     /* 0x8f state for MARKPOINT */
1040 #define MARKPOINT_next_fail_tb_pb      572  /*      0x23c */
1041 #define MARKPOINT_next_fail_tb_p8      573  /*      0x23d */
1042 #define MARKPOINT_next_fail_t8_pb      574  /*      0x23e */
1043 #define MARKPOINT_next_fail_t8_p8      575  /*      0x23f */
1044
1045 #define SKIP_next                   144     /* 0x90 state for SKIP */
1046 #define SKIP_next_tb_pb                576  /*      0x240 */
1047 #define SKIP_next_tb_p8                577  /*      0x241 */
1048 #define SKIP_next_t8_pb                578  /*      0x242 */
1049 #define SKIP_next_t8_p8                579  /*      0x243 */
1050
1051 #define SKIP_next_fail              145     /* 0x91 state for SKIP */
1052 #define SKIP_next_fail_tb_pb           580  /*      0x244 */
1053 #define SKIP_next_fail_tb_p8           581  /*      0x245 */
1054 #define SKIP_next_fail_t8_pb           582  /*      0x246 */
1055 #define SKIP_next_fail_t8_p8           583  /*      0x247 */
1056
1057 #define CUTGROUP_next               146     /* 0x92 state for CUTGROUP */
1058 #define CUTGROUP_next_tb_pb            584  /*      0x248 */
1059 #define CUTGROUP_next_tb_p8            585  /*      0x249 */
1060 #define CUTGROUP_next_t8_pb            586  /*      0x24a */
1061 #define CUTGROUP_next_t8_p8            587  /*      0x24b */
1062
1063 #define CUTGROUP_next_fail          147     /* 0x93 state for CUTGROUP */
1064 #define CUTGROUP_next_fail_tb_pb       588  /*      0x24c */
1065 #define CUTGROUP_next_fail_tb_p8       589  /*      0x24d */
1066 #define CUTGROUP_next_fail_t8_pb       590  /*      0x24e */
1067 #define CUTGROUP_next_fail_t8_p8       591  /*      0x24f */
1068
1069 #define KEEPS_next                  148     /* 0x94 state for KEEPS */
1070 #define KEEPS_next_tb_pb               592  /*      0x250 */
1071 #define KEEPS_next_tb_p8               593  /*      0x251 */
1072 #define KEEPS_next_t8_pb               594  /*      0x252 */
1073 #define KEEPS_next_t8_p8               595  /*      0x253 */
1074
1075 #define KEEPS_next_fail             149     /* 0x95 state for KEEPS */
1076 #define KEEPS_next_fail_tb_pb          596  /*      0x254 */
1077 #define KEEPS_next_fail_tb_p8          597  /*      0x255 */
1078 #define KEEPS_next_fail_t8_pb          598  /*      0x256 */
1079 #define KEEPS_next_fail_t8_p8          599  /*      0x257 */
1080
1081
1082 /* PL_regkind[] What type of regop or state is this. */
1083
1084 #ifndef DOINIT
1085 EXTCONST U8 PL_regkind[];
1086 #else
1087 EXTCONST U8 PL_regkind[] = {
1088         END,            /* END                    */
1089         END,            /* SUCCEED                */
1090         BOL,            /* SBOL                   */
1091         BOL,            /* MBOL                   */
1092         EOL,            /* SEOL                   */
1093         EOL,            /* MEOL                   */
1094         EOL,            /* EOS                    */
1095         GPOS,           /* GPOS                   */
1096         BOUND,          /* BOUND                  */
1097         BOUND,          /* BOUNDL                 */
1098         BOUND,          /* BOUNDU                 */
1099         BOUND,          /* BOUNDA                 */
1100         NBOUND,         /* NBOUND                 */
1101         NBOUND,         /* NBOUNDL                */
1102         NBOUND,         /* NBOUNDU                */
1103         NBOUND,         /* NBOUNDA                */
1104         REG_ANY,        /* REG_ANY                */
1105         REG_ANY,        /* SANY                   */
1106         ANYOF,          /* ANYOF                  */
1107         ANYOF,          /* ANYOFD                 */
1108         ANYOF,          /* ANYOFL                 */
1109         ANYOF,          /* ANYOFPOSIXL            */
1110         ANYOF,          /* ANYOFH                 */
1111         ANYOF,          /* ANYOFHb                */
1112         ANYOF,          /* ANYOFHr                */
1113         ANYOF,          /* ANYOFHs                */
1114         ANYOFR,         /* ANYOFR                 */
1115         ANYOFR,         /* ANYOFRb                */
1116         ANYOFM,         /* ANYOFM                 */
1117         ANYOFM,         /* NANYOFM                */
1118         POSIXD,         /* POSIXD                 */
1119         POSIXD,         /* POSIXL                 */
1120         POSIXD,         /* POSIXU                 */
1121         POSIXD,         /* POSIXA                 */
1122         NPOSIXD,        /* NPOSIXD                */
1123         NPOSIXD,        /* NPOSIXL                */
1124         NPOSIXD,        /* NPOSIXU                */
1125         NPOSIXD,        /* NPOSIXA                */
1126         CLUMP,          /* CLUMP                  */
1127         BRANCH,         /* BRANCH                 */
1128         EXACT,          /* EXACT                  */
1129         EXACT,          /* LEXACT                 */
1130         EXACT,          /* EXACTL                 */
1131         EXACT,          /* EXACTF                 */
1132         EXACT,          /* EXACTFL                */
1133         EXACT,          /* EXACTFU                */
1134         EXACT,          /* EXACTFAA               */
1135         EXACT,          /* EXACTFUP               */
1136         EXACT,          /* EXACTFLU8              */
1137         EXACT,          /* EXACTFAA_NO_TRIE       */
1138         EXACT,          /* EXACT_REQ8             */
1139         EXACT,          /* LEXACT_REQ8            */
1140         EXACT,          /* EXACTFU_REQ8           */
1141         EXACT,          /* EXACTFU_S_EDGE         */
1142         LNBREAK,        /* LNBREAK                */
1143         TRIE,           /* TRIE                   */
1144         TRIE,           /* TRIEC                  */
1145         TRIE,           /* AHOCORASICK            */
1146         TRIE,           /* AHOCORASICKC           */
1147         NOTHING,        /* NOTHING                */
1148         NOTHING,        /* TAIL                   */
1149         STAR,           /* STAR                   */
1150         PLUS,           /* PLUS                   */
1151         CURLY,          /* CURLY                  */
1152         CURLY,          /* CURLYN                 */
1153         CURLY,          /* CURLYM                 */
1154         CURLY,          /* CURLYX                 */
1155         WHILEM,         /* WHILEM                 */
1156         OPEN,           /* OPEN                   */
1157         CLOSE,          /* CLOSE                  */
1158         SROPEN,         /* SROPEN                 */
1159         SRCLOSE,        /* SRCLOSE                */
1160         REF,            /* REF                    */
1161         REF,            /* REFF                   */
1162         REF,            /* REFFL                  */
1163         REF,            /* REFFU                  */
1164         REF,            /* REFFA                  */
1165         REF,            /* REFN                   */
1166         REF,            /* REFFN                  */
1167         REF,            /* REFFLN                 */
1168         REF,            /* REFFUN                 */
1169         REF,            /* REFFAN                 */
1170         LONGJMP,        /* LONGJMP                */
1171         BRANCHJ,        /* BRANCHJ                */
1172         BRANCHJ,        /* IFMATCH                */
1173         BRANCHJ,        /* UNLESSM                */
1174         BRANCHJ,        /* SUSPEND                */
1175         BRANCHJ,        /* IFTHEN                 */
1176         GROUPP,         /* GROUPP                 */
1177         EVAL,           /* EVAL                   */
1178         MINMOD,         /* MINMOD                 */
1179         LOGICAL,        /* LOGICAL                */
1180         BRANCHJ,        /* RENUM                  */
1181         GOSUB,          /* GOSUB                  */
1182         GROUPPN,        /* GROUPPN                */
1183         INSUBP,         /* INSUBP                 */
1184         DEFINEP,        /* DEFINEP                */
1185         ENDLIKE,        /* ENDLIKE                */
1186         ENDLIKE,        /* OPFAIL                 */
1187         ENDLIKE,        /* ACCEPT                 */
1188         VERB,           /* VERB                   */
1189         VERB,           /* PRUNE                  */
1190         VERB,           /* MARKPOINT              */
1191         VERB,           /* SKIP                   */
1192         VERB,           /* COMMIT                 */
1193         VERB,           /* CUTGROUP               */
1194         KEEPS,          /* KEEPS                  */
1195         NOTHING,        /* OPTIMIZED              */
1196         PSEUDO,         /* PSEUDO                 */
1197         REGEX_SET,      /* REGEX_SET              */
1198         /* ------------ States ------------- */
1199         TRIE,           /* TRIE_next              */
1200         TRIE,           /* TRIE_next_fail         */
1201         EVAL,           /* EVAL_B                 */
1202         EVAL,           /* EVAL_B_fail            */
1203         EVAL,           /* EVAL_postponed_AB      */
1204         EVAL,           /* EVAL_postponed_AB_fail */
1205         CURLYX,         /* CURLYX_end             */
1206         CURLYX,         /* CURLYX_end_fail        */
1207         WHILEM,         /* WHILEM_A_pre           */
1208         WHILEM,         /* WHILEM_A_pre_fail      */
1209         WHILEM,         /* WHILEM_A_min           */
1210         WHILEM,         /* WHILEM_A_min_fail      */
1211         WHILEM,         /* WHILEM_A_max           */
1212         WHILEM,         /* WHILEM_A_max_fail      */
1213         WHILEM,         /* WHILEM_B_min           */
1214         WHILEM,         /* WHILEM_B_min_fail      */
1215         WHILEM,         /* WHILEM_B_max           */
1216         WHILEM,         /* WHILEM_B_max_fail      */
1217         BRANCH,         /* BRANCH_next            */
1218         BRANCH,         /* BRANCH_next_fail       */
1219         CURLYM,         /* CURLYM_A               */
1220         CURLYM,         /* CURLYM_A_fail          */
1221         CURLYM,         /* CURLYM_B               */
1222         CURLYM,         /* CURLYM_B_fail          */
1223         IFMATCH,        /* IFMATCH_A              */
1224         IFMATCH,        /* IFMATCH_A_fail         */
1225         CURLY,          /* CURLY_B_min            */
1226         CURLY,          /* CURLY_B_min_fail       */
1227         CURLY,          /* CURLY_B_max            */
1228         CURLY,          /* CURLY_B_max_fail       */
1229         COMMIT,         /* COMMIT_next            */
1230         COMMIT,         /* COMMIT_next_fail       */
1231         MARKPOINT,      /* MARKPOINT_next         */
1232         MARKPOINT,      /* MARKPOINT_next_fail    */
1233         SKIP,           /* SKIP_next              */
1234         SKIP,           /* SKIP_next_fail         */
1235         CUTGROUP,       /* CUTGROUP_next          */
1236         CUTGROUP,       /* CUTGROUP_next_fail     */
1237         KEEPS,          /* KEEPS_next             */
1238         KEEPS,          /* KEEPS_next_fail        */
1239 };
1240 #endif
1241
1242 #ifdef REG_COMP_C
1243
1244 /* regarglen[] - How large is the argument part of the node (in regnodes) */
1245
1246 static const U8 regarglen[] = {
1247         0,                                      /* END          */
1248         0,                                      /* SUCCEED      */
1249         0,                                      /* SBOL         */
1250         0,                                      /* MBOL         */
1251         0,                                      /* SEOL         */
1252         0,                                      /* MEOL         */
1253         0,                                      /* EOS          */
1254         0,                                      /* GPOS         */
1255         0,                                      /* BOUND        */
1256         0,                                      /* BOUNDL       */
1257         0,                                      /* BOUNDU       */
1258         0,                                      /* BOUNDA       */
1259         0,                                      /* NBOUND       */
1260         0,                                      /* NBOUNDL      */
1261         0,                                      /* NBOUNDU      */
1262         0,                                      /* NBOUNDA      */
1263         0,                                      /* REG_ANY      */
1264         0,                                      /* SANY         */
1265         EXTRA_SIZE(struct regnode_charclass),   /* ANYOF        */
1266         EXTRA_SIZE(struct regnode_charclass),   /* ANYOFD       */
1267         EXTRA_SIZE(struct regnode_charclass),   /* ANYOFL       */
1268         EXTRA_SIZE(struct regnode_charclass_posixl),    /* ANYOFPOSIXL  */
1269         EXTRA_SIZE(struct regnode_1),           /* ANYOFH       */
1270         EXTRA_SIZE(struct regnode_1),           /* ANYOFHb      */
1271         EXTRA_SIZE(struct regnode_1),           /* ANYOFHr      */
1272         EXTRA_SIZE(struct regnode_1),           /* ANYOFHs      */
1273         EXTRA_SIZE(struct regnode_1),           /* ANYOFR       */
1274         EXTRA_SIZE(struct regnode_1),           /* ANYOFRb      */
1275         EXTRA_SIZE(struct regnode_1),           /* ANYOFM       */
1276         EXTRA_SIZE(struct regnode_1),           /* NANYOFM      */
1277         0,                                      /* POSIXD       */
1278         0,                                      /* POSIXL       */
1279         0,                                      /* POSIXU       */
1280         0,                                      /* POSIXA       */
1281         0,                                      /* NPOSIXD      */
1282         0,                                      /* NPOSIXL      */
1283         0,                                      /* NPOSIXU      */
1284         0,                                      /* NPOSIXA      */
1285         0,                                      /* CLUMP        */
1286         0,                                      /* BRANCH       */
1287         0,                                      /* EXACT        */
1288         EXTRA_SIZE(struct regnode_1),           /* LEXACT       */
1289         0,                                      /* EXACTL       */
1290         0,                                      /* EXACTF       */
1291         0,                                      /* EXACTFL      */
1292         0,                                      /* EXACTFU      */
1293         0,                                      /* EXACTFAA     */
1294         0,                                      /* EXACTFUP     */
1295         0,                                      /* EXACTFLU8    */
1296         0,                                      /* EXACTFAA_NO_TRIE */
1297         0,                                      /* EXACT_REQ8   */
1298         EXTRA_SIZE(struct regnode_1),           /* LEXACT_REQ8  */
1299         0,                                      /* EXACTFU_REQ8 */
1300         0,                                      /* EXACTFU_S_EDGE */
1301         0,                                      /* LNBREAK      */
1302         EXTRA_SIZE(struct regnode_1),           /* TRIE         */
1303         EXTRA_SIZE(struct regnode_charclass),   /* TRIEC        */
1304         EXTRA_SIZE(struct regnode_1),           /* AHOCORASICK  */
1305         EXTRA_SIZE(struct regnode_charclass),   /* AHOCORASICKC */
1306         0,                                      /* NOTHING      */
1307         0,                                      /* TAIL         */
1308         0,                                      /* STAR         */
1309         0,                                      /* PLUS         */
1310         EXTRA_SIZE(struct regnode_2),           /* CURLY        */
1311         EXTRA_SIZE(struct regnode_2),           /* CURLYN       */
1312         EXTRA_SIZE(struct regnode_2),           /* CURLYM       */
1313         EXTRA_SIZE(struct regnode_2),           /* CURLYX       */
1314         0,                                      /* WHILEM       */
1315         EXTRA_SIZE(struct regnode_1),           /* OPEN         */
1316         EXTRA_SIZE(struct regnode_1),           /* CLOSE        */
1317         0,                                      /* SROPEN       */
1318         0,                                      /* SRCLOSE      */
1319         EXTRA_SIZE(struct regnode_1),           /* REF          */
1320         EXTRA_SIZE(struct regnode_1),           /* REFF         */
1321         EXTRA_SIZE(struct regnode_1),           /* REFFL        */
1322         EXTRA_SIZE(struct regnode_1),           /* REFFU        */
1323         EXTRA_SIZE(struct regnode_1),           /* REFFA        */
1324         EXTRA_SIZE(struct regnode_1),           /* REFN         */
1325         EXTRA_SIZE(struct regnode_1),           /* REFFN        */
1326         EXTRA_SIZE(struct regnode_1),           /* REFFLN       */
1327         EXTRA_SIZE(struct regnode_1),           /* REFFUN       */
1328         EXTRA_SIZE(struct regnode_1),           /* REFFAN       */
1329         EXTRA_SIZE(struct regnode_1),           /* LONGJMP      */
1330         EXTRA_SIZE(struct regnode_1),           /* BRANCHJ      */
1331         EXTRA_SIZE(struct regnode_1),           /* IFMATCH      */
1332         EXTRA_SIZE(struct regnode_1),           /* UNLESSM      */
1333         EXTRA_SIZE(struct regnode_1),           /* SUSPEND      */
1334         EXTRA_SIZE(struct regnode_1),           /* IFTHEN       */
1335         EXTRA_SIZE(struct regnode_1),           /* GROUPP       */
1336         EXTRA_SIZE(struct regnode_2L),          /* EVAL         */
1337         0,                                      /* MINMOD       */
1338         0,                                      /* LOGICAL      */
1339         EXTRA_SIZE(struct regnode_1),           /* RENUM        */
1340         EXTRA_SIZE(struct regnode_2L),          /* GOSUB        */
1341         EXTRA_SIZE(struct regnode_1),           /* GROUPPN      */
1342         EXTRA_SIZE(struct regnode_1),           /* INSUBP       */
1343         EXTRA_SIZE(struct regnode_1),           /* DEFINEP      */
1344         0,                                      /* ENDLIKE      */
1345         EXTRA_SIZE(struct regnode_1),           /* OPFAIL       */
1346         EXTRA_SIZE(struct regnode_2L),          /* ACCEPT       */
1347         EXTRA_SIZE(struct regnode_1),           /* VERB         */
1348         EXTRA_SIZE(struct regnode_1),           /* PRUNE        */
1349         EXTRA_SIZE(struct regnode_1),           /* MARKPOINT    */
1350         EXTRA_SIZE(struct regnode_1),           /* SKIP         */
1351         EXTRA_SIZE(struct regnode_1),           /* COMMIT       */
1352         EXTRA_SIZE(struct regnode_1),           /* CUTGROUP     */
1353         0,                                      /* KEEPS        */
1354         0,                                      /* OPTIMIZED    */
1355         0,                                      /* PSEUDO       */
1356         EXTRA_SIZE(struct regnode_p),           /* REGEX_SET    */
1357 };
1358
1359 /* reg_off_by_arg[] - Which argument holds the offset to the next node */
1360
1361 static const char reg_off_by_arg[] = {
1362         0,      /* END          */
1363         0,      /* SUCCEED      */
1364         0,      /* SBOL         */
1365         0,      /* MBOL         */
1366         0,      /* SEOL         */
1367         0,      /* MEOL         */
1368         0,      /* EOS          */
1369         0,      /* GPOS         */
1370         0,      /* BOUND        */
1371         0,      /* BOUNDL       */
1372         0,      /* BOUNDU       */
1373         0,      /* BOUNDA       */
1374         0,      /* NBOUND       */
1375         0,      /* NBOUNDL      */
1376         0,      /* NBOUNDU      */
1377         0,      /* NBOUNDA      */
1378         0,      /* REG_ANY      */
1379         0,      /* SANY         */
1380         0,      /* ANYOF        */
1381         0,      /* ANYOFD       */
1382         0,      /* ANYOFL       */
1383         0,      /* ANYOFPOSIXL  */
1384         0,      /* ANYOFH       */
1385         0,      /* ANYOFHb      */
1386         0,      /* ANYOFHr      */
1387         0,      /* ANYOFHs      */
1388         0,      /* ANYOFR       */
1389         0,      /* ANYOFRb      */
1390         0,      /* ANYOFM       */
1391         0,      /* NANYOFM      */
1392         0,      /* POSIXD       */
1393         0,      /* POSIXL       */
1394         0,      /* POSIXU       */
1395         0,      /* POSIXA       */
1396         0,      /* NPOSIXD      */
1397         0,      /* NPOSIXL      */
1398         0,      /* NPOSIXU      */
1399         0,      /* NPOSIXA      */
1400         0,      /* CLUMP        */
1401         0,      /* BRANCH       */
1402         0,      /* EXACT        */
1403         0,      /* LEXACT       */
1404         0,      /* EXACTL       */
1405         0,      /* EXACTF       */
1406         0,      /* EXACTFL      */
1407         0,      /* EXACTFU      */
1408         0,      /* EXACTFAA     */
1409         0,      /* EXACTFUP     */
1410         0,      /* EXACTFLU8    */
1411         0,      /* EXACTFAA_NO_TRIE */
1412         0,      /* EXACT_REQ8   */
1413         0,      /* LEXACT_REQ8  */
1414         0,      /* EXACTFU_REQ8 */
1415         0,      /* EXACTFU_S_EDGE */
1416         0,      /* LNBREAK      */
1417         0,      /* TRIE         */
1418         0,      /* TRIEC        */
1419         0,      /* AHOCORASICK  */
1420         0,      /* AHOCORASICKC */
1421         0,      /* NOTHING      */
1422         0,      /* TAIL         */
1423         0,      /* STAR         */
1424         0,      /* PLUS         */
1425         0,      /* CURLY        */
1426         0,      /* CURLYN       */
1427         0,      /* CURLYM       */
1428         0,      /* CURLYX       */
1429         0,      /* WHILEM       */
1430         0,      /* OPEN         */
1431         0,      /* CLOSE        */
1432         0,      /* SROPEN       */
1433         0,      /* SRCLOSE      */
1434         0,      /* REF          */
1435         0,      /* REFF         */
1436         0,      /* REFFL        */
1437         0,      /* REFFU        */
1438         0,      /* REFFA        */
1439         0,      /* REFN         */
1440         0,      /* REFFN        */
1441         0,      /* REFFLN       */
1442         0,      /* REFFUN       */
1443         0,      /* REFFAN       */
1444         1,      /* LONGJMP      */
1445         1,      /* BRANCHJ      */
1446         1,      /* IFMATCH      */
1447         1,      /* UNLESSM      */
1448         1,      /* SUSPEND      */
1449         1,      /* IFTHEN       */
1450         0,      /* GROUPP       */
1451         0,      /* EVAL         */
1452         0,      /* MINMOD       */
1453         0,      /* LOGICAL      */
1454         1,      /* RENUM        */
1455         0,      /* GOSUB        */
1456         0,      /* GROUPPN      */
1457         0,      /* INSUBP       */
1458         0,      /* DEFINEP      */
1459         0,      /* ENDLIKE      */
1460         0,      /* OPFAIL       */
1461         0,      /* ACCEPT       */
1462         0,      /* VERB         */
1463         0,      /* PRUNE        */
1464         0,      /* MARKPOINT    */
1465         0,      /* SKIP         */
1466         0,      /* COMMIT       */
1467         0,      /* CUTGROUP     */
1468         0,      /* KEEPS        */
1469         0,      /* OPTIMIZED    */
1470         0,      /* PSEUDO       */
1471         0,      /* REGEX_SET    */
1472 };
1473
1474 #endif /* REG_COMP_C */
1475
1476
1477 /* reg_name[] - Opcode/state names in string form, for debugging */
1478
1479 #ifndef DOINIT
1480 EXTCONST char * PL_reg_name[];
1481 #else
1482 EXTCONST char * const PL_reg_name[] = {
1483         "END",                          /* 0000 */
1484         "SUCCEED",                      /* 0x01 */
1485         "SBOL",                         /* 0x02 */
1486         "MBOL",                         /* 0x03 */
1487         "SEOL",                         /* 0x04 */
1488         "MEOL",                         /* 0x05 */
1489         "EOS",                          /* 0x06 */
1490         "GPOS",                         /* 0x07 */
1491         "BOUND",                        /* 0x08 */
1492         "BOUNDL",                       /* 0x09 */
1493         "BOUNDU",                       /* 0x0a */
1494         "BOUNDA",                       /* 0x0b */
1495         "NBOUND",                       /* 0x0c */
1496         "NBOUNDL",                      /* 0x0d */
1497         "NBOUNDU",                      /* 0x0e */
1498         "NBOUNDA",                      /* 0x0f */
1499         "REG_ANY",                      /* 0x10 */
1500         "SANY",                         /* 0x11 */
1501         "ANYOF",                        /* 0x12 */
1502         "ANYOFD",                       /* 0x13 */
1503         "ANYOFL",                       /* 0x14 */
1504         "ANYOFPOSIXL",                  /* 0x15 */
1505         "ANYOFH",                       /* 0x16 */
1506         "ANYOFHb",                      /* 0x17 */
1507         "ANYOFHr",                      /* 0x18 */
1508         "ANYOFHs",                      /* 0x19 */
1509         "ANYOFR",                       /* 0x1a */
1510         "ANYOFRb",                      /* 0x1b */
1511         "ANYOFM",                       /* 0x1c */
1512         "NANYOFM",                      /* 0x1d */
1513         "POSIXD",                       /* 0x1e */
1514         "POSIXL",                       /* 0x1f */
1515         "POSIXU",                       /* 0x20 */
1516         "POSIXA",                       /* 0x21 */
1517         "NPOSIXD",                      /* 0x22 */
1518         "NPOSIXL",                      /* 0x23 */
1519         "NPOSIXU",                      /* 0x24 */
1520         "NPOSIXA",                      /* 0x25 */
1521         "CLUMP",                        /* 0x26 */
1522         "BRANCH",                       /* 0x27 */
1523         "EXACT",                        /* 0x28 */
1524         "LEXACT",                       /* 0x29 */
1525         "EXACTL",                       /* 0x2a */
1526         "EXACTF",                       /* 0x2b */
1527         "EXACTFL",                      /* 0x2c */
1528         "EXACTFU",                      /* 0x2d */
1529         "EXACTFAA",                     /* 0x2e */
1530         "EXACTFUP",                     /* 0x2f */
1531         "EXACTFLU8",                    /* 0x30 */
1532         "EXACTFAA_NO_TRIE",             /* 0x31 */
1533         "EXACT_REQ8",                   /* 0x32 */
1534         "LEXACT_REQ8",                  /* 0x33 */
1535         "EXACTFU_REQ8",                 /* 0x34 */
1536         "EXACTFU_S_EDGE",               /* 0x35 */
1537         "LNBREAK",                      /* 0x36 */
1538         "TRIE",                         /* 0x37 */
1539         "TRIEC",                        /* 0x38 */
1540         "AHOCORASICK",                  /* 0x39 */
1541         "AHOCORASICKC",                 /* 0x3a */
1542         "NOTHING",                      /* 0x3b */
1543         "TAIL",                         /* 0x3c */
1544         "STAR",                         /* 0x3d */
1545         "PLUS",                         /* 0x3e */
1546         "CURLY",                        /* 0x3f */
1547         "CURLYN",                       /* 0x40 */
1548         "CURLYM",                       /* 0x41 */
1549         "CURLYX",                       /* 0x42 */
1550         "WHILEM",                       /* 0x43 */
1551         "OPEN",                         /* 0x44 */
1552         "CLOSE",                        /* 0x45 */
1553         "SROPEN",                       /* 0x46 */
1554         "SRCLOSE",                      /* 0x47 */
1555         "REF",                          /* 0x48 */
1556         "REFF",                         /* 0x49 */
1557         "REFFL",                        /* 0x4a */
1558         "REFFU",                        /* 0x4b */
1559         "REFFA",                        /* 0x4c */
1560         "REFN",                         /* 0x4d */
1561         "REFFN",                        /* 0x4e */
1562         "REFFLN",                       /* 0x4f */
1563         "REFFUN",                       /* 0x50 */
1564         "REFFAN",                       /* 0x51 */
1565         "LONGJMP",                      /* 0x52 */
1566         "BRANCHJ",                      /* 0x53 */
1567         "IFMATCH",                      /* 0x54 */
1568         "UNLESSM",                      /* 0x55 */
1569         "SUSPEND",                      /* 0x56 */
1570         "IFTHEN",                       /* 0x57 */
1571         "GROUPP",                       /* 0x58 */
1572         "EVAL",                         /* 0x59 */
1573         "MINMOD",                       /* 0x5a */
1574         "LOGICAL",                      /* 0x5b */
1575         "RENUM",                        /* 0x5c */
1576         "GOSUB",                        /* 0x5d */
1577         "GROUPPN",                      /* 0x5e */
1578         "INSUBP",                       /* 0x5f */
1579         "DEFINEP",                      /* 0x60 */
1580         "ENDLIKE",                      /* 0x61 */
1581         "OPFAIL",                       /* 0x62 */
1582         "ACCEPT",                       /* 0x63 */
1583         "VERB",                         /* 0x64 */
1584         "PRUNE",                        /* 0x65 */
1585         "MARKPOINT",                    /* 0x66 */
1586         "SKIP",                         /* 0x67 */
1587         "COMMIT",                       /* 0x68 */
1588         "CUTGROUP",                     /* 0x69 */
1589         "KEEPS",                        /* 0x6a */
1590         "OPTIMIZED",                    /* 0x6b */
1591         "PSEUDO",                       /* 0x6c */
1592         "REGEX_SET",                    /* 0x6d */
1593         /* ------------ States ------------- */
1594         "TRIE_next",                    /* REGNODE_MAX +0x01 */
1595         "TRIE_next_fail",               /* REGNODE_MAX +0x02 */
1596         "EVAL_B",                       /* REGNODE_MAX +0x03 */
1597         "EVAL_B_fail",                  /* REGNODE_MAX +0x04 */
1598         "EVAL_postponed_AB",            /* REGNODE_MAX +0x05 */
1599         "EVAL_postponed_AB_fail",       /* REGNODE_MAX +0x06 */
1600         "CURLYX_end",                   /* REGNODE_MAX +0x07 */
1601         "CURLYX_end_fail",              /* REGNODE_MAX +0x08 */
1602         "WHILEM_A_pre",                 /* REGNODE_MAX +0x09 */
1603         "WHILEM_A_pre_fail",            /* REGNODE_MAX +0x0a */
1604         "WHILEM_A_min",                 /* REGNODE_MAX +0x0b */
1605         "WHILEM_A_min_fail",            /* REGNODE_MAX +0x0c */
1606         "WHILEM_A_max",                 /* REGNODE_MAX +0x0d */
1607         "WHILEM_A_max_fail",            /* REGNODE_MAX +0x0e */
1608         "WHILEM_B_min",                 /* REGNODE_MAX +0x0f */
1609         "WHILEM_B_min_fail",            /* REGNODE_MAX +0x10 */
1610         "WHILEM_B_max",                 /* REGNODE_MAX +0x11 */
1611         "WHILEM_B_max_fail",            /* REGNODE_MAX +0x12 */
1612         "BRANCH_next",                  /* REGNODE_MAX +0x13 */
1613         "BRANCH_next_fail",             /* REGNODE_MAX +0x14 */
1614         "CURLYM_A",                     /* REGNODE_MAX +0x15 */
1615         "CURLYM_A_fail",                /* REGNODE_MAX +0x16 */
1616         "CURLYM_B",                     /* REGNODE_MAX +0x17 */
1617         "CURLYM_B_fail",                /* REGNODE_MAX +0x18 */
1618         "IFMATCH_A",                    /* REGNODE_MAX +0x19 */
1619         "IFMATCH_A_fail",               /* REGNODE_MAX +0x1a */
1620         "CURLY_B_min",                  /* REGNODE_MAX +0x1b */
1621         "CURLY_B_min_fail",             /* REGNODE_MAX +0x1c */
1622         "CURLY_B_max",                  /* REGNODE_MAX +0x1d */
1623         "CURLY_B_max_fail",             /* REGNODE_MAX +0x1e */
1624         "COMMIT_next",                  /* REGNODE_MAX +0x1f */
1625         "COMMIT_next_fail",             /* REGNODE_MAX +0x20 */
1626         "MARKPOINT_next",               /* REGNODE_MAX +0x21 */
1627         "MARKPOINT_next_fail",          /* REGNODE_MAX +0x22 */
1628         "SKIP_next",                    /* REGNODE_MAX +0x23 */
1629         "SKIP_next_fail",               /* REGNODE_MAX +0x24 */
1630         "CUTGROUP_next",                /* REGNODE_MAX +0x25 */
1631         "CUTGROUP_next_fail",           /* REGNODE_MAX +0x26 */
1632         "KEEPS_next",                   /* REGNODE_MAX +0x27 */
1633         "KEEPS_next_fail",              /* REGNODE_MAX +0x28 */
1634 };
1635 #endif /* DOINIT */
1636
1637 /* PL_reg_extflags_name[] - Opcode/state names in string form, for debugging */
1638
1639 #ifndef DOINIT
1640 EXTCONST char * PL_reg_extflags_name[];
1641 #else
1642 EXTCONST char * const PL_reg_extflags_name[] = {
1643         /* Bits in extflags defined: 11111111111111110000111111111111 */
1644         "MULTILINE",        /* 0x00000001 */
1645         "SINGLELINE",       /* 0x00000002 */
1646         "FOLD",             /* 0x00000004 */
1647         "EXTENDED",         /* 0x00000008 */
1648         "EXTENDED_MORE",    /* 0x00000010 */
1649         "NOCAPTURE",        /* 0x00000020 */
1650         "KEEPCOPY",         /* 0x00000040 */
1651         "CHARSET0",         /* 0x00000080 : "CHARSET" - 0x00000380 */
1652         "CHARSET1",         /* 0x00000100 : "CHARSET" - 0x00000380 */
1653         "CHARSET2",         /* 0x00000200 : "CHARSET" - 0x00000380 */
1654         "STRICT",           /* 0x00000400 */
1655         "SPLIT",            /* 0x00000800 */
1656         "UNUSED_BIT_12",    /* 0x00001000 */
1657         "UNUSED_BIT_13",    /* 0x00002000 */
1658         "UNUSED_BIT_14",    /* 0x00004000 */
1659         "UNUSED_BIT_15",    /* 0x00008000 */
1660         "NO_INPLACE_SUBST", /* 0x00010000 */
1661         "EVAL_SEEN",        /* 0x00020000 */
1662         "UNBOUNDED_QUANTIFIER_SEEN",/* 0x00040000 */
1663         "CHECK_ALL",        /* 0x00080000 */
1664         "MATCH_UTF8",       /* 0x00100000 */
1665         "USE_INTUIT_NOML",  /* 0x00200000 */
1666         "USE_INTUIT_ML",    /* 0x00400000 */
1667         "INTUIT_TAIL",      /* 0x00800000 */
1668         "IS_ANCHORED",      /* 0x01000000 */
1669         "COPY_DONE",        /* 0x02000000 */
1670         "TAINTED_SEEN",     /* 0x04000000 */
1671         "TAINTED",          /* 0x08000000 */
1672         "START_ONLY",       /* 0x10000000 */
1673         "SKIPWHITE",        /* 0x20000000 */
1674         "WHITE",            /* 0x40000000 */
1675         "NULL",             /* 0x80000000 */
1676 };
1677 #endif /* DOINIT */
1678
1679 #ifdef DEBUGGING
1680 #  define REG_EXTFLAGS_NAME_SIZE 32
1681 #endif
1682
1683 /* PL_reg_intflags_name[] - Opcode/state names in string form, for debugging */
1684
1685 #ifndef DOINIT
1686 EXTCONST char * PL_reg_intflags_name[];
1687 #else
1688 EXTCONST char * const PL_reg_intflags_name[] = {
1689         "SKIP",                       /* 0x00000001 - PREGf_SKIP */
1690         "IMPLICIT",                   /* 0x00000002 - PREGf_IMPLICIT -  Converted .* to ^.*  */
1691         "NAUGHTY",                    /* 0x00000004 - PREGf_NAUGHTY -  how exponential is this pattern?  */
1692         "VERBARG_SEEN",               /* 0x00000008 - PREGf_VERBARG_SEEN */
1693         "CUTGROUP_SEEN",              /* 0x00000010 - PREGf_CUTGROUP_SEEN */
1694         "USE_RE_EVAL",                /* 0x00000020 - PREGf_USE_RE_EVAL -  compiled with "use re 'eval'"  */
1695         "NOSCAN",                     /* 0x00000040 - PREGf_NOSCAN */
1696         "GPOS_SEEN",                  /* 0x00000100 - PREGf_GPOS_SEEN */
1697         "GPOS_FLOAT",                 /* 0x00000200 - PREGf_GPOS_FLOAT */
1698         "ANCH_MBOL",                  /* 0x00000400 - PREGf_ANCH_MBOL */
1699         "ANCH_SBOL",                  /* 0x00000800 - PREGf_ANCH_SBOL */
1700         "ANCH_GPOS",                  /* 0x00001000 - PREGf_ANCH_GPOS */
1701         "RECURSE_SEEN",               /* 0x00002000 - PREGf_RECURSE_SEEN */
1702 };
1703 #endif /* DOINIT */
1704
1705 #ifdef DEBUGGING
1706 #  define REG_INTFLAGS_NAME_SIZE 13
1707 #endif
1708
1709 /* The following have no fixed length. U8 so we can do strchr() on it. */
1710 #define REGNODE_VARIES(node) (PL_varies_bitmask[(node) >> 3] & (1 << ((node) & 7)))
1711
1712 #ifndef DOINIT
1713 EXTCONST U8 PL_varies[] __attribute__deprecated__;
1714 #else
1715 EXTCONST U8 PL_varies[] __attribute__deprecated__ = {
1716     CLUMP, BRANCH, STAR, PLUS, CURLY, CURLYN, CURLYM, CURLYX, WHILEM, REF,
1717     REFF, REFFL, REFFU, REFFA, REFN, REFFN, REFFLN, REFFUN, REFFAN,
1718     BRANCHJ, SUSPEND, IFTHEN,
1719     0
1720 };
1721 #endif /* DOINIT */
1722
1723 #ifndef DOINIT
1724 EXTCONST U8 PL_varies_bitmask[];
1725 #else
1726 EXTCONST U8 PL_varies_bitmask[] = {
1727     0x00, 0x00, 0x00, 0x00, 0xC0, 0x00, 0x00, 0xE0, 0x0F, 0xFF, 0xCB, 0x00, 0x00, 0x00
1728 };
1729 #endif /* DOINIT */
1730
1731 /* The following always have a length of 1. U8 we can do strchr() on it. */
1732 /* (Note that length 1 means "one character" under UTF8, not "one octet".) */
1733 #define REGNODE_SIMPLE(node) (PL_simple_bitmask[(node) >> 3] & (1 << ((node) & 7)))
1734
1735 #ifndef DOINIT
1736 EXTCONST U8 PL_simple[] __attribute__deprecated__;
1737 #else
1738 EXTCONST U8 PL_simple[] __attribute__deprecated__ = {
1739     REG_ANY, SANY, ANYOF, ANYOFD, ANYOFL, ANYOFPOSIXL, ANYOFH, ANYOFHb,
1740     ANYOFHr, ANYOFHs, ANYOFR, ANYOFRb, ANYOFM, NANYOFM, POSIXD, POSIXL,
1741     POSIXU, POSIXA, NPOSIXD, NPOSIXL, NPOSIXU, NPOSIXA, REGEX_SET,
1742     0
1743 };
1744 #endif /* DOINIT */
1745
1746 #ifndef DOINIT
1747 EXTCONST U8 PL_simple_bitmask[];
1748 #else
1749 EXTCONST U8 PL_simple_bitmask[] = {
1750     0x00, 0x00, 0xFF, 0xFF, 0x3F, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x20
1751 };
1752 #endif /* DOINIT */
1753
1754 /* ex: set ro: */