/[pcre]/code/trunk/testdata/testoutput2
ViewVC logotype

Diff of /code/trunk/testdata/testoutput2

Parent Directory Parent Directory | Revision Log Revision Log | View Patch Patch

revision 55 by nigel, Sat Feb 24 21:39:46 2007 UTC revision 511 by ph10, Mon Mar 29 09:25:38 2010 UTC
# Line 1  Line 1 
1  PCRE version 3.6 23-Oct-2001  /-- This set of tests is not Perl-compatible. It checks on special features
2        of PCRE's API, error diagnostics, and the compiled code of some patterns.
3        It also checks the non-Perl syntax the PCRE supports (Python, .NET,
4        Oniguruma). Finally, there are some tests where PCRE and Perl differ,
5        either because PCRE can't be compatible, or there is potential Perl
6        bug. --/
7    
8    /-- Originally, the Perl 5.10 things were in here too, but now I have separated
9        many (most?) of them out into test 11. However, there may still be some
10        that were overlooked. --/
11    
12  /(a)b|/  /(a)b|/I
13  Capturing subpattern count = 1  Capturing subpattern count = 1
14  No options  No options
15  No first char  No first char
16  No need char  No need char
17    
18  /abc/  /abc/I
19  Capturing subpattern count = 0  Capturing subpattern count = 0
20  No options  No options
21  First char = 'a'  First char = 'a'
# Line 24  No match Line 33  No match
33      ABC      ABC
34  No match  No match
35    
36  /^abc/  /^abc/I
37  Capturing subpattern count = 0  Capturing subpattern count = 0
38  Options: anchored  Options: anchored
39  No first char  No first char
40  Need char = 'c'  No need char
41      abc      abc
42   0: abc   0: abc
43      \Aabc      \Aabc
# Line 40  No match Line 49  No match
49      \Adefabc      \Adefabc
50  No match  No match
51    
52  /a+bc/  /a+bc/I
53  Capturing subpattern count = 0  Capturing subpattern count = 0
54  No options  No options
55  First char = 'a'  First char = 'a'
56  Need char = 'c'  Need char = 'c'
57    
58  /a*bc/  /a*bc/I
59  Capturing subpattern count = 0  Capturing subpattern count = 0
60  No options  No options
61  No first char  No first char
62  Need char = 'c'  Need char = 'c'
63    
64  /a{3}bc/  /a{3}bc/I
65  Capturing subpattern count = 0  Capturing subpattern count = 0
66  No options  No options
67  First char = 'a'  First char = 'a'
68  Need char = 'c'  Need char = 'c'
69    
70  /(abc|a+z)/  /(abc|a+z)/I
71  Capturing subpattern count = 1  Capturing subpattern count = 1
72  No options  No options
73  First char = 'a'  First char = 'a'
74  No need char  No need char
75    
76  /^abc$/  /^abc$/I
77  Capturing subpattern count = 0  Capturing subpattern count = 0
78  Options: anchored  Options: anchored
79  No first char  No first char
80  Need char = 'c'  No need char
81      abc      abc
82   0: abc   0: abc
83      *** Failers      *** Failers
# Line 76  No match Line 85  No match
85      def\nabc      def\nabc
86  No match  No match
87    
88  /ab\gdef/X  /ab\idef/X
89  Failed: unrecognized character follows \ at offset 3  Failed: unrecognized character follows \ at offset 3
90    
91  /(?X)ab\gdef/X  /(?X)ab\idef/X
92  Failed: unrecognized character follows \ at offset 7  Failed: unrecognized character follows \ at offset 7
93    
94  /x{5,4}/  /x{5,4}/
# Line 91  Failed: number too big in {} quantifier Line 100  Failed: number too big in {} quantifier
100  /[abcd/  /[abcd/
101  Failed: missing terminating ] for character class at offset 5  Failed: missing terminating ] for character class at offset 5
102    
103  /[\B]/  /(?X)[\B]/
104  Failed: invalid escape sequence in character class at offset 2  Failed: invalid escape sequence in character class at offset 6
105    
106  /[z-a]/  /[z-a]/
107  Failed: range out of order in character class at offset 3  Failed: range out of order in character class at offset 3
# Line 107  Failed: missing ) at offset 4 Line 116  Failed: missing ) at offset 4
116  Failed: missing ) after comment at offset 7  Failed: missing ) after comment at offset 7
117    
118  /(?z)abc/  /(?z)abc/
119  Failed: unrecognized character after (? at offset 2  Failed: unrecognized character after (? or (?- at offset 2
120    
121  /.*b/  /.*b/I
122  Capturing subpattern count = 0  Capturing subpattern count = 0
123  No options  No options
124  First char at start or follows \n  First char at start or follows newline
125  Need char = 'b'  Need char = 'b'
126    
127  /.*?b/  /.*?b/I
128  Capturing subpattern count = 0  Capturing subpattern count = 0
129  No options  No options
130  First char at start or follows \n  First char at start or follows newline
131  Need char = 'b'  Need char = 'b'
132    
133  /cat|dog|elephant/  /cat|dog|elephant/I
134  Capturing subpattern count = 0  Capturing subpattern count = 0
135  No options  No options
136  No first char  No first char
# Line 131  No need char Line 140  No need char
140      this sentences rambles on and on for a while and then reaches elephant      this sentences rambles on and on for a while and then reaches elephant
141   0: elephant   0: elephant
142    
143  /cat|dog|elephant/S  /cat|dog|elephant/IS
144  Capturing subpattern count = 0  Capturing subpattern count = 0
145  No options  No options
146  No first char  No first char
147  No need char  No need char
148  Starting character set: c d e  Subject length lower bound = 3
149    Starting byte set: c d e
150      this sentence eventually mentions a cat      this sentence eventually mentions a cat
151   0: cat   0: cat
152      this sentences rambles on and on for a while and then reaches elephant      this sentences rambles on and on for a while and then reaches elephant
153   0: elephant   0: elephant
154    
155  /cat|dog|elephant/iS  /cat|dog|elephant/IiS
156  Capturing subpattern count = 0  Capturing subpattern count = 0
157  Options: caseless  Options: caseless
158  No first char  No first char
159  No need char  No need char
160  Starting character set: C D E c d e  Subject length lower bound = 3
161    Starting byte set: C D E c d e
162      this sentence eventually mentions a CAT cat      this sentence eventually mentions a CAT cat
163   0: CAT   0: CAT
164      this sentences rambles on and on for a while to elephant ElePhant      this sentences rambles on and on for a while to elephant ElePhant
165   0: elephant   0: elephant
166    
167  /a|[bcd]/S  /a|[bcd]/IS
168  Capturing subpattern count = 0  Capturing subpattern count = 0
169  No options  No options
170  No first char  No first char
171  No need char  No need char
172  Starting character set: a b c d  Subject length lower bound = 1
173    Starting byte set: a b c d
174    
175  /(a|[^\dZ])/S  /(a|[^\dZ])/IS
176  Capturing subpattern count = 1  Capturing subpattern count = 1
177  No options  No options
178  No first char  No first char
179  No need char  No need char
180  Starting character set: \x00 \x01 \x02 \x03 \x04 \x05 \x06 \x07 \x08 \x09 \x0a  Subject length lower bound = 1
181    Starting byte set: \x00 \x01 \x02 \x03 \x04 \x05 \x06 \x07 \x08 \x09 \x0a
182    \x0b \x0c \x0d \x0e \x0f \x10 \x11 \x12 \x13 \x14 \x15 \x16 \x17 \x18 \x19    \x0b \x0c \x0d \x0e \x0f \x10 \x11 \x12 \x13 \x14 \x15 \x16 \x17 \x18 \x19
183    \x1a \x1b \x1c \x1d \x1e \x1f \x20 ! " # $ % & ' ( ) * + , - . / : ; < = >    \x1a \x1b \x1c \x1d \x1e \x1f \x20 ! " # $ % & ' ( ) * + , - . / : ; < = >
184    ? @ A B C D E F G H I J K L M N O P Q R S T U V W X Y [ \ ] ^ _ ` a b c d    ? @ A B C D E F G H I J K L M N O P Q R S T U V W X Y [ \ ] ^ _ ` a b c d
# Line 180  Starting character set: \x00 \x01 \x02 \ Line 193  Starting character set: \x00 \x01 \x02 \
193    \xed \xee \xef \xf0 \xf1 \xf2 \xf3 \xf4 \xf5 \xf6 \xf7 \xf8 \xf9 \xfa \xfb    \xed \xee \xef \xf0 \xf1 \xf2 \xf3 \xf4 \xf5 \xf6 \xf7 \xf8 \xf9 \xfa \xfb
194    \xfc \xfd \xfe \xff    \xfc \xfd \xfe \xff
195    
196  /(a|b)*[\s]/S  /(a|b)*[\s]/IS
197  Capturing subpattern count = 1  Capturing subpattern count = 1
198  No options  No options
199  No first char  No first char
200  No need char  No need char
201  Starting character set: \x09 \x0a \x0b \x0c \x0d \x20 a b  Subject length lower bound = 1
202    Starting byte set: \x09 \x0a \x0c \x0d \x20 a b
203    
204  /(ab\2)/  /(ab\2)/
205  Failed: back reference to non-existent subpattern at offset 6  Failed: reference to non-existent subpattern at offset 6
206    
207  /{4,5}abc/  /{4,5}abc/
208  Failed: nothing to repeat at offset 4  Failed: nothing to repeat at offset 4
209    
210  /(a)(b)(c)\2/  /(a)(b)(c)\2/I
211  Capturing subpattern count = 3  Capturing subpattern count = 3
212  Max back reference = 2  Max back reference = 2
213  No options  No options
# Line 218  Matched, but too many substrings Line 232  Matched, but too many substrings
232   0: abcb   0: abcb
233   1: a   1: a
234   2: b   2: b
235      \O12abcb      \O12abcb
236   0: abcb   0: abcb
237   1: a   1: a
238   2: b   2: b
239   3: c   3: c
240    
241  /(a)bc|(a)(b)\2/  /(a)bc|(a)(b)\2/I
242  Capturing subpattern count = 3  Capturing subpattern count = 3
243  Max back reference = 2  Max back reference = 2
244  No options  No options
# Line 266  Matched, but too many substrings Line 280  Matched, but too many substrings
280   2: a   2: a
281   3: b   3: b
282    
283  /abc$/E  /abc$/IE
284  Capturing subpattern count = 0  Capturing subpattern count = 0
285  Options: dollar_endonly  Options: dollar_endonly
286  First char = 'a'  First char = 'a'
# Line 281  No match Line 295  No match
295  No match  No match
296    
297  /(a)(b)(c)(d)(e)\6/  /(a)(b)(c)(d)(e)\6/
298  Failed: back reference to non-existent subpattern at offset 17  Failed: reference to non-existent subpattern at offset 17
299    
300  /the quick brown fox/  /the quick brown fox/I
301  Capturing subpattern count = 0  Capturing subpattern count = 0
302  No options  No options
303  First char = 't'  First char = 't'
# Line 293  Need char = 'x' Line 307  Need char = 'x'
307      this is a line with the quick brown fox      this is a line with the quick brown fox
308   0: the quick brown fox   0: the quick brown fox
309    
310  /the quick brown fox/A  /the quick brown fox/IA
311  Capturing subpattern count = 0  Capturing subpattern count = 0
312  Options: anchored  Options: anchored
313  No first char  No first char
314  Need char = 'x'  No need char
315      the quick brown fox      the quick brown fox
316   0: the quick brown fox   0: the quick brown fox
317      *** Failers      *** Failers
# Line 306  No match Line 320  No match
320  No match  No match
321    
322  /ab(?z)cd/  /ab(?z)cd/
323  Failed: unrecognized character after (? at offset 4  Failed: unrecognized character after (? or (?- at offset 4
324    
325  /^abc|def/  /^abc|def/I
326  Capturing subpattern count = 0  Capturing subpattern count = 0
327  No options  No options
328  No first char  No first char
# Line 318  No need char Line 332  No need char
332      abcdef\B      abcdef\B
333   0: def   0: def
334    
335  /.*((abc)$|(def))/  /.*((abc)$|(def))/I
336  Capturing subpattern count = 3  Capturing subpattern count = 3
337  No options  No options
338  First char at start or follows \n  First char at start or follows newline
339  No need char  No need char
340      defabc      defabc
341   0: defabc   0: defabc
# Line 338  No need char Line 352  No need char
352   0: abc   0: abc
353      *** Failers      *** Failers
354  No match: POSIX code 17: match failed  No match: POSIX code 17: match failed
355    
356  /^abc|def/P  /^abc|def/P
357      abcdef      abcdef
358   0: abc   0: abc
# Line 354  No match: POSIX code 17: match failed Line 368  No match: POSIX code 17: match failed
368   0: def   0: def
369   1: def   1: def
370   3: def   3: def
371    
372  /the quick brown fox/P  /the quick brown fox/P
373      the quick brown fox      the quick brown fox
374   0: the quick brown fox   0: the quick brown fox
375      *** Failers      *** Failers
376  No match: POSIX code 17: match failed  No match: POSIX code 17: match failed
377      The Quick Brown Fox      The Quick Brown Fox
378  No match: POSIX code 17: match failed  No match: POSIX code 17: match failed
379    
380  /the quick brown fox/Pi  /the quick brown fox/Pi
381      the quick brown fox      the quick brown fox
382   0: the quick brown fox   0: the quick brown fox
383      The Quick Brown Fox      The Quick Brown Fox
384   0: The Quick Brown Fox   0: The Quick Brown Fox
385    
386  /abc.def/P  /abc.def/P
# Line 374  No match: POSIX code 17: match failed Line 388  No match: POSIX code 17: match failed
388  No match: POSIX code 17: match failed  No match: POSIX code 17: match failed
389      abc\ndef      abc\ndef
390  No match: POSIX code 17: match failed  No match: POSIX code 17: match failed
391    
392  /abc$/P  /abc$/P
393      abc      abc
394   0: abc   0: abc
395      abc\n      abc\n
396   0: abc   0: abc
397    
398  /(abc)\2/P  /(abc)\2/P
# Line 394  Failed: unmatched parentheses at offset Line 408  Failed: unmatched parentheses at offset
408  /a[]b/  /a[]b/
409  Failed: missing terminating ] for character class at offset 4  Failed: missing terminating ] for character class at offset 4
410    
411  /[^aeiou ]{3,}/  /[^aeiou ]{3,}/I
412  Capturing subpattern count = 0  Capturing subpattern count = 0
413  No options  No options
414  No first char  No first char
415  No need char  No need char
416      co-processors, and for      co-processors, and for
417   0: -pr   0: -pr
418    
419  /<.*>/  /<.*>/I
420  Capturing subpattern count = 0  Capturing subpattern count = 0
421  No options  No options
422  First char = '<'  First char = '<'
# Line 410  Need char = '>' Line 424  Need char = '>'
424      abc<def>ghi<klm>nop      abc<def>ghi<klm>nop
425   0: <def>ghi<klm>   0: <def>ghi<klm>
426    
427  /<.*?>/  /<.*?>/I
428  Capturing subpattern count = 0  Capturing subpattern count = 0
429  No options  No options
430  First char = '<'  First char = '<'
# Line 418  Need char = '>' Line 432  Need char = '>'
432      abc<def>ghi<klm>nop      abc<def>ghi<klm>nop
433   0: <def>   0: <def>
434    
435  /<.*>/U  /<.*>/IU
436  Capturing subpattern count = 0  Capturing subpattern count = 0
437  Options: ungreedy  Options: ungreedy
438  First char = '<'  First char = '<'
439  Need char = '>'  Need char = '>'
440      abc<def>ghi<klm>nop      abc<def>ghi<klm>nop
441   0: <def>   0: <def>
442    
443  /<.*>(?U)/  /(?U)<.*>/I
444  Capturing subpattern count = 0  Capturing subpattern count = 0
445  Options: ungreedy  Options: ungreedy
446  First char = '<'  First char = '<'
# Line 434  Need char = '>' Line 448  Need char = '>'
448      abc<def>ghi<klm>nop      abc<def>ghi<klm>nop
449   0: <def>   0: <def>
450    
451  /<.*?>/U  /<.*?>/IU
452  Capturing subpattern count = 0  Capturing subpattern count = 0
453  Options: ungreedy  Options: ungreedy
454  First char = '<'  First char = '<'
455  Need char = '>'  Need char = '>'
456      abc<def>ghi<klm>nop      abc<def>ghi<klm>nop
457   0: <def>ghi<klm>   0: <def>ghi<klm>
458    
459  /={3,}/U  /={3,}/IU
460  Capturing subpattern count = 0  Capturing subpattern count = 0
461  Options: ungreedy  Options: ungreedy
462  First char = '='  First char = '='
463  Need char = '='  Need char = '='
464      abc========def      abc========def
465   0: ===   0: ===
466    
467  /(?U)={3,}?/  /(?U)={3,}?/I
468  Capturing subpattern count = 0  Capturing subpattern count = 0
469  Options: ungreedy  Options: ungreedy
470  First char = '='  First char = '='
471  Need char = '='  Need char = '='
472      abc========def      abc========def
473   0: ========   0: ========
474    
475  /(?<!bar|cattle)foo/  /(?<!bar|cattle)foo/I
476  Capturing subpattern count = 0  Capturing subpattern count = 0
477  No options  No options
478  First char = 'f'  First char = 'f'
479  Need char = 'o'  Need char = 'o'
480      foo      foo
481   0: foo   0: foo
482      catfoo      catfoo
483   0: foo   0: foo
484      *** Failers      *** Failers
485  No match  No match
486      the barfoo      the barfoo
487  No match  No match
488      and cattlefoo      and cattlefoo
489  No match  No match
490    
491  /(?<=a+)b/  /(?<=a+)b/
# Line 483  Failed: lookbehind assertion is not fixe Line 497  Failed: lookbehind assertion is not fixe
497  /(?<!(foo)a\1)bar/  /(?<!(foo)a\1)bar/
498  Failed: lookbehind assertion is not fixed length at offset 12  Failed: lookbehind assertion is not fixed length at offset 12
499    
500  /(?i)abc/  /(?i)abc/I
501  Capturing subpattern count = 0  Capturing subpattern count = 0
502  Options: caseless  Options: caseless
503  First char = 'a'  First char = 'a' (caseless)
504  Need char = 'c'  Need char = 'c' (caseless)
505    
506  /(a|(?m)a)/  /(a|(?m)a)/I
507  Capturing subpattern count = 1  Capturing subpattern count = 1
508  No options  No options
509  First char = 'a'  First char = 'a'
510  No need char  No need char
511    
512  /(?i)^1234/  /(?i)^1234/I
513  Capturing subpattern count = 0  Capturing subpattern count = 0
514  Options: anchored caseless  Options: anchored caseless
515  No first char  No first char
516  Need char = '4'  No need char
517    
518  /(^b|(?i)^d)/  /(^b|(?i)^d)/I
519  Capturing subpattern count = 1  Capturing subpattern count = 1
520  Options: anchored  Options: anchored
 Case state changes  
521  No first char  No first char
522  No need char  No need char
523    
524  /(?s).*/  /(?s).*/I
525  Capturing subpattern count = 0  Capturing subpattern count = 0
526  Options: anchored dotall  Options: anchored dotall
527  No first char  No first char
528  No need char  No need char
529    
530  /[abcd]/S  /[abcd]/IS
531  Capturing subpattern count = 0  Capturing subpattern count = 0
532  No options  No options
533  No first char  No first char
534  No need char  No need char
535  Starting character set: a b c d  Subject length lower bound = 1
536    Starting byte set: a b c d
537    
538  /(?i)[abcd]/S  /(?i)[abcd]/IS
539  Capturing subpattern count = 0  Capturing subpattern count = 0
540  Options: caseless  Options: caseless
541  No first char  No first char
542  No need char  No need char
543  Starting character set: A B C D a b c d  Subject length lower bound = 1
544    Starting byte set: A B C D a b c d
545    
546  /(?m)[xy]|(b|c)/S  /(?m)[xy]|(b|c)/IS
547  Capturing subpattern count = 1  Capturing subpattern count = 1
548  Options: multiline  Options: multiline
549  No first char  No first char
550  No need char  No need char
551  Starting character set: b c x y  Subject length lower bound = 1
552    Starting byte set: b c x y
553    
554  /(^a|^b)/m  /(^a|^b)/Im
555  Capturing subpattern count = 1  Capturing subpattern count = 1
556  Options: multiline  Options: multiline
557  First char at start or follows \n  First char at start or follows newline
558  No need char  No need char
559    
560  /(?i)(^a|^b)/m  /(?i)(^a|^b)/Im
561  Capturing subpattern count = 1  Capturing subpattern count = 1
562  Options: caseless multiline  Options: caseless multiline
563  First char at start or follows \n  First char at start or follows newline
564  No need char  No need char
565    
566  /(a)(?(1)a|b|c)/  /(a)(?(1)a|b|c)/
# Line 554  Failed: conditional group contains more Line 570  Failed: conditional group contains more
570  Failed: conditional group contains more than two branches at offset 12  Failed: conditional group contains more than two branches at offset 12
571    
572  /(?(1a)/  /(?(1a)/
573  Failed: malformed number after (?( at offset 4  Failed: missing ) at offset 6
574    
575    /(?(1a))/
576    Failed: reference to non-existent subpattern at offset 6
577    
578  /(?(?i))/  /(?(?i))/
579  Failed: assertion expected after (?( at offset 3  Failed: assertion expected after (?( at offset 3
580    
581  /(?(abc))/  /(?(abc))/
582  Failed: assertion expected after (?( at offset 3  Failed: reference to non-existent subpattern at offset 7
583    
584  /(?(?<ab))/  /(?(?<ab))/
585  Failed: unrecognized character after (?< at offset 2  Failed: syntax error in subpattern name (missing terminator) at offset 7
586    
587  /((?s)blah)\s+\1/  /((?s)blah)\s+\1/I
588  Capturing subpattern count = 1  Capturing subpattern count = 1
589  Max back reference = 1  Max back reference = 1
590  No options  No options
591  First char = 'b'  First char = 'b'
592  Need char = 'h'  Need char = 'h'
593    
594  /((?i)blah)\s+\1/  /((?i)blah)\s+\1/I
595  Capturing subpattern count = 1  Capturing subpattern count = 1
596  Max back reference = 1  Max back reference = 1
597  No options  No options
598  Case state changes  First char = 'b' (caseless)
599  No first char  Need char = 'h' (caseless)
 Need char = 'h'  
600    
601  /((?i)b)/DS  /((?i)b)/IDZS
602  ------------------------------------------------------------------  ------------------------------------------------------------------
603    0  16 Bra 0          Bra
604    3   8 Bra 1          CBra 1
605    6  01 Opt       01 Opt
606    8   1 b       NC b
607   11   8 Ket          Ket
608   14  00 Opt       00 Opt
609   16  16 Ket          Ket
610   19     End          End
611  ------------------------------------------------------------------  ------------------------------------------------------------------
612  Capturing subpattern count = 1  Capturing subpattern count = 1
613  No options  No options
614  Case state changes  First char = 'b' (caseless)
615  No first char  No need char
616  Need char = 'b'  Subject length lower bound = 1
617  Starting character set: B b  No set of starting bytes
618    
619  /(a*b|(?i:c*(?-i)d))/S  /(a*b|(?i:c*(?-i)d))/IS
620  Capturing subpattern count = 1  Capturing subpattern count = 1
621  No options  No options
 Case state changes  
622  No first char  No first char
623  No need char  No need char
624  Starting character set: C a b c d  Subject length lower bound = 1
625    Starting byte set: C a b c d
626    
627  /a$/  /a$/I
628  Capturing subpattern count = 0  Capturing subpattern count = 0
629  No options  No options
630  First char = 'a'  First char = 'a'
# Line 615  No need char Line 633  No need char
633   0: a   0: a
634      a\n      a\n
635   0: a   0: a
636      *** Failers      *** Failers
637  No match  No match
638      \Za      \Za
639  No match  No match
640      \Za\n      \Za\n
641  No match  No match
642    
643  /a$/m  /a$/Im
644  Capturing subpattern count = 0  Capturing subpattern count = 0
645  Options: multiline  Options: multiline
646  First char = 'a'  First char = 'a'
# Line 631  No need char Line 649  No need char
649   0: a   0: a
650      a\n      a\n
651   0: a   0: a
652      \Za\n      \Za\n
653   0: a   0: a
654      *** Failers      *** Failers
655  No match  No match
656      \Za      \Za
657  No match  No match
658    
659  /\Aabc/m  /\Aabc/Im
660  Capturing subpattern count = 0  Capturing subpattern count = 0
661  Options: anchored multiline  Options: anchored multiline
662  No first char  No first char
663  Need char = 'c'  No need char
664    
665  /^abc/m  /^abc/Im
666  Capturing subpattern count = 0  Capturing subpattern count = 0
667  Options: multiline  Options: multiline
668  First char at start or follows \n  First char at start or follows newline
669  Need char = 'c'  Need char = 'c'
670    
671  /^((a+)(?U)([ab]+)(?-U)([bc]+)(\w*))/  /^((a+)(?U)([ab]+)(?-U)([bc]+)(\w*))/I
672  Capturing subpattern count = 5  Capturing subpattern count = 5
673  Options: anchored  Options: anchored
674  No first char  No first char
675  Need char = 'a'  No need char
676    aaaaabbbbbcccccdef    aaaaabbbbbcccccdef
677   0: aaaaabbbbbcccccdef   0: aaaaabbbbbcccccdef
678   1: aaaaabbbbbcccccdef   1: aaaaabbbbbcccccdef
# Line 663  Need char = 'a' Line 681  Need char = 'a'
681   4: bbbbccccc   4: bbbbccccc
682   5: def   5: def
683    
684  /(?<=foo)[ab]/S  /(?<=foo)[ab]/IS
685  Capturing subpattern count = 0  Capturing subpattern count = 0
686  No options  No options
687  No first char  No first char
688  No need char  No need char
689  Starting character set: a b  Subject length lower bound = 1
690    Starting byte set: a b
691    
692  /(?<!foo)(alpha|omega)/S  /(?<!foo)(alpha|omega)/IS
693  Capturing subpattern count = 1  Capturing subpattern count = 1
694  No options  No options
695  No first char  No first char
696  Need char = 'a'  Need char = 'a'
697  Starting character set: a o  Subject length lower bound = 5
698    Starting byte set: a o
699    
700  /(?!alphabet)[ab]/S  /(?!alphabet)[ab]/IS
701  Capturing subpattern count = 0  Capturing subpattern count = 0
702  No options  No options
703  No first char  No first char
704  No need char  No need char
705  Starting character set: a b  Subject length lower bound = 1
706    Starting byte set: a b
707    
708    /(?<=foo\n)^bar/Im
709    Capturing subpattern count = 0
710    Contains explicit CR or LF match
711    Options: multiline
712    No first char
713    Need char = 'r'
714        foo\nbarbar
715     0: bar
716        ***Failers
717    No match
718        rhubarb
719    No match
720        barbell
721    No match
722        abc\nbarton
723    No match
724    
725  /(?<=foo\n)^bar/m  /^(?<=foo\n)bar/Im
726  Capturing subpattern count = 0  Capturing subpattern count = 0
727    Contains explicit CR or LF match
728  Options: multiline  Options: multiline
729  First char at start or follows \n  First char at start or follows newline
730  Need char = 'r'  Need char = 'r'
731        foo\nbarbar
732     0: bar
733        ***Failers
734    No match
735        rhubarb
736    No match
737        barbell
738    No match
739        abc\nbarton
740    No match
741    
742  /(?>^abc)/m  /(?>^abc)/Im
743  Capturing subpattern count = 0  Capturing subpattern count = 0
744  Options: multiline  Options: multiline
745  First char at start or follows \n  First char at start or follows newline
746  Need char = 'c'  Need char = 'c'
747      abc      abc
748   0: abc   0: abc
# Line 701  Need char = 'c' Line 750  Need char = 'c'
750   0: abc   0: abc
751      *** Failers      *** Failers
752  No match  No match
753      defabc      defabc
754  No match  No match
755    
756  /(?<=ab(c+)d)ef/  /(?<=ab(c+)d)ef/
# Line 714  Failed: lookbehind assertion is not fixe Line 763  Failed: lookbehind assertion is not fixe
763  Failed: lookbehind assertion is not fixed length at offset 13  Failed: lookbehind assertion is not fixed length at offset 13
764    
765  /The next three are in testinput2 because they have variable length branches/  /The next three are in testinput2 because they have variable length branches/
 Capturing subpattern count = 0  
 No options  
 First char = 'T'  
 Need char = 's'  
766    
767  /(?<=bullock|donkey)-cart/  /(?<=bullock|donkey)-cart/I
768  Capturing subpattern count = 0  Capturing subpattern count = 0
769  No options  No options
770  First char = '-'  First char = '-'
# Line 732  Need char = 't' Line 777  Need char = 't'
777  No match  No match
778      cart      cart
779  No match  No match
780      horse-and-cart      horse-and-cart
781  No match  No match
782    
783  /(?<=ab(?i)x|y|z)/  /(?<=ab(?i)x|y|z)/I
784  Capturing subpattern count = 0  Capturing subpattern count = 0
785  No options  No options
 Case state changes  
786  No first char  No first char
787  No need char  No need char
788    
789  /(?>.*)(?<=(abcd)|(xyz))/  /(?>.*)(?<=(abcd)|(xyz))/I
790  Capturing subpattern count = 2  Capturing subpattern count = 2
791  No options  No options
792  First char at start or follows \n  First char at start or follows newline
793  No need char  No need char
794      alphabetabcd      alphabetabcd
795   0: alphabetabcd   0: alphabetabcd
# Line 755  No need char Line 799  No need char
799   1: <unset>   1: <unset>
800   2: xyz   2: xyz
801    
802  /(?<=ab(?i)x(?-i)y|(?i)z|b)ZZ/  /(?<=ab(?i)x(?-i)y|(?i)z|b)ZZ/I
803  Capturing subpattern count = 0  Capturing subpattern count = 0
804  No options  No options
 Case state changes  
805  First char = 'Z'  First char = 'Z'
806  Need char = 'Z'  Need char = 'Z'
807      abxyZZ      abxyZZ
# Line 771  Need char = 'Z' Line 814  Need char = 'Z'
814   0: ZZ   0: ZZ
815      bZZ      bZZ
816   0: ZZ   0: ZZ
817      BZZ      BZZ
818   0: ZZ   0: ZZ
819      *** Failers      *** Failers
820  No match  No match
821      ZZ      ZZ
822  No match  No match
823      abXYZZ      abXYZZ
824  No match  No match
825      zzz      zzz
826  No match  No match
827      bzz      bzz
828  No match  No match
829    
830  /(?<!(foo)a)bar/  /(?<!(foo)a)bar/I
831  Capturing subpattern count = 1  Capturing subpattern count = 1
832  No options  No options
833  First char = 'b'  First char = 'b'
834  Need char = 'r'  Need char = 'r'
835      bar      bar
836   0: bar   0: bar
837      foobbar      foobbar
838   0: bar   0: bar
839      *** Failers      *** Failers
840  No match  No match
841      fooabar      fooabar
842  No match  No match
843    
844  /This one is here because Perl 5.005_02 doesn't fail it/  /This one is here because Perl 5.005_02 doesn't fail it/I
845  Capturing subpattern count = 0  Capturing subpattern count = 0
846  No options  No options
847  First char = 'T'  First char = 'T'
848  Need char = 't'  Need char = 't'
849    
850  /^(a)?(?(1)a|b)+$/  /^(a)?(?(1)a|b)+$/I
851  Capturing subpattern count = 1  Capturing subpattern count = 1
852  Options: anchored  Options: anchored
853  No first char  No first char
854  No need char  No need char
855      *** Failers      *** Failers
856  No match  No match
857      a      a
858  No match  No match
859    
860  /This one is here because I think Perl 5.005_02 gets the setting of $1 wrong/  /This one is here because Perl behaves differently; see also the following/I
861  Capturing subpattern count = 0  Capturing subpattern count = 0
862  No options  No options
863  First char = 'T'  First char = 'T'
864  Need char = 'g'  Need char = 'g'
865    
866  /^(a\1?){4}$/  /^(a\1?){4}$/I
867  Capturing subpattern count = 1  Capturing subpattern count = 1
868  Max back reference = 1  Max back reference = 1
869  Options: anchored  Options: anchored
870  No first char  No first char
871  Need char = 'a'  No need char
872        aaaa
873    No match
874      aaaaaa      aaaaaa
875   0: aaaaaa  No match
  1: aa  
876    
877  /These are syntax tests from Perl 5.005/  /Perl does not fail these two for the final subjects. Neither did PCRE until/
878    /release 8.01. The problem is in backtracking into a subpattern that contains/
879    No match
880    /a recursive reference to itself. PCRE has now made these into atomic patterns./
881    No match
882    
883    /^(xa|=?\1a){2}$/
884        xa=xaa
885     0: xa=xaa
886     1: =xaa
887        ** Failers
888    No match
889        xa=xaaa
890    No match
891    
892    /^(xa|=?\1a)+$/
893        xa=xaa
894     0: xa=xaa
895     1: =xaa
896        ** Failers
897    No match
898        xa=xaaa
899    No match
900    
901    /These are syntax tests from Perl 5.005/I
902  Capturing subpattern count = 0  Capturing subpattern count = 0
903  No options  No options
904  First char = 'T'  First char = 'T'
# Line 864  Failed: nothing to repeat at offset 2 Line 932  Failed: nothing to repeat at offset 2
932  Failed: unmatched parentheses at offset 0  Failed: unmatched parentheses at offset 0
933    
934  /\1/  /\1/
935  Failed: back reference to non-existent subpattern at offset 2  Failed: reference to non-existent subpattern at offset 2
936    
937  /\2/  /\2/
938  Failed: back reference to non-existent subpattern at offset 2  Failed: reference to non-existent subpattern at offset 2
939    
940  /(a)|\2/  /(a)|\2/
941  Failed: back reference to non-existent subpattern at offset 6  Failed: reference to non-existent subpattern at offset 6
942    
943  /a[b-a]/i  /a[b-a]/Ii
944  Failed: range out of order in character class at offset 4  Failed: range out of order in character class at offset 4
945    
946  /a[]b/i  /a[]b/Ii
947  Failed: missing terminating ] for character class at offset 4  Failed: missing terminating ] for character class at offset 4
948    
949  /a[/i  /a[/Ii
950  Failed: missing terminating ] for character class at offset 2  Failed: missing terminating ] for character class at offset 2
951    
952  /*a/i  /*a/Ii
953  Failed: nothing to repeat at offset 0  Failed: nothing to repeat at offset 0
954    
955  /(*)b/i  /(*)b/Ii
956  Failed: nothing to repeat at offset 1  Failed: nothing to repeat at offset 1
957    
958  /abc)/i  /abc)/Ii
959  Failed: unmatched parentheses at offset 3  Failed: unmatched parentheses at offset 3
960    
961  /(abc/i  /(abc/Ii
962  Failed: missing ) at offset 4  Failed: missing ) at offset 4
963    
964  /a**/i  /a**/Ii
965  Failed: nothing to repeat at offset 2  Failed: nothing to repeat at offset 2
966    
967  /)(/i  /)(/Ii
968  Failed: unmatched parentheses at offset 0  Failed: unmatched parentheses at offset 0
969    
970  /:(?:/  /:(?:/
971  Failed: missing ) at offset 4  Failed: missing ) at offset 4
972    
973  /(?<%)b/  /(?<%)b/
974  Failed: unrecognized character after (?< at offset 0  Failed: unrecognized character after (?< at offset 3
975    
976  /a(?{)b/  /a(?{)b/
977  Failed: unrecognized character after (? at offset 3  Failed: unrecognized character after (? or (?- at offset 3
978    
979  /a(?{{})b/  /a(?{{})b/
980  Failed: unrecognized character after (? at offset 3  Failed: unrecognized character after (? or (?- at offset 3
981    
982  /a(?{}})b/  /a(?{}})b/
983  Failed: unrecognized character after (? at offset 3  Failed: unrecognized character after (? or (?- at offset 3
984    
985  /a(?{"{"})b/  /a(?{"{"})b/
986  Failed: unrecognized character after (? at offset 3  Failed: unrecognized character after (? or (?- at offset 3
987    
988  /a(?{"{"}})b/  /a(?{"{"}})b/
989  Failed: unrecognized character after (? at offset 3  Failed: unrecognized character after (? or (?- at offset 3
990    
991  /(?(1?)a|b)/  /(?(1?)a|b)/
992  Failed: malformed number after (?( at offset 4  Failed: malformed number or name after (?( at offset 4
   
 /(?(1)a|b|c)/  
 Failed: conditional group contains more than two branches at offset 10  
993    
994  /[a[:xyz:/  /[a[:xyz:/
995  Failed: missing terminating ] for character class at offset 8  Failed: missing terminating ] for character class at offset 8
# Line 944  Failed: POSIX code 9: bad escape sequenc Line 1009  Failed: POSIX code 9: bad escape sequenc
1009  /abc/\i  /abc/\i
1010  Failed: \ at end of pattern at offset 4  Failed: \ at end of pattern at offset 4
1011    
1012  /(a)bc(d)/  /(a)bc(d)/I
1013  Capturing subpattern count = 2  Capturing subpattern count = 2
1014  No options  No options
1015  First char = 'a'  First char = 'a'
# Line 963  Need char = 'd' Line 1028  Need char = 'd'
1028   1: a   1: a
1029   2: d   2: d
1030  copy substring 5 failed -7  copy substring 5 failed -7
1031    
1032  /(.{20})/  /(.{20})/I
1033  Capturing subpattern count = 1  Capturing subpattern count = 1
1034  No options  No options
1035  No first char  No first char
# Line 975  No need char Line 1040  No need char
1040      abcdefghijklmnopqrstuvwxyz\C1      abcdefghijklmnopqrstuvwxyz\C1
1041   0: abcdefghijklmnopqrst   0: abcdefghijklmnopqrst
1042   1: abcdefghijklmnopqrst   1: abcdefghijklmnopqrst
1043  copy substring 1 failed -6   1C abcdefghijklmnopqrst (20)
1044      abcdefghijklmnopqrstuvwxyz\G1      abcdefghijklmnopqrstuvwxyz\G1
1045   0: abcdefghijklmnopqrst   0: abcdefghijklmnopqrst
1046   1: abcdefghijklmnopqrst   1: abcdefghijklmnopqrst
1047   1G abcdefghijklmnopqrst (20)   1G abcdefghijklmnopqrst (20)
1048    
1049  /(.{15})/  /(.{15})/I
1050  Capturing subpattern count = 1  Capturing subpattern count = 1
1051  No options  No options
1052  No first char  No first char
# Line 995  No need char Line 1060  No need char
1060   1C abcdefghijklmno (15)   1C abcdefghijklmno (15)
1061   1G abcdefghijklmno (15)   1G abcdefghijklmno (15)
1062    
1063  /(.{16})/  /(.{16})/I
1064  Capturing subpattern count = 1  Capturing subpattern count = 1
1065  No options  No options
1066  No first char  No first char
# Line 1006  No need char Line 1071  No need char
1071      abcdefghijklmnopqrstuvwxyz\C1\G1\L      abcdefghijklmnopqrstuvwxyz\C1\G1\L
1072   0: abcdefghijklmnop   0: abcdefghijklmnop
1073   1: abcdefghijklmnop   1: abcdefghijklmnop
1074  copy substring 1 failed -6   1C abcdefghijklmnop (16)
1075   1G abcdefghijklmnop (16)   1G abcdefghijklmnop (16)
1076   0L abcdefghijklmnop   0L abcdefghijklmnop
1077   1L abcdefghijklmnop   1L abcdefghijklmnop
1078    
1079  /^(a|(bc))de(f)/  /^(a|(bc))de(f)/I
1080  Capturing subpattern count = 3  Capturing subpattern count = 3
1081  Options: anchored  Options: anchored
1082  No first char  No first char
1083  Need char = 'f'  No need char
1084      adef\G1\G2\G3\G4\L      adef\G1\G2\G3\G4\L
1085   0: adef   0: adef
1086   1: a   1: a
1087   2: <unset>   2: <unset>
# Line 1029  get substring 4 failed -7 Line 1094  get substring 4 failed -7
1094   1L a   1L a
1095   2L   2L
1096   3L f   3L f
1097      bcdef\G1\G2\G3\G4\L      bcdef\G1\G2\G3\G4\L
1098   0: bcdef   0: bcdef
1099   1: bc   1: bc
1100   2: bc   2: bc
# Line 1042  get substring 4 failed -7 Line 1107  get substring 4 failed -7
1107   1L bc   1L bc
1108   2L bc   2L bc
1109   3L f   3L f
1110      adefghijk\C0      adefghijk\C0
1111   0: adef   0: adef
1112   1: a   1: a
1113   2: <unset>   2: <unset>
1114   3: f   3: f
1115   0C adef (4)   0C adef (4)
1116    
1117  /^abc\00def/  /^abc\00def/I
1118  Capturing subpattern count = 0  Capturing subpattern count = 0
1119  Options: anchored  Options: anchored
1120  No first char  No first char
1121  Need char = 'f'  No need char
1122      abc\00def\L\C0      abc\00def\L\C0
1123   0: abc\x00def   0: abc\x00def
1124   0C abc (7)   0C abc (7)
1125   0L abc   0L abc
1126    
1127  /word ((?:[a-zA-Z0-9]+ )((?:[a-zA-Z0-9]+ )((?:[a-zA-Z0-9]+ )((?:[a-zA-Z0-9]+  /word ((?:[a-zA-Z0-9]+ )((?:[a-zA-Z0-9]+ )((?:[a-zA-Z0-9]+ )((?:[a-zA-Z0-9]+
1128  )((?:[a-zA-Z0-9]+ )((?:[a-zA-Z0-9]+ )((?:[a-zA-Z0-9]+ )((?:[a-zA-Z0-9]+  )((?:[a-zA-Z0-9]+ )((?:[a-zA-Z0-9]+ )((?:[a-zA-Z0-9]+ )((?:[a-zA-Z0-9]+
1129  )?)?)?)?)?)?)?)?)?otherword/M  )?)?)?)?)?)?)?)?)?otherword/I
 Memory allocation (code space): 428  
1130  Capturing subpattern count = 8  Capturing subpattern count = 8
1131    Contains explicit CR or LF match
1132  No options  No options
1133  First char = 'w'  First char = 'w'
1134  Need char = 'd'  Need char = 'd'
1135    
1136  /.*X/D  /.*X/IDZ
1137  ------------------------------------------------------------------  ------------------------------------------------------------------
1138    0   8 Bra 0          Bra
1139    3     Any*          Any*
1140    5   1 X          X
1141    8   8 Ket          Ket
1142   11     End          End
1143  ------------------------------------------------------------------  ------------------------------------------------------------------
1144  Capturing subpattern count = 0  Capturing subpattern count = 0
1145  No options  No options
1146  First char at start or follows \n  First char at start or follows newline
1147  Need char = 'X'  Need char = 'X'
1148    
1149  /.*X/Ds  /.*X/IDZs
1150  ------------------------------------------------------------------  ------------------------------------------------------------------
1151    0   8 Bra 0          Bra
1152    3     Any*          AllAny*
1153    5   1 X          X
1154    8   8 Ket          Ket
1155   11     End          End
1156  ------------------------------------------------------------------  ------------------------------------------------------------------
1157  Capturing subpattern count = 0  Capturing subpattern count = 0
1158  Options: anchored dotall  Options: anchored dotall
1159  No first char  No first char
1160  Need char = 'X'  Need char = 'X'
1161    
1162  /(.*X|^B)/D  /(.*X|^B)/IDZ
1163  ------------------------------------------------------------------  ------------------------------------------------------------------
1164    0  21 Bra 0          Bra
1165    3   8 Bra 1          CBra 1
1166    6     Any*          Any*
1167    8   1 X          X
1168   11   7 Alt          Alt
1169   14     ^          ^
1170   15   1 B          B
1171   18  15 Ket          Ket
1172   21  21 Ket          Ket
1173   24     End          End
1174  ------------------------------------------------------------------  ------------------------------------------------------------------
1175  Capturing subpattern count = 1  Capturing subpattern count = 1
1176  No options  No options
1177  First char at start or follows \n  First char at start or follows newline
1178  No need char  No need char
1179    
1180  /(.*X|^B)/Ds  /(.*X|^B)/IDZs
1181  ------------------------------------------------------------------  ------------------------------------------------------------------
1182    0  21 Bra 0          Bra
1183    3   8 Bra 1          CBra 1
1184    6     Any*          AllAny*
1185    8   1 X          X
1186   11   7 Alt          Alt
1187   14     ^          ^
1188   15   1 B          B
1189   18  15 Ket          Ket
1190   21  21 Ket          Ket
1191   24     End          End
1192  ------------------------------------------------------------------  ------------------------------------------------------------------
1193  Capturing subpattern count = 1  Capturing subpattern count = 1
1194  Options: anchored dotall  Options: anchored dotall
1195  No first char  No first char
1196  No need char  No need char
1197    
1198  /(?s)(.*X|^B)/D  /(?s)(.*X|^B)/IDZ
1199  ------------------------------------------------------------------  ------------------------------------------------------------------
1200    0  21 Bra 0          Bra
1201    3   8 Bra 1          CBra 1
1202    6     Any*          AllAny*
1203    8   1 X          X
1204   11   7 Alt          Alt
1205   14     ^          ^
1206   15   1 B          B
1207   18  15 Ket          Ket
1208   21  21 Ket          Ket
1209   24     End          End
1210  ------------------------------------------------------------------  ------------------------------------------------------------------
1211  Capturing subpattern count = 1  Capturing subpattern count = 1
1212  Options: anchored dotall  Options: anchored dotall
1213  No first char  No first char
1214  No need char  No need char
1215    
1216  /(?s:.*X|^B)/D  /(?s:.*X|^B)/IDZ
1217  ------------------------------------------------------------------  ------------------------------------------------------------------
1218    0  27 Bra 0          Bra
1219    3  10 Bra 0          Bra
1220    6  04 Opt       04 Opt
1221    8     Any*          AllAny*
1222   10   1 X          X
1223   13   9 Alt          Alt
1224   16  04 Opt       04 Opt
1225   18     ^          ^
1226   19   1 B          B
1227   22  19 Ket          Ket
1228   25  00 Opt       00 Opt
1229   27  27 Ket          Ket
1230   30     End          End
1231  ------------------------------------------------------------------  ------------------------------------------------------------------
1232  Capturing subpattern count = 0  Capturing subpattern count = 0
1233  No options  Options: anchored
1234  First char at start or follows \n  No first char
1235  No need char  No need char
1236    
1237  /\Biss\B/+  /\Biss\B/I+
1238  Capturing subpattern count = 0  Capturing subpattern count = 0
1239  No options  No options
1240  First char = 'i'  First char = 'i'
# Line 1178  Need char = 's' Line 1243  Need char = 's'
1243   0: iss   0: iss
1244   0+ issippi   0+ issippi
1245    
1246  /\Biss\B/+P  /\Biss\B/I+P
1247      Mississippi      Mississippi
1248   0: iss   0: iss
1249   0+ issippi   0+ issippi
1250    
1251  /iss/G+  /iss/IG+
1252  Capturing subpattern count = 0  Capturing subpattern count = 0
1253  No options  No options
1254  First char = 'i'  First char = 'i'
# Line 1194  Need char = 's' Line 1259  Need char = 's'
1259   0: iss   0: iss
1260   0+ ippi   0+ ippi
1261    
1262  /\Biss\B/G+  /\Biss\B/IG+
1263  Capturing subpattern count = 0  Capturing subpattern count = 0
1264  No options  No options
1265  First char = 'i'  First char = 'i'
# Line 1203  Need char = 's' Line 1268  Need char = 's'
1268   0: iss   0: iss
1269   0+ issippi   0+ issippi
1270    
1271  /\Biss\B/g+  /\Biss\B/Ig+
1272  Capturing subpattern count = 0  Capturing subpattern count = 0
1273  No options  No options
1274  First char = 'i'  First char = 'i'
# Line 1218  No match Line 1283  No match
1283      Mississippi\A      Mississippi\A
1284  No match  No match
1285    
1286  /(?<=[Ms])iss/g+  /(?<=[Ms])iss/Ig+
1287  Capturing subpattern count = 0  Capturing subpattern count = 0
1288  No options  No options
1289  First char = 'i'  First char = 'i'
# Line 1229  Need char = 's' Line 1294  Need char = 's'
1294   0: iss   0: iss
1295   0+ ippi   0+ ippi
1296    
1297  /(?<=[Ms])iss/G+  /(?<=[Ms])iss/IG+
1298  Capturing subpattern count = 0  Capturing subpattern count = 0
1299  No options  No options
1300  First char = 'i'  First char = 'i'
# Line 1238  Need char = 's' Line 1303  Need char = 's'
1303   0: iss   0: iss
1304   0+ issippi   0+ issippi
1305    
1306  /^iss/g+  /^iss/Ig+
1307  Capturing subpattern count = 0  Capturing subpattern count = 0
1308  Options: anchored  Options: anchored
1309  No first char  No first char
1310  Need char = 's'  No need char
1311      ississippi      ississippi
1312   0: iss   0: iss
1313   0+ issippi   0+ issippi
1314    
1315  /.*iss/g+  /.*iss/Ig+
1316  Capturing subpattern count = 0  Capturing subpattern count = 0
1317  No options  No options
1318  First char at start or follows \n  First char at start or follows newline
1319  Need char = 's'  Need char = 's'
1320      abciss\nxyzisspqr      abciss\nxyzisspqr
1321   0: abciss   0: abciss
1322   0+ \x0axyzisspqr   0+ \x0axyzisspqr
1323   0: xyziss   0: xyziss
1324   0+ pqr   0+ pqr
1325    
1326  /.i./+g  /.i./I+g
1327  Capturing subpattern count = 0  Capturing subpattern count = 0
1328  No options  No options
1329  No first char  No first char
# Line 1284  Need char = 'i' Line 1349  Need char = 'i'
1349   0+ river   0+ river
1350   0: riv   0: riv
1351   0+ er   0+ er
1352      Missouri river\A      Missouri river\A
1353   0: Mis   0: Mis
1354   0+ souri river   0+ souri river
1355    
1356  /^.is/+g  /^.is/I+g
1357  Capturing subpattern count = 0  Capturing subpattern count = 0
1358  Options: anchored  Options: anchored
1359  No first char  No first char
1360  Need char = 's'  No need char
1361      Mississippi      Mississippi
1362   0: Mis   0: Mis
1363   0+ sissippi   0+ sissippi
1364    
1365  /^ab\n/g+  /^ab\n/Ig+
1366  Capturing subpattern count = 0  Capturing subpattern count = 0
1367    Contains explicit CR or LF match
1368  Options: anchored  Options: anchored
1369  No first char  No first char
1370  Need char = 10  No need char
1371      ab\nab\ncd      ab\nab\ncd
1372   0: ab\x0a   0: ab\x0a
1373   0+ ab\x0acd   0+ ab\x0acd
1374    
1375  /^ab\n/mg+  /^ab\n/Img+
1376  Capturing subpattern count = 0  Capturing subpattern count = 0
1377    Contains explicit CR or LF match
1378  Options: multiline  Options: multiline
1379  First char at start or follows \n  First char at start or follows newline
1380  Need char = 10  Need char = 10
1381      ab\nab\ncd      ab\nab\ncd
1382   0: ab\x0a   0: ab\x0a
# Line 1317  Need char = 10 Line 1384  Need char = 10
1384   0: ab\x0a   0: ab\x0a
1385   0+ cd   0+ cd
1386    
1387  /abc/  /abc/I
1388  Capturing subpattern count = 0  Capturing subpattern count = 0
1389  No options  No options
1390  First char = 'a'  First char = 'a'
1391  Need char = 'c'  Need char = 'c'
1392    
1393  /abc|bac/  /abc|bac/I
1394  Capturing subpattern count = 0  Capturing subpattern count = 0
1395  No options  No options
1396  No first char  No first char
1397  Need char = 'c'  Need char = 'c'
1398    
1399  /(abc|bac)/  /(abc|bac)/I
1400  Capturing subpattern count = 1  Capturing subpattern count = 1
1401  No options  No options
1402  No first char  No first char
1403  Need char = 'c'  Need char = 'c'
1404    
1405  /(abc|(c|dc))/  /(abc|(c|dc))/I
1406  Capturing subpattern count = 2  Capturing subpattern count = 2
1407  No options  No options
1408  No first char  No first char
1409  Need char = 'c'  Need char = 'c'
1410    
1411  /(abc|(d|de)c)/  /(abc|(d|de)c)/I
1412  Capturing subpattern count = 2  Capturing subpattern count = 2
1413  No options  No options
1414  No first char  No first char
1415  Need char = 'c'  Need char = 'c'
1416    
1417  /a*/  /a*/I
1418  Capturing subpattern count = 0  Capturing subpattern count = 0
1419  No options  No options
1420  No first char  No first char
1421  No need char  No need char
1422    
1423  /a+/  /a+/I
1424  Capturing subpattern count = 0  Capturing subpattern count = 0
1425  No options  No options
1426  First char = 'a'  First char = 'a'
1427  No need char  No need char
1428    
1429  /(baa|a+)/  /(baa|a+)/I
1430  Capturing subpattern count = 1  Capturing subpattern count = 1
1431  No options  No options
1432  No first char  No first char
1433  Need char = 'a'  Need char = 'a'
1434    
1435  /a{0,3}/  /a{0,3}/I
1436  Capturing subpattern count = 0  Capturing subpattern count = 0
1437  No options  No options
1438  No first char  No first char
1439  No need char  No need char
1440    
1441  /baa{3,}/  /baa{3,}/I
1442  Capturing subpattern count = 0  Capturing subpattern count = 0
1443  No options  No options
1444  First char = 'b'  First char = 'b'
1445  Need char = 'a'  Need char = 'a'
1446    
1447  /"([^\\"]+|\\.)*"/  /"([^\\"]+|\\.)*"/I
1448  Capturing subpattern count = 1  Capturing subpattern count = 1
1449  No options  No options
1450  First char = '"'  First char = '"'
1451  Need char = '"'  Need char = '"'
1452    
1453  /(abc|ab[cd])/  /(abc|ab[cd])/I
1454  Capturing subpattern count = 1  Capturing subpattern count = 1
1455  No options  No options
1456  First char = 'a'  First char = 'a'
1457  No need char  No need char
1458    
1459  /(a|.)/  /(a|.)/I
1460  Capturing subpattern count = 1  Capturing subpattern count = 1
1461  No options  No options
1462  No first char  No first char
1463  No need char  No need char
1464    
1465  /a|ba|\w/  /a|ba|\w/I
1466  Capturing subpattern count = 0  Capturing subpattern count = 0
1467  No options  No options
1468  No first char  No first char
1469  No need char  No need char
1470    
1471  /abc(?=pqr)/  /abc(?=pqr)/I
1472  Capturing subpattern count = 0  Capturing subpattern count = 0
1473  No options  No options
1474  First char = 'a'  First char = 'a'
1475  Need char = 'r'  Need char = 'r'
1476    
1477  /...(?<=abc)/  /...(?<=abc)/I
1478  Capturing subpattern count = 0  Capturing subpattern count = 0
1479  No options  No options
1480  No first char  No first char
1481  No need char  No need char
1482    
1483  /abc(?!pqr)/  /abc(?!pqr)/I
1484  Capturing subpattern count = 0  Capturing subpattern count = 0
1485  No options  No options
1486  First char = 'a'  First char = 'a'
1487  Need char = 'c'  Need char = 'c'
1488    
1489  /ab./  /ab./I
1490  Capturing subpattern count = 0  Capturing subpattern count = 0
1491  No options  No options
1492  First char = 'a'  First char = 'a'
1493  Need char = 'b'  Need char = 'b'
1494    
1495  /ab[xyz]/  /ab[xyz]/I
1496  Capturing subpattern count = 0  Capturing subpattern count = 0
1497  No options  No options
1498  First char = 'a'  First char = 'a'
1499  Need char = 'b'  Need char = 'b'
1500    
1501  /abc*/  /abc*/I
1502  Capturing subpattern count = 0  Capturing subpattern count = 0
1503  No options  No options
1504  First char = 'a'  First char = 'a'
1505  Need char = 'b'  Need char = 'b'
1506    
1507  /ab.c*/  /ab.c*/I
1508  Capturing subpattern count = 0  Capturing subpattern count = 0
1509  No options  No options
1510  First char = 'a'  First char = 'a'
1511  Need char = 'b'  Need char = 'b'
1512    
1513  /a.c*/  /a.c*/I
1514  Capturing subpattern count = 0  Capturing subpattern count = 0
1515  No options  No options
1516  First char = 'a'  First char = 'a'
1517  No need char  No need char
1518    
1519  /.c*/  /.c*/I
1520  Capturing subpattern count = 0  Capturing subpattern count = 0
1521  No options  No options
1522  No first char  No first char
1523  No need char  No need char
1524    
1525  /ac*/  /ac*/I
1526  Capturing subpattern count = 0  Capturing subpattern count = 0
1527  No options  No options
1528  First char = 'a'  First char = 'a'
1529  No need char  No need char
1530    
1531  /(a.c*|b.c*)/  /(a.c*|b.c*)/I
1532  Capturing subpattern count = 1  Capturing subpattern count = 1
1533  No options  No options
1534  No first char  No first char
1535  No need char  No need char
1536    
1537  /a.c*|aba/  /a.c*|aba/I
1538  Capturing subpattern count = 0  Capturing subpattern count = 0
1539  No options  No options
1540  First char = 'a'  First char = 'a'
1541  No need char  No need char
1542    
1543  /.+a/  /.+a/I
1544  Capturing subpattern count = 0  Capturing subpattern count = 0
1545  No options  No options
1546  No first char  No first char
1547  Need char = 'a'  Need char = 'a'
1548    
1549  /(?=abcda)a.*/  /(?=abcda)a.*/I
1550  Capturing subpattern count = 0  Capturing subpattern count = 0
1551  No options  No options
1552  First char = 'a'  First char = 'a'
1553  No need char  Need char = 'a'
1554    
1555  /(?=a)a.*/  /(?=a)a.*/I
1556  Capturing subpattern count = 0  Capturing subpattern count = 0
1557  No options  No options
1558  First char = 'a'  First char = 'a'
1559  No need char  No need char
1560    
1561  /a(b)*/  /a(b)*/I
1562  Capturing subpattern count = 1  Capturing subpattern count = 1
1563  No options  No options
1564  First char = 'a'  First char = 'a'
1565  No need char  No need char
1566    
1567  /a\d*/  /a\d*/I
1568  Capturing subpattern count = 0  Capturing subpattern count = 0
1569  No options  No options
1570  First char = 'a'  First char = 'a'
1571  No need char  No need char
1572    
1573  /ab\d*/  /ab\d*/I
1574  Capturing subpattern count = 0  Capturing subpattern count = 0
1575  No options  No options
1576  First char = 'a'  First char = 'a'
1577  Need char = 'b'  Need char = 'b'
1578    
1579  /a(\d)*/  /a(\d)*/I
1580  Capturing subpattern count = 1  Capturing subpattern count = 1
1581  No options  No options
1582  First char = 'a'  First char = 'a'
1583  No need char  No need char
1584    
1585  /abcde{0,0}/  /abcde{0,0}/I
1586  Capturing subpattern count = 0  Capturing subpattern count = 0
1587  No options  No options
1588  First char = 'a'  First char = 'a'
1589  Need char = 'd'  Need char = 'd'
1590    
1591  /ab\d+/  /ab\d+/I
1592  Capturing subpattern count = 0  Capturing subpattern count = 0
1593  No options  No options
1594  First char = 'a'  First char = 'a'
1595  Need char = 'b'  Need char = 'b'
1596    
1597  /a(?(1)b)/  /a(?(1)b)(.)/I
1598  Capturing subpattern count = 0  Capturing subpattern count = 1
1599  No options  No options
1600  First char = 'a'  First char = 'a'
1601  No need char  No need char
1602    
1603  /a(?(1)bag|big)/  /a(?(1)bag|big)(.)/I
1604  Capturing subpattern count = 0  Capturing subpattern count = 1
1605  No options  No options
1606  First char = 'a'  First char = 'a'
1607  Need char = 'g'  Need char = 'g'
1608    
1609  /a(?(1)bag|big)*/  /a(?(1)bag|big)*(.)/I
1610  Capturing subpattern count = 0  Capturing subpattern count = 1
1611  No options  No options
1612  First char = 'a'  First char = 'a'
1613  No need char  No need char
1614    
1615  /a(?(1)bag|big)+/  /a(?(1)bag|big)+(.)/I
1616  Capturing subpattern count = 0  Capturing subpattern count = 1
1617  No options  No options
1618  First char = 'a'  First char = 'a'
1619  Need char = 'g'  Need char = 'g'
1620    
1621  /a(?(1)b..|b..)/  /a(?(1)b..|b..)(.)/I
1622  Capturing subpattern count = 0  Capturing subpattern count = 1
1623  No options  No options
1624  First char = 'a'  First char = 'a'
1625  Need char = 'b'  Need char = 'b'
1626    
1627  /ab\d{0}e/  /ab\d{0}e/I
1628  Capturing subpattern count = 0  Capturing subpattern count = 0
1629  No options  No options
1630  First char = 'a'  First char = 'a'
1631  Need char = 'e'  Need char = 'e'
1632    
1633  /a?b?/  /a?b?/I
1634  Capturing subpattern count = 0  Capturing subpattern count = 0
1635  No options  No options
1636  No first char  No first char
# Line 1578  No need char Line 1645  No need char
1645   0:   0:
1646      *** Failers      *** Failers
1647   0:   0:
1648      \N      \N
1649  No match  No match
1650    
1651  /|-/  /|-/I
1652  Capturing subpattern count = 0  Capturing subpattern count = 0
1653  No options  No options
1654  No first char  No first char
# Line 1594  No need char Line 1661  No need char
1661   0: -   0: -
1662      *** Failers      *** Failers
1663   0:   0:
1664      \Nabc      \Nabc
1665  No match  No match
1666    
1667  /a*(b+)(z)(z)/P  /a*(b+)(z)(z)/P
# Line 1623  No match Line 1690  No match
1690   1: bbbb   1: bbbb
1691   2: z   2: z
1692   3: z   3: z
1693    
1694  /^.?abcd/S  /^.?abcd/IS
1695  Capturing subpattern count = 0  Capturing subpattern count = 0
1696  Options: anchored  Options: anchored
1697  No first char  No first char
1698  Need char = 'd'  Need char = 'd'
1699  Study returned NULL  Subject length lower bound = 4
1700    No set of starting bytes
1701    
1702  /\(             # ( at start  /\(             # ( at start
1703    (?:           # Non-capturing bracket    (?:           # Non-capturing bracket
# Line 1638  Study returned NULL Line 1706  Study returned NULL
1706    (?R)          # Recurse - i.e. nested bracketed string    (?R)          # Recurse - i.e. nested bracketed string
1707    )*            # Zero or more contents    )*            # Zero or more contents
1708    \)            # Closing )    \)            # Closing )
1709    /x    /Ix
1710  Capturing subpattern count = 0  Capturing subpattern count = 0
1711  Options: extended  Options: extended
1712  First char = '('  First char = '('
# Line 1649  Need char = ')' Line 1717  Need char = ')'
1717   0: (abcd)   0: (abcd)
1718      xyz(abcd)      xyz(abcd)
1719   0: (abcd)   0: (abcd)
1720      (ab(xy)cd)pqr      (ab(xy)cd)pqr
1721   0: (ab(xy)cd)   0: (ab(xy)cd)
1722      (ab(xycd)pqr      (ab(xycd)pqr
1723   0: (xycd)   0: (xycd)
1724      () abc ()      () abc ()
1725   0: ()   0: ()
1726      12(abcde(fsh)xyz(foo(bar))lmno)89      12(abcde(fsh)xyz(foo(bar))lmno)89
1727   0: (abcde(fsh)xyz(foo(bar))lmno)   0: (abcde(fsh)xyz(foo(bar))lmno)
1728      *** Failers      *** Failers
1729  No match  No match
1730      abcd      abcd
1731  No match  No match
1732      abcd)      abcd)
1733  No match  No match
1734      (abcd      (abcd
1735  No match  No match
1736    
1737  /\(  ( (?>[^()]+) | (?R) )* \) /xg  /\(  ( (?>[^()]+) | (?R) )* \) /Ixg
1738  Capturing subpattern count = 1  Capturing subpattern count = 1
1739  Options: extended  Options: extended
1740  First char = '('  First char = '('
1741  Need char = ')'  Need char = ')'
1742      (ab(xy)cd)pqr      (ab(xy)cd)pqr
1743   0: (ab(xy)cd)   0: (ab(xy)cd)
1744   1: cd   1: cd
1745      1(abcd)(x(y)z)pqr      1(abcd)(x(y)z)pqr
# Line 1680  Need char = ')' Line 1748  Need char = ')'
1748   0: (x(y)z)   0: (x(y)z)
1749   1: z   1: z
1750    
1751  /\(  (?: (?>[^()]+) | (?R) ) \) /x  /\(  (?: (?>[^()]+) | (?R) ) \) /Ix
1752  Capturing subpattern count = 0  Capturing subpattern count = 0
1753  Options: extended  Options: extended
1754  First char = '('  First char = '('
# Line 1689  Need char = ')' Line 1757  Need char = ')'
1757   0: (abcd)   0: (abcd)
1758      (ab(xy)cd)      (ab(xy)cd)
1759   0: (xy)   0: (xy)
1760      (a(b(c)d)e)      (a(b(c)d)e)
1761   0: (c)   0: (c)
1762      ((ab))      ((ab))
1763   0: ((ab))   0: ((ab))
1764      *** Failers      *** Failers
1765  No match  No match
1766      ()      ()
1767  No match  No match
1768    
1769  /\(  (?: (?>[^()]+) | (?R) )? \) /x  /\(  (?: (?>[^()]+) | (?R) )? \) /Ix
1770  Capturing subpattern count = 0  Capturing subpattern count = 0
1771  Options: extended  Options: extended
1772  First char = '('  First char = '('
# Line 1708  Need char = ')' Line 1776  Need char = ')'
1776      12(abcde(fsh)xyz(foo(bar))lmno)89      12(abcde(fsh)xyz(foo(bar))lmno)89
1777   0: (fsh)   0: (fsh)
1778    
1779  /\(  ( (?>[^()]+) | (?R) )* \) /x  /\(  ( (?>[^()]+) | (?R) )* \) /Ix
1780  Capturing subpattern count = 1  Capturing subpattern count = 1
1781  Options: extended  Options: extended
1782  First char = '('  First char = '('
# Line 1717  Need char = ')' Line 1785  Need char = ')'
1785   0: (ab(xy)cd)   0: (ab(xy)cd)
1786   1: cd   1: cd
1787    
1788  /\( ( ( (?>[^()]+) | (?R) )* ) \) /x  /\( ( ( (?>[^()]+) | (?R) )* ) \) /Ix
1789  Capturing subpattern count = 2  Capturing subpattern count = 2
1790  Options: extended  Options: extended
1791  First char = '('  First char = '('
# Line 1727  Need char = ')' Line 1795  Need char = ')'
1795   1: ab(xy)cd   1: ab(xy)cd
1796   2: cd   2: cd
1797    
1798  /\( (123)? ( ( (?>[^()]+) | (?R) )* ) \) /x  /\( (123)? ( ( (?>[^()]+) | (?R) )* ) \) /Ix
1799  Capturing subpattern count = 3  Capturing subpattern count = 3
1800  Options: extended  Options: extended
1801  First char = '('  First char = '('
# Line 1743  Need char = ')' Line 1811  Need char = ')'
1811   2: ab(xy)cd   2: ab(xy)cd
1812   3: cd   3: cd
1813    
1814  /\( ( (123)? ( (?>[^()]+) | (?R) )* ) \) /x  /\( ( (123)? ( (?>[^()]+) | (?R) )* ) \) /Ix
1815  Capturing subpattern count = 3  Capturing subpattern count = 3
1816  Options: extended  Options: extended
1817  First char = '('  First char = '('
# Line 1759  Need char = ')' Line 1827  Need char = ')'
1827   2: 123   2: 123
1828   3: cd   3: cd
1829    
1830  /\( (((((((((( ( (?>[^()]+) | (?R) )* )))))))))) \) /x  /\( (((((((((( ( (?>[^()]+) | (?R) )* )))))))))) \) /Ix
1831  Capturing subpattern count = 11  Capturing subpattern count = 11
1832  Options: extended  Options: extended
1833  First char = '('  First char = '('
# Line 1778  Need char = ')' Line 1846  Need char = ')'
1846  10: ab(xy)cd  10: ab(xy)cd
1847  11: cd  11: cd
1848    
1849  /\( ( ( (?>[^()<>]+) | ((?>[^()]+)) | (?R) )* ) \) /x  /\( ( ( (?>[^()<>]+) | ((?>[^()]+)) | (?R) )* ) \) /Ix
1850  Capturing subpattern count = 3  Capturing subpattern count = 3
1851  Options: extended  Options: extended
1852  First char = '('  First char = '('
# Line 1787  Need char = ')' Line 1855  Need char = ')'
1855   0: (abcd(xyz<p>qrs)123)   0: (abcd(xyz<p>qrs)123)
1856   1: abcd(xyz<p>qrs)123   1: abcd(xyz<p>qrs)123
1857   2: 123   2: 123
  3: <p>qrs  
1858    
1859  /\( ( ( (?>[^()]+) | ((?R)) )* ) \) /x  /\( ( ( (?>[^()]+) | ((?R)) )* ) \) /Ix
1860  Capturing subpattern count = 3  Capturing subpattern count = 3
1861  Options: extended  Options: extended
1862  First char = '('  First char = '('
# Line 1805  Need char = ')' Line 1872  Need char = ')'
1872   2: ij   2: ij
1873   3: (cd(ef)gh)   3: (cd(ef)gh)
1874    
1875  /^[[:alnum:]]/D  /^[[:alnum:]]/DZ
1876    ------------------------------------------------------------------
1877            Bra
1878            ^
1879            [0-9A-Za-z]
1880            Ket
1881            End
1882    ------------------------------------------------------------------
1883    Capturing subpattern count = 0
1884    Options: anchored
1885    No first char
1886    No need char
1887    
1888    /^[[:^alnum:]]/DZ
1889    ------------------------------------------------------------------
1890            Bra
1891            ^
1892            [\x00-/:-@[-`{-\xff] (neg)
1893            Ket
1894            End
1895    ------------------------------------------------------------------
1896    Capturing subpattern count = 0
1897    Options: anchored
1898    No first char
1899    No need char
1900    
1901    /^[[:alpha:]]/DZ
1902    ------------------------------------------------------------------
1903            Bra
1904            ^
1905            [A-Za-z]
1906            Ket
1907            End
1908    ------------------------------------------------------------------
1909    Capturing subpattern count = 0
1910    Options: anchored
1911    No first char
1912    No need char
1913    
1914    /^[[:^alpha:]]/DZ
1915    ------------------------------------------------------------------
1916            Bra
1917            ^
1918            [\x00-@[-`{-\xff] (neg)
1919            Ket
1920            End
1921    ------------------------------------------------------------------
1922    Capturing subpattern count = 0
1923    Options: anchored
1924    No first char
1925    No need char
1926    
1927    /[_[:alpha:]]/IS
1928    Capturing subpattern count = 0
1929    No options
1930    No first char
1931    No need char
1932    Subject length lower bound = 1
1933    Starting byte set: A B C D E F G H I J K L M N O P Q R S T U V W X Y Z
1934      _ a b c d e f g h i j k l m n o p q r s t u v w x y z
1935    
1936    /^[[:ascii:]]/DZ
1937    ------------------------------------------------------------------
1938            Bra
1939            ^
1940            [\x00-\x7f]
1941            Ket
1942            End
1943    ------------------------------------------------------------------
1944    Capturing subpattern count = 0
1945    Options: anchored
1946    No first char
1947    No need char
1948    
1949    /^[[:^ascii:]]/DZ
1950    ------------------------------------------------------------------
1951            Bra
1952            ^
1953            [\x80-\xff] (neg)
1954            Ket
1955            End
1956    ------------------------------------------------------------------
1957    Capturing subpattern count = 0
1958    Options: anchored
1959    No first char
1960    No need char
1961    
1962    /^[[:blank:]]/DZ
1963  ------------------------------------------------------------------  ------------------------------------------------------------------
1964    0  37 Bra 0          Bra
1965    3     ^          ^
1966    4     [0-9A-Za-z]          [\x09 ]
1967   37  37 Ket          Ket
1968   40     End          End
1969  ------------------------------------------------------------------  ------------------------------------------------------------------
1970  Capturing subpattern count = 0  Capturing subpattern count = 0
1971  Options: anchored  Options: anchored
1972  No first char  No first char
1973  No need char  No need char
1974    
1975  /^[[:alpha:]]/D  /^[[:^blank:]]/DZ
1976  ------------------------------------------------------------------  ------------------------------------------------------------------
1977    0  37 Bra 0          Bra
1978    3     ^          ^
1979    4     [A-Za-z]          [\x00-\x08\x0a-\x1f!-\xff] (neg)
1980   37  37 Ket          Ket
1981   40     End          End
1982  ------------------------------------------------------------------  ------------------------------------------------------------------
1983  Capturing subpattern count = 0  Capturing subpattern count = 0
1984  Options: anchored  Options: anchored
1985  No first char  No first char
1986  No need char  No need char
1987    
1988  /^[[:ascii:]]/D  /[\n\x0b\x0c\x0d[:blank:]]/IS
1989    Capturing subpattern count = 0
1990    Contains explicit CR or LF match
1991    No options
1992    No first char
1993    No need char
1994    Subject length lower bound = 1
1995    Starting byte set: \x09 \x0a \x0b \x0c \x0d \x20
1996    
1997    /^[[:cntrl:]]/DZ
1998  ------------------------------------------------------------------  ------------------------------------------------------------------
1999    0  37 Bra 0          Bra
2000    3     ^          ^
2001    4     [\x00-\x7f]          [\x00-\x1f\x7f]
2002   37  37 Ket          Ket
2003   40     End          End
2004  ------------------------------------------------------------------  ------------------------------------------------------------------
2005  Capturing subpattern count = 0  Capturing subpattern count = 0
2006  Options: anchored  Options: anchored
2007  No first char  No first char
2008  No need char  No need char
2009    
2010  /^[[:cntrl:]]/D  /^[[:digit:]]/DZ
2011  ------------------------------------------------------------------  ------------------------------------------------------------------
2012    0  37 Bra 0          Bra
2013    3     ^          ^
2014    4     [\x00-\x1f\x7f]          [0-9]
2015   37  37 Ket          Ket
2016   40     End          End
2017  ------------------------------------------------------------------  ------------------------------------------------------------------
2018  Capturing subpattern count = 0  Capturing subpattern count = 0
2019  Options: anchored  Options: anchored
2020  No first char  No first char
2021  No need char  No need char
2022    
2023  /^[[:digit:]]/D  /^[[:graph:]]/DZ
2024  ------------------------------------------------------------------  ------------------------------------------------------------------
2025    0  37 Bra 0          Bra
2026    3     ^          ^
2027    4     [0-9]          [!-~]
2028   37  37 Ket          Ket
2029   40     End          End
2030  ------------------------------------------------------------------  ------------------------------------------------------------------
2031  Capturing subpattern count = 0  Capturing subpattern count = 0
2032  Options: anchored  Options: anchored
2033  No first char  No first char
2034  No need char  No need char
2035    
2036  /^[[:graph:]]/D  /^[[:lower:]]/DZ
2037  ------------------------------------------------------------------  ------------------------------------------------------------------
2038    0  37 Bra 0          Bra
2039    3     ^          ^
2040    4     [!-~]          [a-z]
2041   37  37 Ket          Ket
2042   40     End          End
2043  ------------------------------------------------------------------  ------------------------------------------------------------------
2044  Capturing subpattern count = 0  Capturing subpattern count = 0
2045  Options: anchored  Options: anchored
2046  No first char  No first char
2047  No need char  No need char
2048    
2049  /^[[:lower:]]/D  /^[[:print:]]/DZ
2050  ------------------------------------------------------------------  ------------------------------------------------------------------
2051    0  37 Bra 0          Bra
2052    3     ^          ^
2053    4     [a-z]          [ -~]
2054   37  37 Ket          Ket
2055   40     End          End
2056  ------------------------------------------------------------------  ------------------------------------------------------------------
2057  Capturing subpattern count = 0  Capturing subpattern count = 0
2058  Options: anchored  Options: anchored
2059  No first char  No first char
2060  No need char  No need char
2061    
2062  /^[[:print:]]/D  /^[[:punct:]]/DZ
2063  ------------------------------------------------------------------  ------------------------------------------------------------------
2064    0  37 Bra 0          Bra
2065    3     ^          ^
2066    4     [ -~]          [!-/:-@[-`{-~]
2067   37  37 Ket          Ket
2068   40     End          End
2069  ------------------------------------------------------------------  ------------------------------------------------------------------
2070  Capturing subpattern count = 0  Capturing subpattern count = 0
2071  Options: anchored  Options: anchored
2072  No first char  No first char
2073  No need char  No need char
2074    
2075  /^[[:punct:]]/D  /^[[:space:]]/DZ
2076  ------------------------------------------------------------------  ------------------------------------------------------------------
2077    0  37 Bra 0          Bra
2078    3     ^          ^
2079    4     [!-/:-@[-`{-~]          [\x09-\x0d ]
2080   37  37 Ket          Ket
2081   40     End          End
2082  ------------------------------------------------------------------  ------------------------------------------------------------------
2083  Capturing subpattern count = 0  Capturing subpattern count = 0
2084  Options: anchored  Options: anchored
2085  No first char  No first char
2086  No need char  No need char
2087    
2088  /^[[:space:]]/D  /^[[:upper:]]/DZ
2089  ------------------------------------------------------------------  ------------------------------------------------------------------
2090    0  37 Bra 0          Bra
2091    3     ^          ^
2092    4     [\x09-\x0d ]          [A-Z]
2093   37  37 Ket          Ket
2094   40     End          End
2095  ------------------------------------------------------------------  ------------------------------------------------------------------
2096  Capturing subpattern count = 0  Capturing subpattern count = 0
2097  Options: anchored  Options: anchored
2098  No first char  No first char
2099  No need char  No need char
2100    
2101  /^[[:upper:]]/D  /^[[:xdigit:]]/DZ
2102  ------------------------------------------------------------------  ------------------------------------------------------------------
2103    0  37 Bra 0          Bra
2104    3     ^          ^
2105    4     [A-Z]          [0-9A-Fa-f]
2106   37  37 Ket          Ket
2107   40     End          End
2108  ------------------------------------------------------------------  ------------------------------------------------------------------
2109  Capturing subpattern count = 0  Capturing subpattern count = 0
2110  Options: anchored  Options: anchored
2111  No first char  No first char
2112  No need char  No need char
2113    
2114  /^[[:xdigit:]]/D  /^[[:word:]]/DZ
2115  ------------------------------------------------------------------  ------------------------------------------------------------------
2116    0  37 Bra 0          Bra
2117    3     ^          ^
2118    4     [0-9A-Fa-f]          [0-9A-Z_a-z]
2119   37  37 Ket          Ket
2120   40     End          End
2121  ------------------------------------------------------------------  ------------------------------------------------------------------
2122  Capturing subpattern count = 0  Capturing subpattern count = 0
2123  Options: anchored  Options: anchored
2124  No first char  No first char
2125  No need char  No need char
2126    
2127  /^[[:word:]]/D  /^[[:^cntrl:]]/DZ
2128  ------------------------------------------------------------------  ------------------------------------------------------------------
2129    0  37 Bra 0          Bra
2130    3     ^          ^
2131    4     [0-9A-Z_a-z]          [ -~\x80-\xff] (neg)
2132   37  37 Ket          Ket
2133   40     End          End
2134  ------------------------------------------------------------------  ------------------------------------------------------------------
2135  Capturing subpattern count = 0  Capturing subpattern count = 0
2136  Options: anchored  Options: anchored
2137  No first char  No first char
2138  No need char  No need char
2139    
2140  /^[[:^cntrl:]]/D  /^[12[:^digit:]]/DZ
2141  ------------------------------------------------------------------  ------------------------------------------------------------------
2142    0  37 Bra 0          Bra
2143    3     ^          ^
2144    4     [ -~\x80-\xff]          [\x00-/12:-\xff] (neg)
2145   37  37 Ket          Ket
2146   40     End          End
2147  ------------------------------------------------------------------  ------------------------------------------------------------------
2148  Capturing subpattern count = 0  Capturing subpattern count = 0
2149  Options: anchored  Options: anchored
2150  No first char  No first char
2151  No need char  No need char
2152    
2153  /^[12[:^digit:]]/D  /^[[:^blank:]]/DZ
2154  ------------------------------------------------------------------  ------------------------------------------------------------------
2155    0  37 Bra 0          Bra
2156    3     ^          ^
2157    4     [\x00-/1-2:-\xff]          [\x00-\x08\x0a-\x1f!-\xff] (neg)
2158   37  37 Ket          Ket
2159   40     End          End
2160  ------------------------------------------------------------------  ------------------------------------------------------------------
2161  Capturing subpattern count = 0  Capturing subpattern count = 0
2162  Options: anchored  Options: anchored
2163  No first char  No first char
2164  No need char  No need char
2165    
2166  /[01[:alpha:]%]/D  /[01[:alpha:]%]/DZ
2167  ------------------------------------------------------------------  ------------------------------------------------------------------
2168    0  36 Bra 0          Bra
2169    3     [%0-1A-Za-z]          [%01A-Za-z]
2170   36  36 Ket          Ket
2171   39     End          End
2172  ------------------------------------------------------------------  ------------------------------------------------------------------
2173  Capturing subpattern count = 0  Capturing subpattern count = 0
2174  No options  No options
2175  No first char  No first char
2176  No need char  No need char
2177    
2178  /[[.ch.]]/  /[[.ch.]]/I
2179  Failed: POSIX collating elements are not supported at offset 1  Failed: POSIX collating elements are not supported at offset 1
2180    
2181  /[[=ch=]]/  /[[=ch=]]/I
2182  Failed: POSIX collating elements are not supported at offset 1  Failed: POSIX collating elements are not supported at offset 1
2183    
2184  /[[:rhubarb:]]/  /[[:rhubarb:]]/I
2185  Failed: unknown POSIX class name at offset 3  Failed: unknown POSIX class name at offset 3
2186    
2187  /[[:upper:]]/i  /[[:upper:]]/Ii
2188  Capturing subpattern count = 0  Capturing subpattern count = 0
2189  Options: caseless  Options: caseless
2190  No first char  No first char
2191  No need char  No need char
2192      A      A
2193   0: A   0: A
2194      a      a
2195   0: a   0: a
2196    
2197  /[[:lower:]]/i  /[[:lower:]]/Ii
2198  Capturing subpattern count = 0  Capturing subpattern count = 0
2199  Options: caseless  Options: caseless
2200  No first char  No first char
2201  No need char  No need char
2202      A      A
2203   0: A   0: A
2204      a      a
2205   0: a   0: a
2206    
2207  /((?-i)[[:lower:]])[[:lower:]]/i  /((?-i)[[:lower:]])[[:lower:]]/Ii
2208  Capturing subpattern count = 1  Capturing subpattern count = 1
2209  Options: caseless  Options: caseless
 Case state changes  
2210  No first char  No first char
2211  No need char  No need char
2212      ab      ab
# Line 2058  No need char Line 2220  No need char
2220   1: a   1: a
2221      Ab      Ab
2222  No match  No match
2223      AB      AB
2224  No match  No match
2225    
2226  /[\200-\410]/  /[\200-\110]/I
2227  Failed: range out of order in character class at offset 9  Failed: range out of order in character class at offset 9
2228    
2229  /^(?(0)f|b)oo/  /^(?(0)f|b)oo/I
2230  Failed: invalid condition (?(0) at offset 5  Failed: invalid condition (?(0) at offset 6
2231    
2232  /This one's here because of the large output vector needed/  /This one's here because of the large output vector needed/I
2233  Capturing subpattern count = 0  Capturing subpattern count = 0
2234  No options  No options
2235  First char = 'T'  First char = 'T'
2236  Need char = 'd'  Need char = 'd'
2237    
2238  /(\d+(?:\s|$))(\d+(?:\s|$))(\d+(?:\s|$))(\d+(?:\s|$))(\d+(?:\s|$))(\d+(?:\s|$))(\d+(?:\s|$))(\d+(?:\s|$))(\d+(?:\s|$))(\d+(?:\s|$))(\d+(?:\s|$))(\d+(?:\s|$))(\d+(?:\s|$))(\d+(?:\s|$))(\d+(?:\s|$))(\d+(?:\s|$))(\d+(?:\s|$))(\d+(?:\s|$))(\d+(?:\s|$))(\d+(?:\s|$))(\d+(?:\s|$))(\d+(?:\s|$))(\d+(?:\s|$))(\d+(?:\s|$))(\d+(?:\s|$))(\d+(?:\s|$))(\d+(?:\s|$))(\d+(?:\s|$))(\d+(?:\s|$))(\d+(?:\s|$))(\d+(?:\s|$))(\d+(?:\s|$))(\d+(?:\s|$))(\d+(?:\s|$))(\d+(?:\s|$))(\d+(?:\s|$))(\d+(?:\s|$))(\d+(?:\s|$))(\d+(?:\s|$))(\d+(?:\s|$))(\d+(?:\s|$))(\d+(?:\s|$))(\d+(?:\s|$))(\d+(?:\s|$))(\d+(?:\s|$))(\d+(?:\s|$))(\d+(?:\s|$))(\d+(?:\s|$))(\d+(?:\s|$))(\d+(?:\s|$))(\d+(?:\s|$))(\d+(?:\s|$))(\d+(?:\s|$))(\d+(?:\s|$))(\d+(?:\s|$))(\d+(?:\s|$))(\d+(?:\s|$))(\d+(?:\s|$))(\d+(?:\s|$))(\d+(?:\s|$))(\d+(?:\s|$))(\d+(?:\s|$))(\d+(?:\s|$))(\d+(?:\s|$))(\d+(?:\s|$))(\d+(?:\s|$))(\d+(?:\s|$))(\d+(?:\s|$))(\d+(?:\s|$))(\d+(?:\s|$))(\d+(?:\s|$))(\d+(?:\s|$))(\d+(?:\s|$))(\d+(?:\s|$))(\d+(?:\s|$))(\d+(?:\s|$))(\d+(?:\s|$))(\d+(?:\s|$))(\d+(?:\s|$))(\d+(?:\s|$))(\d+(?:\s|$))(\d+(?:\s|$))(\d+(?:\s|$))(\d+(?:\s|$))(\d+(?:\s|$))(\d+(?:\s|$))(\d+(?:\s|$))(\d+(?:\s|$))(\d+(?:\s|$))(\d+(?:\s|$))(\d+(?:\s|$))(\d+(?:\s|$))(\d+(?:\s|$))(\d+(?:\s|$))(\d+(?:\s|$))(\d+(?:\s|$))(\d+(?:\s|$))(\d+(?:\s|$))(\d+(?:\s|$))(\d+(?:\s|$))(\d+(?:\s|$))(\d+(?:\s|$))(\d+(?:\s|$))(\d+(?:\s|$))(\d+(?:\s|$))(\d+(?:\s|$))(\d+(?:\s|$))(\d+(?:\s|$))(\d+(?:\s|$))(\d+(?:\s|$))(\d+(?:\s|$))(\d+(?:\s|$))(\d+(?:\s|$))(\d+(?:\s|$))(\d+(?:\s|$))(\d+(?:\s|$))(\d+(?:\s|$))(\d+(?:\s|$))(\d+(?:\s|$))(\d+(?:\s|$))(\d+(?:\s|$))(\d+(?:\s|$))(\d+(?:\s|$))(\d+(?:\s|$))(\d+(?:\s|$))(\d+(?:\s|$))(\d+(?:\s|$))(\d+(?:\s|$))(\d+(?:\s|$))(\d+(?:\s|$))(\d+(?:\s|$))(\d+(?:\s|$))(\d+(?:\s|$))(\d+(?:\s|$))(\d+(?:\s|$))(\d+(?:\s|$))(\d+(?:\s|$))(\d+(?:\s|$))(\d+(?:\s|$))(\d+(?:\s|$))(\d+(?:\s|$))(\d+(?:\s|$))(\d+(?:\s|$))(\d+(?:\s|$))(\d+(?:\s|$))(\d+(?:\s|$))(\d+(?:\s|$))(\d+(?:\s|$))(\d+(?:\s|$))(\d+(?:\s|$))(\d+(?:\s|$))(\d+(?:\s|$))(\d+(?:\s|$))(\d+(?:\s|$))(\d+(?:\s|$))(\d+(?:\s|$))(\d+(?:\s|$))(\d+(?:\s|$))(\d+(?:\s|$))(\d+(?:\s|$))(\d+(?:\s|$))(\d+(?:\s|$))(\d+(?:\s|$))(\d+(?:\s|$))(\d+(?:\s|$))(\d+(?:\s|$))(\d+(?:\s|$))(\d+(?:\s|$))(\d+(?:\s|$))(\d+(?:\s|$))(\d+(?:\s|$))(\d+(?:\s|$))(\d+(?:\s|$))(\d+(?:\s|$))(\d+(?:\s|$))(\d+(?:\s|$))(\d+(?:\s|$))(\d+(?:\s|$))(\d+(?:\s|$))(\d+(?:\s|$))(\d+(?:\s|$))(\d+(?:\s|$))(\d+(?:\s|$))(\d+(?:\s|$))(\d+(?:\s|$))(\d+(?:\s|$))(\d+(?:\s|$))(\d+(?:\s|$))(\d+(?:\s|$))(\d+(?:\s|$))(\d+(?:\s|$))(\d+(?:\s|$))(\d+(?:\s|$))(\d+(?:\s|$))(\d+(?:\s|$))(\d+(?:\s|$))(\d+(?:\s|$))(\d+(?:\s|$))(\d+(?:\s|$))(\d+(?:\s|$))(\d+(?:\s|$))(\d+(?:\s|$))(\d+(?:\s|$))(\d+(?:\s|$))(\d+(?:\s|$))(\d+(?:\s|$))(\d+(?:\s|$))(\d+(?:\s|$))(\d+(?:\s|$))(\d+(?:\s|$))(\d+(?:\s|$))(\d+(?:\s|$))(\d+(?:\s|$))(\d+(?:\s|$))(\d+(?:\s|$))(\d+(?:\s|$))(\d+(?:\s|$))(\d+(?:\s|$))(\d+(?:\s|$))(\d+(?:\s|$))(\d+(?:\s|$))(\d+(?:\s|$))(\d+(?:\s|$))(\d+(?:\s|$))(\d+(?:\s|$))(\d+(?:\s|$))(\d+(?:\s|$))(\d+(?:\s|$))(\d+(?:\s|$))(\d+(?:\s|$))(\d+(?:\s|$))(\d+(?:\s|$))(\d+(?:\s|$))(\d+(?:\s|$))(\d+(?:\s|$))(\d+(?:\s|$))(\d+(?:\s|$))(\d+(?:\s|$))(\d+(?:\s|$))(\d+(?:\s|$))(\d+(?:\s|$))(\d+(?:\s|$))(\d+(?:\s|$))(\d+(?:\s|$))(\d+(?:\s|$))(\d+(?:\s|$))(\d+(?:\s|$))(\d+(?:\s|$))(\d+(?:\s|$))(\d+(?:\s|$))(\d+(?:\s|$))(\d+(?:\s|$))(\d+(?:\s|$))(\d+(?:\s|$))(\d+(?:\s|$))(\d+(?:\s|$))(\d+(?:\s|$))(\d+(?:\s|$))(\d+(?:\s|$))(\d+(?:\s|$))(\d+(?:\s|$))(\d+(?:\s|$))(\d+(?:\s|$))(\d+(?:\s|$))(\d+(?:\s|$))(\d+(?:\s|$))(\d+(?:\s|$))(\d+(?:\s|$))(\d+(?:\s|$))(\w+)\s+(\270)/  /(\d+(?:\s|$))(\d+(?:\s|$))(\d+(?:\s|$))(\d+(?:\s|$))(\d+(?:\s|$))(\d+(?:\s|$))(\d+(?:\s|$))(\d+(?:\s|$))(\d+(?:\s|$))(\d+(?:\s|$))(\d+(?:\s|$))(\d+(?:\s|$))(\d+(?:\s|$))(\d+(?:\s|$))(\d+(?:\s|$))(\d+(?:\s|$))(\d+(?:\s|$))(\d+(?:\s|$))(\d+(?:\s|$))(\d+(?:\s|$))(\d+(?:\s|$))(\d+(?:\s|$))(\d+(?:\s|$))(\d+(?:\s|$))(\d+(?:\s|$))(\d+(?:\s|$))(\d+(?:\s|$))(\d+(?:\s|$))(\d+(?:\s|$))(\d+(?:\s|$))(\d+(?:\s|$))(\d+(?:\s|$))(\d+(?:\s|$))(\d+(?:\s|$))(\d+(?:\s|$))(\d+(?:\s|$))(\d+(?:\s|$))(\d+(?:\s|$))(\d+(?:\s|$))(\d+(?:\s|$))(\d+(?:\s|$))(\d+(?:\s|$))(\d+(?:\s|$))(\d+(?:\s|$))(\d+(?:\s|$))(\d+(?:\s|$))(\d+(?:\s|$))(\d+(?:\s|$))(\d+(?:\s|$))(\d+(?:\s|$))(\d+(?:\s|$))(\d+(?:\s|$))(\d+(?:\s|$))(\d+(?:\s|$))(\d+(?:\s|$))(\d+(?:\s|$))(\d+(?:\s|$))(\d+(?:\s|$))(\d+(?:\s|$))(\d+(?:\s|$))(\d+(?:\s|$))(\d+(?:\s|$))(\d+(?:\s|$))(\d+(?:\s|$))(\d+(?:\s|$))(\d+(?:\s|$))(\d+(?:\s|$))(\d+(?:\s|$))(\d+(?:\s|$))(\d+(?:\s|$))(\d+(?:\s|$))(\d+(?:\s|$))(\d+(?:\s|$))(\d+(?:\s|$))(\d+(?:\s|$))(\d+(?:\s|$))(\d+(?:\s|$))(\d+(?:\s|$))(\d+(?:\s|$))(\d+(?:\s|$))(\d+(?:\s|$))(\d+(?:\s|$))(\d+(?:\s|$))(\d+(?:\s|$))(\d+(?:\s|$))(\d+(?:\s|$))(\d+(?:\s|$))(\d+(?:\s|$))(\d+(?:\s|$))(\d+(?:\s|$))(\d+(?:\s|$))(\d+(?:\s|$))(\d+(?:\s|$))(\d+(?:\s|$))(\d+(?:\s|$))(\d+(?:\s|$))(\d+(?:\s|$))(\d+(?:\s|$))(\d+(?:\s|$))(\d+(?:\s|$))(\d+(?:\s|$))(\d+(?:\s|$))(\d+(?:\s|$))(\d+(?:\s|$))(\d+(?:\s|$))(\d+(?:\s|$))(\d+(?:\s|$))(\d+(?:\s|$))(\d+(?:\s|$))(\d+(?:\s|$))(\d+(?:\s|$))(\d+(?:\s|$))(\d+(?:\s|$))(\d+(?:\s|$))(\d+(?:\s|$))(\d+(?:\s|$))(\d+(?:\s|$))(\d+(?:\s|$))(\d+(?:\s|$))(\d+(?:\s|$))(\d+(?:\s|$))(\d+(?:\s|$))(\d+(?:\s|$))(\d+(?:\s|$))(\d+(?:\s|$))(\d+(?:\s|$))(\d+(?:\s|$))(\d+(?:\s|$))(\d+(?:\s|$))(\d+(?:\s|$))(\d+(?:\s|$))(\d+(?:\s|$))(\d+(?:\s|$))(\d+(?:\s|$))(\d+(?:\s|$))(\d+(?:\s|$))(\d+(?:\s|$))(\d+(?:\s|$))(\d+(?:\s|$))(\d+(?:\s|$))(\d+(?:\s|$))(\d+(?:\s|$))(\d+(?:\s|$))(\d+(?:\s|$))(\d+(?:\s|$))(\d+(?:\s|$))(\d+(?:\s|$))(\d+(?:\s|$))(\d+(?:\s|$))(\d+(?:\s|$))(\d+(?:\s|$))(\d+(?:\s|$))(\d+(?:\s|$))(\d+(?:\s|$))(\d+(?:\s|$))(\d+(?:\s|$))(\d+(?:\s|$))(\d+(?:\s|$))(\d+(?:\s|$))(\d+(?:\s|$))(\d+(?:\s|$))(\d+(?:\s|$))(\d+(?:\s|$))(\d+(?:\s|$))(\d+(?:\s|$))(\d+(?:\s|$))(\d+(?:\s|$))(\d+(?:\s|$))(\d+(?:\s|$))(\d+(?:\s|$))(\d+(?:\s|$))(\d+(?:\s|$))(\d+(?:\s|$))(\d+(?:\s|$))(\d+(?:\s|$))(\d+(?:\s|$))(\d+(?:\s|$))(\d+(?:\s|$))(\d+(?:\s|$))(\d+(?:\s|$))(\d+(?:\s|$))(\d+(?:\s|$))(\d+(?:\s|$))(\d+(?:\s|$))(\d+(?:\s|$))(\d+(?:\s|$))(\d+(?:\s|$))(\d+(?:\s|$))(\d+(?:\s|$))(\d+(?:\s|$))(\d+(?:\s|$))(\d+(?:\s|$))(\d+(?:\s|$))(\d+(?:\s|$))(\d+(?:\s|$))(\d+(?:\s|$))(\d+(?:\s|$))(\d+(?:\s|$))(\d+(?:\s|$))(\d+(?:\s|$))(\d+(?:\s|$))(\d+(?:\s|$))(\d+(?:\s|$))(\d+(?:\s|$))(\d+(?:\s|$))(\d+(?:\s|$))(\d+(?:\s|$))(\d+(?:\s|$))(\d+(?:\s|$))(\d+(?:\s|$))(\d+(?:\s|$))(\d+(?:\s|$))(\d+(?:\s|$))(\d+(?:\s|$))(\d+(?:\s|$))(\d+(?:\s|$))(\d+(?:\s|$))(\d+(?:\s|$))(\d+(?:\s|$))(\d+(?:\s|$))(\d+(?:\s|$))(\d+(?:\s|$))(\d+(?:\s|$))(\d+(?:\s|$))(\d+(?:\s|$))(\d+(?:\s|$))(\d+(?:\s|$))(\d+(?:\s|$))(\d+(?:\s|$))(\d+(?:\s|$))(\d+(?:\s|$))(\d+(?:\s|$))(\d+(?:\s|$))(\d+(?:\s|$))(\d+(?:\s|$))(\d+(?:\s|$))(\d+(?:\s|$))(\d+(?:\s|$))(\d+(?:\s|$))(\d+(?:\s|$))(\d+(?:\s|$))(\d+(?:\s|$))(\d+(?:\s|$))(\d+(?:\s|$))(\d+(?:\s|$))(\d+(?:\s|$))(\d+(?:\s|$))(\d+(?:\s|$))(\d+(?:\s|$))(\d+(?:\s|$))(\d+(?:\s|$))(\d+(?:\s|$))(\d+(?:\s|$))(\d+(?:\s|$))(\d+(?:\s|$))(\d+(?:\s|$))(\d+(?:\s|$))(\d+(?:\s|$))(\d+(?:\s|$))(\d+(?:\s|$))(\d+(?:\s|$))(\d+(?:\s|$))(\d+(?:\s|$))(\d+(?:\s|$))(\d+(?:\s|$))(\d+(?:\s|$))(\d+(?:\s|$))(\d+(?:\s|$))(\d+(?:\s|$))(\w+)\s+(\270)/I
2239  Capturing subpattern count = 271  Capturing subpattern count = 271
2240  Max back reference = 270  Max back reference = 270
2241  No options  No options
# Line 2353  No need char Line 2515  No need char
2515  270: ABC  270: ABC
2516  271: ABC  271: ABC
2517    
2518  /This one's here because Perl does this differently and PCRE can't at present/  /This one's here because Perl does this differently and PCRE can't at present/I
2519  Capturing subpattern count = 0  Capturing subpattern count = 0
2520  No options  No options
2521  First char = 'T'  First char = 'T'
2522  Need char = 't'  Need char = 't'
2523    
2524  /(main(O)?)+/  /(main(O)?)+/I
2525  Capturing subpattern count = 2  Capturing subpattern count = 2
2526  No options  No options
2527  First char = 'm'  First char = 'm'
# Line 2371  Need char = 'n' Line 2533  Need char = 'n'
2533   0: mainOmain   0: mainOmain
2534   1: main   1: main
2535   2: O   2: O
2536    
2537  / End of testinput2 /  /These are all cases where Perl does it differently (nested captures)/I
2538  Capturing subpattern count = 0  Capturing subpattern count = 1
2539  No options  No options
2540  First char = ' '  First char = 'T'
2541  Need char = ' '  Need char = 's'
2542    
2543    /^(a(b)?)+$/I
2544    Capturing subpattern count = 2
2545    Options: anchored
2546    No first char
2547    No need char
2548        aba
2549     0: aba
2550     1: a
2551     2: b
2552    
2553    /^(aa(bb)?)+$/I
2554    Capturing subpattern count = 2
2555    Options: anchored
2556    No first char
2557    No need char
2558        aabbaa
2559     0: aabbaa
2560     1: aa
2561     2: bb
2562    
2563    /^(aa|aa(bb))+$/I
2564    Capturing subpattern count = 2
2565    Options: anchored
2566    No first char
2567    No need char
2568        aabbaa
2569     0: aabbaa
2570     1: aa
2571     2: bb
2572    
2573    /^(aa(bb)??)+$/I
2574    Capturing subpattern count = 2
2575    Options: anchored
2576    No first char
2577    No need char
2578        aabbaa
2579     0: aabbaa
2580     1: aa
2581     2: bb
2582    
2583    /^(?:aa(bb)?)+$/I
2584    Capturing subpattern count = 1
2585    Options: anchored
2586    No first char
2587    No need char
2588        aabbaa
2589     0: aabbaa
2590     1: bb
2591    
2592    /^(aa(b(b))?)+$/I
2593    Capturing subpattern count = 3
2594    Options: anchored
2595    No first char
2596    No need char
2597        aabbaa
2598     0: aabbaa
2599     1: aa
2600     2: bb
2601     3: b
2602    
2603    /^(?:aa(b(b))?)+$/I
2604    Capturing subpattern count = 2
2605    Options: anchored
2606    No first char
2607    No need char
2608        aabbaa
2609     0: aabbaa
2610     1: bb
2611     2: b
2612    
2613    /^(?:aa(b(?:b))?)+$/I
2614    Capturing subpattern count = 1
2615    Options: anchored
2616    No first char
2617    No need char
2618        aabbaa
2619     0: aabbaa
2620     1: bb
2621    
2622    /^(?:aa(bb(?:b))?)+$/I
2623    Capturing subpattern count = 1
2624    Options: anchored
2625    No first char
2626    No need char
2627        aabbbaa
2628     0: aabbbaa
2629     1: bbb
2630    
2631    /^(?:aa(b(?:bb))?)+$/I
2632    Capturing subpattern count = 1
2633    Options: anchored
2634    No first char
2635    No need char
2636        aabbbaa
2637     0: aabbbaa
2638     1: bbb
2639    
2640    /^(?:aa(?:b(b))?)+$/I
2641    Capturing subpattern count = 1
2642    Options: anchored
2643    No first char
2644    No need char
2645        aabbaa
2646     0: aabbaa
2647     1: b
2648    
2649    /^(?:aa(?:b(bb))?)+$/I
2650    Capturing subpattern count = 1
2651    Options: anchored
2652    No first char
2653    No need char
2654        aabbbaa
2655     0: aabbbaa
2656     1: bb
2657    
2658    /^(aa(b(bb))?)+$/I
2659    Capturing subpattern count = 3
2660    Options: anchored
2661    No first char
2662    No need char
2663        aabbbaa
2664     0: aabbbaa
2665     1: aa
2666     2: bbb
2667     3: bb
2668    
2669    /^(aa(bb(bb))?)+$/I
2670    Capturing subpattern count = 3
2671    Options: anchored
2672    No first char
2673    No need char
2674        aabbbbaa
2675     0: aabbbbaa
2676     1: aa
2677     2: bbbb
2678     3: bb
2679    
2680    /--------------------------------------------------------------------/I
2681    Capturing subpattern count = 0
2682    No options
2683    First char = '-'
2684    Need char = '-'
2685    
2686    /#/IxDZ
2687    ------------------------------------------------------------------
2688            Bra
2689            Ket
2690            End
2691    ------------------------------------------------------------------
2692    Capturing subpattern count = 0
2693    Options: extended
2694    No first char
2695    No need char
2696    
2697    /a#/IxDZ
2698    ------------------------------------------------------------------
2699            Bra
2700            a
2701            Ket
2702            End
2703    ------------------------------------------------------------------
2704    Capturing subpattern count = 0
2705    Options: extended
2706    First char = 'a'
2707    No need char
2708    
2709    /[\s]/DZ
2710    ------------------------------------------------------------------
2711            Bra
2712            [\x09\x0a\x0c\x0d ]
2713            Ket
2714            End
2715    ------------------------------------------------------------------
2716    Capturing subpattern count = 0
2717    No options
2718    No first char
2719    No need char
2720    
2721    /[\S]/DZ
2722    ------------------------------------------------------------------
2723            Bra
2724            [\x00-\x08\x0b\x0e-\x1f!-\xff] (neg)
2725            Ket
2726            End
2727    ------------------------------------------------------------------
2728    Capturing subpattern count = 0
2729    No options
2730    No first char
2731    No need char
2732    
2733    /a(?i)b/DZ
2734    ------------------------------------------------------------------
2735            Bra
2736            a
2737         01 Opt
2738         NC b
2739            Ket
2740            End
2741    ------------------------------------------------------------------
2742    Capturing subpattern count = 0
2743    No options
2744    First char = 'a'
2745    Need char = 'b' (caseless)
2746        ab
2747     0: ab
2748        aB
2749     0: aB
2750        *** Failers
2751    No match
2752        AB
2753    No match
2754    
2755    /(a(?i)b)/DZ
2756    ------------------------------------------------------------------
2757            Bra
2758            CBra 1
2759            a
2760         01 Opt
2761         NC b
2762            Ket
2763         00 Opt
2764            Ket
2765            End
2766    ------------------------------------------------------------------
2767    Capturing subpattern count = 1
2768    No options
2769    First char = 'a'
2770    Need char = 'b' (caseless)
2771        ab
2772     0: ab
2773     1: ab
2774        aB
2775     0: aB
2776     1: aB
2777        *** Failers
2778    No match
2779        AB
2780    No match
2781    
2782    /   (?i)abc/IxDZ
2783    ------------------------------------------------------------------
2784            Bra
2785         NC abc
2786            Ket
2787            End
2788    ------------------------------------------------------------------
2789    Capturing subpattern count = 0
2790    Options: caseless extended
2791    First char = 'a' (caseless)
2792    Need char = 'c' (caseless)
2793    
2794    /#this is a comment
2795      (?i)abc/IxDZ
2796    ------------------------------------------------------------------
2797            Bra
2798         NC abc
2799            Ket
2800            End
2801    ------------------------------------------------------------------
2802    Capturing subpattern count = 0
2803    Options: caseless extended
2804    First char = 'a' (caseless)
2805    Need char = 'c' (caseless)
2806    
2807    /123456789012345678901234567890123456789012345678901234567890123456789012345678901234567890123456789012345678901234567890123456789012345678901234567890123456789012345678901234567890123456789012345678901234567890123456789012345678901234567890123456789012345678901234567890123456789012345678901234567890/DZ
2808    ------------------------------------------------------------------
2809            Bra
2810            123456789012345678901234567890123456789012345678901234567890123456789012345678901234567890123456789012345678901234567890123456789012345678901234567890123456789012345678901234567890123456789012345678901234567890123456789012345678901234567890123456789012345678901234567890123456789012345678901234567890
2811            Ket
2812            End
2813    ------------------------------------------------------------------
2814    Capturing subpattern count = 0
2815    No options
2816    First char = '1'
2817    Need char = '0'
2818    
2819    /\Q123456789012345678901234567890123456789012345678901234567890123456789012345678901234567890123456789012345678901234567890123456789012345678901234567890123456789012345678901234567890123456789012345678901234567890123456789012345678901234567890123456789012345678901234567890123456789012345678901234567890/DZ
2820    ------------------------------------------------------------------
2821            Bra
2822            123456789012345678901234567890123456789012345678901234567890123456789012345678901234567890123456789012345678901234567890123456789012345678901234567890123456789012345678901234567890123456789012345678901234567890123456789012345678901234567890123456789012345678901234567890123456789012345678901234567890
2823            Ket
2824            End
2825    ------------------------------------------------------------------
2826    Capturing subpattern count = 0
2827    No options
2828    First char = '1'
2829    Need char = '0'
2830    
2831    /\Q\E/DZ
2832    ------------------------------------------------------------------
2833            Bra
2834            Ket
2835            End
2836    ------------------------------------------------------------------
2837    Capturing subpattern count = 0
2838    No options
2839    No first char
2840    No need char
2841        \
2842     0:
2843    
2844    /\Q\Ex/DZ
2845    ------------------------------------------------------------------
2846            Bra
2847            x
2848            Ket
2849            End
2850    ------------------------------------------------------------------
2851    Capturing subpattern count = 0
2852    No options
2853    First char = 'x'
2854    No need char
2855    
2856    / \Q\E/DZ
2857    ------------------------------------------------------------------
2858            Bra
2859    
2860            Ket
2861            End
2862    ------------------------------------------------------------------
2863    Capturing subpattern count = 0
2864    No options
2865    First char = ' '
2866    No need char
2867    
2868    /a\Q\E/DZ
2869    ------------------------------------------------------------------
2870            Bra
2871            a
2872            Ket
2873            End
2874    ------------------------------------------------------------------
2875    Capturing subpattern count = 0
2876    No options
2877    First char = 'a'
2878    No need char
2879      abc
2880     0: a
2881      bca
2882     0: a
2883      bac
2884     0: a
2885    
2886    /a\Q\Eb/DZ
2887    ------------------------------------------------------------------
2888            Bra
2889            ab
2890            Ket
2891            End
2892    ------------------------------------------------------------------
2893    Capturing subpattern count = 0
2894    No options
2895    First char = 'a'
2896    Need char = 'b'
2897      abc
2898     0: ab
2899    
2900    /\Q\Eabc/DZ
2901    ------------------------------------------------------------------
2902            Bra
2903            abc
2904            Ket
2905            End
2906    ------------------------------------------------------------------
2907    Capturing subpattern count = 0
2908    No options
2909    First char = 'a'
2910    Need char = 'c'
2911    
2912    /x*+\w/DZ
2913    ------------------------------------------------------------------
2914            Bra
2915            x*+
2916            \w
2917            Ket
2918            End
2919    ------------------------------------------------------------------
2920    Capturing subpattern count = 0
2921    No options
2922    No first char
2923    No need char
2924        *** Failers
2925     0: F
2926        xxxxx
2927    No match
2928    
2929    /x?+/DZ
2930    ------------------------------------------------------------------
2931            Bra
2932            x?+
2933            Ket
2934            End
2935    ------------------------------------------------------------------
2936    Capturing subpattern count = 0
2937    No options
2938    No first char
2939    No need char
2940    
2941    /x++/DZ
2942    ------------------------------------------------------------------
2943            Bra
2944            x++
2945            Ket
2946            End
2947    ------------------------------------------------------------------
2948    Capturing subpattern count = 0
2949    No options
2950    First char = 'x'
2951    No need char
2952    
2953    /x{1,3}+/DZ
2954    ------------------------------------------------------------------
2955            Bra
2956            Once
2957            x
2958            x{0,2}
2959            Ket
2960            Ket
2961            End
2962    ------------------------------------------------------------------
2963    Capturing subpattern count = 0
2964    No options
2965    First char = 'x'
2966    No need char
2967    
2968    /(x)*+/DZ
2969    ------------------------------------------------------------------
2970            Bra
2971            Once
2972            Brazero
2973            CBra 1
2974            x
2975            KetRmax
2976            Ket
2977            Ket
2978            End
2979    ------------------------------------------------------------------
2980    Capturing subpattern count = 1
2981    No options
2982    No first char
2983    No need char
2984    
2985    /^(\w++|\s++)*$/I
2986    Capturing subpattern count = 1
2987    Options: anchored
2988    No first char
2989    No need char
2990        now is the time for all good men to come to the aid of the party
2991     0: now is the time for all good men to come to the aid of the party
2992     1: party
2993        *** Failers
2994    No match
2995        this is not a line with only words and spaces!
2996    No match
2997    
2998    /(\d++)(\w)/I
2999    Capturing subpattern count = 2
3000    No options
3001    No first char
3002    No need char
3003        12345a
3004     0: 12345a
3005     1: 12345
3006     2: a
3007        *** Failers
3008    No match
3009        12345+
3010    No match
3011    
3012    /a++b/I
3013    Capturing subpattern count = 0
3014    No options
3015    First char = 'a'
3016    Need char = 'b'
3017        aaab
3018     0: aaab
3019    
3020    /(a++b)/I
3021    Capturing subpattern count = 1
3022    No options
3023    First char = 'a'
3024    Need char = 'b'
3025        aaab
3026     0: aaab
3027     1: aaab
3028    
3029    /(a++)b/I
3030    Capturing subpattern count = 1
3031    No options
3032    First char = 'a'
3033    Need char = 'b'
3034        aaab
3035     0: aaab
3036     1: aaa
3037    
3038    /([^()]++|\([^()]*\))+/I
3039    Capturing subpattern count = 1
3040    No options
3041    No first char
3042    No need char
3043        ((abc(ade)ufh()()x
3044     0: abc(ade)ufh()()x
3045     1: x
3046    
3047    /\(([^()]++|\([^()]+\))+\)/I
3048    Capturing subpattern count = 1
3049    No options
3050    First char = '('
3051    Need char = ')'
3052        (abc)
3053     0: (abc)
3054     1: abc
3055        (abc(def)xyz)
3056     0: (abc(def)xyz)
3057     1: xyz
3058        *** Failers
3059    No match
3060        ((()aaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaa
3061    No match
3062    
3063    /(abc){1,3}+/DZ
3064    ------------------------------------------------------------------
3065            Bra
3066            Once
3067            CBra 1
3068            abc
3069            Ket
3070            Brazero
3071            Bra
3072            CBra 1
3073            abc
3074            Ket
3075            Brazero
3076            CBra 1
3077            abc
3078            Ket
3079            Ket
3080            Ket
3081            Ket
3082            End
3083    ------------------------------------------------------------------
3084    Capturing subpattern count = 1
3085    No options
3086    First char = 'a'
3087    Need char = 'c'
3088    
3089    /a+?+/I
3090    Failed: nothing to repeat at offset 3
3091    
3092    /a{2,3}?+b/I
3093    Failed: nothing to repeat at offset 7
3094    
3095    /(?U)a+?+/I
3096    Failed: nothing to repeat at offset 7
3097    
3098    /a{2,3}?+b/IU
3099    Failed: nothing to repeat at offset 7
3100    
3101    /x(?U)a++b/DZ
3102    ------------------------------------------------------------------
3103            Bra
3104            x
3105            a++
3106            b
3107            Ket
3108            End
3109    ------------------------------------------------------------------
3110    Capturing subpattern count = 0
3111    No options
3112    First char = 'x'
3113    Need char = 'b'
3114        xaaaab
3115     0: xaaaab
3116    
3117    /(?U)xa++b/DZ
3118    ------------------------------------------------------------------
3119            Bra
3120            x
3121            a++
3122            b
3123            Ket
3124            End
3125    ------------------------------------------------------------------
3126    Capturing subpattern count = 0
3127    Options: ungreedy
3128    First char = 'x'
3129    Need char = 'b'
3130        xaaaab
3131     0: xaaaab
3132    
3133    /^((a+)(?U)([ab]+)(?-U)([bc]+)(\w*))/DZ
3134    ------------------------------------------------------------------
3135            Bra
3136            ^
3137            CBra 1
3138            CBra 2
3139            a+
3140            Ket
3141            CBra 3
3142            [ab]+?
3143            Ket
3144            CBra 4
3145            [bc]+
3146            Ket
3147            CBra 5
3148            \w*
3149            Ket
3150            Ket
3151            Ket
3152            End
3153    ------------------------------------------------------------------
3154    Capturing subpattern count = 5
3155    Options: anchored
3156    No first char
3157    No need char
3158    
3159    /^x(?U)a+b/DZ
3160    ------------------------------------------------------------------
3161            Bra
3162            ^
3163            x
3164            a++
3165            b
3166            Ket
3167            End
3168    ------------------------------------------------------------------
3169    Capturing subpattern count = 0
3170    Options: anchored
3171    No first char
3172    Need char = 'b'
3173    
3174    /^x(?U)(a+)b/DZ
3175    ------------------------------------------------------------------
3176            Bra
3177            ^
3178            x
3179            CBra 1
3180            a+?
3181            Ket
3182            b
3183            Ket
3184            End
3185    ------------------------------------------------------------------
3186    Capturing subpattern count = 1
3187    Options: anchored
3188    No first char
3189    Need char = 'b'
3190    
3191    /[.x.]/I
3192    Failed: POSIX collating elements are not supported at offset 0
3193    
3194    /[=x=]/I
3195    Failed: POSIX collating elements are not supported at offset 0
3196    
3197    /[:x:]/I
3198    Failed: POSIX named classes are supported only within a class at offset 0
3199    
3200    /\l/I
3201    Failed: PCRE does not support \L, \l, \N, \U, or \u at offset 1
3202    
3203    /\L/I
3204    Failed: PCRE does not support \L, \l, \N, \U, or \u at offset 1
3205    
3206    /\N{name}/I
3207    Failed: PCRE does not support \L, \l, \N, \U, or \u at offset 1
3208    
3209    /\u/I
3210    Failed: PCRE does not support \L, \l, \N, \U, or \u at offset 1
3211    
3212    /\U/I
3213    Failed: PCRE does not support \L, \l, \N, \U, or \u at offset 1
3214    
3215    /[/I
3216    Failed: missing terminating ] for character class at offset 1
3217    
3218    /[a-/I
3219    Failed: missing terminating ] for character class at offset 3
3220    
3221    /[[:space:]/I
3222    Failed: missing terminating ] for character class at offset 10
3223    
3224    /[\s]/IDZ
3225    ------------------------------------------------------------------
3226            Bra
3227            [\x09\x0a\x0c\x0d ]
3228            Ket
3229            End
3230    ------------------------------------------------------------------
3231    Capturing subpattern count = 0
3232    No options
3233    No first char
3234    No need char
3235    
3236    /[[:space:]]/IDZ
3237    ------------------------------------------------------------------
3238            Bra
3239            [\x09-\x0d ]
3240            Ket
3241            End
3242    ------------------------------------------------------------------
3243    Capturing subpattern count = 0
3244    No options
3245    No first char
3246    No need char
3247    
3248    /[[:space:]abcde]/IDZ
3249    ------------------------------------------------------------------
3250            Bra
3251            [\x09-\x0d a-e]
3252            Ket
3253            End
3254    ------------------------------------------------------------------
3255    Capturing subpattern count = 0
3256    No options
3257    No first char
3258    No need char
3259    
3260    /< (?: (?(R) \d++  | [^<>]*+) | (?R)) * >/Ix
3261    Capturing subpattern count = 0
3262    Options: extended
3263    First char = '<'
3264    Need char = '>'
3265        <>
3266     0: <>
3267        <abcd>
3268     0: <abcd>
3269        <abc <123> hij>
3270     0: <abc <123> hij>
3271        <abc <def> hij>
3272     0: <def>
3273        <abc<>def>
3274     0: <abc<>def>
3275        <abc<>
3276     0: <>
3277        *** Failers
3278    No match
3279        <abc
3280    No match
3281    
3282    |8J\$WE\<\.rX\+ix\[d1b\!H\#\?vV0vrK\:ZH1\=2M\>iV\;\?aPhFB\<\*vW\@QW\@sO9\}cfZA\-i\'w\%hKd6gt1UJP\,15_\#QY\$M\^Mss_U\/\]\&LK9\[5vQub\^w\[KDD\<EjmhUZ\?\.akp2dF\>qmj\;2\}YWFdYx\.Ap\]hjCPTP\(n28k\+3\;o\&WXqs\/gOXdr\$\:r\'do0\;b4c\(f_Gr\=\"\\4\)\[01T7ajQJvL\$W\~mL_sS\/4h\:x\*\[ZN\=KLs\&L5zX\/\/\>it\,o\:aU\(\;Z\>pW\&T7oP\'2K\^E\:x9\'c\[\%z\-\,64JQ5AeH_G\#KijUKghQw\^\\vea3a\?kka_G\$8\#\`\*kynsxzBLru\'\]k_\[7FrVx\}\^\=\$blx\>s\-N\%j\;D\*aZDnsw\:YKZ\%Q\.Kne9\#hP\?\+b3\(SOvL\,\^\;\&u5\@\?5C5Bhb\=m\-vEh_L15Jl\]U\)0RP6\{q\%L\^_z5E\'Dw6X\b|IDZ
3283    ------------------------------------------------------------------
3284            Bra
3285            8J$WE<.rX+ix[d1b!H#?vV0vrK:ZH1=2M>iV;?aPhFB<*vW@QW@sO9}cfZA-i'w%hKd6gt1UJP,15_#QY$M^Mss_U/]&LK9[5vQub^w[KDD<EjmhUZ?.akp2dF>qmj;2}YWFdYx.Ap]hjCPTP(n28k+3;o&WXqs/gOXdr$:r'do0;b4c(f_Gr="\4)[01T7ajQJvL$W~mL_sS/4h:x*[ZN=KLs&L5zX//>it,o:aU(;Z>pW&T7oP'2K^E:x9'c[%z-,64JQ5AeH_G#KijUKghQw^\vea3a?kka_G$8#`*kynsxzBLru']k_[7FrVx}^=$blx>s-N%j;D*aZDnsw:YKZ%Q.Kne9#hP?+b3(SOvL,^;&u5@?5C5Bhb=m-vEh_L15Jl]U)0RP6{q%L^_z5E'Dw6X
3286            \b
3287            Ket
3288            End
3289    ------------------------------------------------------------------
3290    Capturing subpattern count = 0
3291    No options
3292    First char = '8'
3293    Need char = 'X'
3294    
3295    |\$\<\.X\+ix\[d1b\!H\#\?vV0vrK\:ZH1\=2M\>iV\;\?aPhFB\<\*vW\@QW\@sO9\}cfZA\-i\'w\%hKd6gt1UJP\,15_\#QY\$M\^Mss_U\/\]\&LK9\[5vQub\^w\[KDD\<EjmhUZ\?\.akp2dF\>qmj\;2\}YWFdYx\.Ap\]hjCPTP\(n28k\+3\;o\&WXqs\/gOXdr\$\:r\'do0\;b4c\(f_Gr\=\"\\4\)\[01T7ajQJvL\$W\~mL_sS\/4h\:x\*\[ZN\=KLs\&L5zX\/\/\>it\,o\:aU\(\;Z\>pW\&T7oP\'2K\^E\:x9\'c\[\%z\-\,64JQ5AeH_G\#KijUKghQw\^\\vea3a\?kka_G\$8\#\`\*kynsxzBLru\'\]k_\[7FrVx\}\^\=\$blx\>s\-N\%j\;D\*aZDnsw\:YKZ\%Q\.Kne9\#hP\?\+b3\(SOvL\,\^\;\&u5\@\?5C5Bhb\=m\-vEh_L15Jl\]U\)0RP6\{q\%L\^_z5E\'Dw6X\b|IDZ
3296    ------------------------------------------------------------------
3297            Bra
3298            $<.X+ix[d1b!H#?vV0vrK:ZH1=2M>iV;?aPhFB<*vW@QW@sO9}cfZA-i'w%hKd6gt1UJP,15_#QY$M^Mss_U/]&LK9[5vQub^w[KDD<EjmhUZ?.akp2dF>qmj;2}YWFdYx.Ap]hjCPTP(n28k+3;o&WXqs/gOXdr$:r'do0;b4c(f_Gr="\4)[01T7ajQJvL$W~mL_sS/4h:x*[ZN=KLs&L5zX//>it,o:aU(;Z>pW&T7oP'2K^E:x9'c[%z-,64JQ5AeH_G#KijUKghQw^\vea3a?kka_G$8#`*kynsxzBLru']k_[7FrVx}^=$blx>s-N%j;D*aZDnsw:YKZ%Q.Kne9#hP?+b3(SOvL,^;&u5@?5C5Bhb=m-vEh_L15Jl]U)0RP6{q%L^_z5E'Dw6X
3299            \b
3300            Ket
3301            End
3302    ------------------------------------------------------------------
3303    Capturing subpattern count = 0
3304    No options
3305    First char = '$'
3306    Need char = 'X'
3307    
3308    /(.*)\d+\1/I
3309    Capturing subpattern count = 1
3310    Max back reference = 1
3311    No options
3312    No first char
3313    No need char
3314    
3315    /(.*)\d+/I
3316    Capturing subpattern count = 1
3317    No options
3318    First char at start or follows newline
3319    No need char
3320    
3321    /(.*)\d+\1/Is
3322    Capturing subpattern count = 1
3323    Max back reference = 1
3324    Options: dotall
3325    No first char
3326    No need char
3327    
3328    /(.*)\d+/Is
3329    Capturing subpattern count = 1
3330    Options: anchored dotall
3331    No first char
3332    No need char
3333    
3334    /(.*(xyz))\d+\2/I
3335    Capturing subpattern count = 2
3336    Max back reference = 2
3337    No options
3338    First char at start or follows newline
3339    Need char = 'z'
3340    
3341    /((.*))\d+\1/I
3342    Capturing subpattern count = 2
3343    Max back reference = 1
3344    No options
3345    No first char
3346    No need char
3347        abc123bc
3348     0: bc123bc
3349     1: bc
3350     2: bc
3351    
3352    /a[b]/I
3353    Capturing subpattern count = 0
3354    No options
3355    First char = 'a'
3356    Need char = 'b'
3357    
3358    /(?=a).*/I
3359    Capturing subpattern count = 0
3360    No options
3361    First char = 'a'
3362    No need char
3363    
3364    /(?=abc).xyz/IiI
3365    Capturing subpattern count = 0
3366    Options: caseless
3367    First char = 'a' (caseless)
3368    Need char = 'z' (caseless)
3369    
3370    /(?=abc)(?i).xyz/I
3371    Capturing subpattern count = 0
3372    No options
3373    First char = 'a'
3374    Need char = 'z' (caseless)
3375    
3376    /(?=a)(?=b)/I
3377    Capturing subpattern count = 0
3378    No options
3379    First char = 'a'
3380    No need char
3381    
3382    /(?=.)a/I
3383    Capturing subpattern count = 0
3384    No options
3385    First char = 'a'
3386    No need char
3387    
3388    /((?=abcda)a)/I
3389    Capturing subpattern count = 1
3390    No options
3391    First char = 'a'
3392    Need char = 'a'
3393    
3394    /((?=abcda)ab)/I
3395    Capturing subpattern count = 1
3396    No options
3397    First char = 'a'
3398    Need char = 'b'
3399    
3400    /()a/I
3401    Capturing subpattern count = 1
3402    No options
3403    No first char
3404    Need char = 'a'
3405    
3406    /(?(1)ab|ac)(.)/I
3407    Capturing subpattern count = 1
3408    No options
3409    First char = 'a'
3410    No need char
3411    
3412    /(?(1)abz|acz)(.)/I
3413    Capturing subpattern count = 1
3414    No options
3415    First char = 'a'
3416    Need char = 'z'
3417    
3418    /(?(1)abz)(.)/I
3419    Capturing subpattern count = 1
3420    No options
3421    No first char
3422    No need char
3423    
3424    /(?(1)abz)(1)23/I
3425    Capturing subpattern count = 1
3426    No options
3427    No first char
3428    Need char = '3'
3429    
3430    /(a)+/I
3431    Capturing subpattern count = 1
3432    No options
3433    First char = 'a'
3434    No need char
3435    
3436    /(a){2,3}/I
3437    Capturing subpattern count = 1
3438    No options
3439    First char = 'a'
3440    Need char = 'a'
3441    
3442    /(a)*/I
3443    Capturing subpattern count = 1
3444    No options
3445    No first char
3446    No need char
3447    
3448    /[a]/I
3449    Capturing subpattern count = 0
3450    No options
3451    First char = 'a'
3452    No need char
3453    
3454    /[ab]/I
3455    Capturing subpattern count = 0
3456    No options
3457    No first char
3458    No need char
3459    
3460    /[ab]/IS
3461    Capturing subpattern count = 0
3462    No options
3463    No first char
3464    No need char
3465    Subject length lower bound = 1
3466    Starting byte set: a b
3467    
3468    /[^a]/I
3469    Capturing subpattern count = 0
3470    No options
3471    No first char
3472    No need char
3473    
3474    /\d456/I
3475    Capturing subpattern count = 0
3476    No options
3477    No first char
3478    Need char = '6'
3479    
3480    /\d456/IS
3481    Capturing subpattern count = 0
3482    No options
3483    No first char
3484    Need char = '6'
3485    Subject length lower bound = 4
3486    Starting byte set: 0 1 2 3 4 5 6 7 8 9
3487    
3488    /a^b/I
3489    Capturing subpattern count = 0
3490    No options
3491    First char = 'a'
3492    Need char = 'b'
3493    
3494    /^a/Im
3495    Capturing subpattern count = 0
3496    Options: multiline
3497    First char at start or follows newline
3498    Need char = 'a'
3499      abcde
3500     0: a
3501      xy\nabc
3502     0: a
3503      *** Failers
3504    No match
3505      xyabc
3506    No match
3507    
3508    /c|abc/I
3509    Capturing subpattern count = 0
3510    No options
3511    No first char
3512    Need char = 'c'
3513    
3514    /(?i)[ab]/IS
3515    Capturing subpattern count = 0
3516    Options: caseless
3517    No first char
3518    No need char
3519    Subject length lower bound = 1
3520    Starting byte set: A B a b
3521    
3522    /[ab](?i)cd/IS
3523    Capturing subpattern count = 0
3524    No options
3525    No first char
3526    Need char = 'd' (caseless)
3527    Subject length lower bound = 3
3528    Starting byte set: a b
3529    
3530    /abc(?C)def/I
3531    Capturing subpattern count = 0
3532    No options
3533    First char = 'a'
3534    Need char = 'f'
3535        abcdef
3536    --->abcdef
3537      0 ^  ^       d
3538     0: abcdef
3539        1234abcdef
3540    --->1234abcdef
3541      0     ^  ^       d
3542     0: abcdef
3543        *** Failers
3544    No match
3545        abcxyz
3546    No match
3547        abcxyzf
3548    --->abcxyzf
3549      0 ^  ^        d
3550    No match
3551    
3552    /abc(?C)de(?C1)f/I
3553    Capturing subpattern count = 0
3554    No options
3555    First char = 'a'
3556    Need char = 'f'
3557        123abcdef
3558    --->123abcdef
3559      0    ^  ^       d
3560      1    ^    ^     f
3561     0: abcdef
3562    
3563    /(?C1)\dabc(?C2)def/I
3564    Capturing subpattern count = 0
3565    No options
3566    No first char
3567    Need char = 'f'
3568        1234abcdef
3569    --->1234abcdef
3570      1 ^              \d
3571      1  ^             \d
3572      1   ^            \d
3573      1    ^           \d
3574      2    ^   ^       d
3575     0: 4abcdef
3576        *** Failers
3577    No match
3578        abcdef
3579    --->abcdef
3580      1 ^          \d
3581      1  ^         \d
3582      1   ^        \d
3583      1    ^       \d
3584      1     ^      \d
3585      1      ^     \d
3586    No match
3587    
3588    /(?C255)ab/I
3589    Capturing subpattern count = 0
3590    No options
3591    First char = 'a'
3592    Need char = 'b'
3593    
3594    /(?C256)ab/I
3595    Failed: number after (?C is > 255 at offset 6
3596    
3597    /(?Cab)xx/I
3598    Failed: closing ) for (?C expected at offset 3
3599    
3600    /(?C12vr)x/I
3601    Failed: closing ) for (?C expected at offset 5
3602    
3603    /abc(?C)def/I
3604    Capturing subpattern count = 0
3605    No options
3606    First char = 'a'
3607    Need char = 'f'
3608        *** Failers
3609    No match
3610        \x83\x0\x61bcdef
3611    --->\x83\x00abcdef
3612      0         ^  ^       d
3613     0: abcdef
3614    
3615    /(abc)(?C)de(?C1)f/I
3616    Capturing subpattern count = 1
3617    No options
3618    First char = 'a'
3619    Need char = 'f'
3620        123abcdef
3621    --->123abcdef
3622      0    ^  ^       d
3623      1    ^    ^     f
3624     0: abcdef
3625     1: abc
3626        123abcdef\C+
3627    Callout 0: last capture = 1
3628     0: <unset>
3629     1: abc
3630    --->123abcdef
3631           ^  ^       d
3632    Callout 1: last capture = 1
3633     0: <unset>
3634     1: abc
3635    --->123abcdef
3636           ^    ^     f
3637     0: abcdef
3638     1: abc
3639        123abcdef\C-
3640     0: abcdef
3641     1: abc
3642        *** Failers
3643    No match
3644        123abcdef\C!1
3645    --->123abcdef
3646      0    ^  ^       d
3647      1    ^    ^     f
3648    No match
3649    
3650    /(?C0)(abc(?C1))*/I
3651    Capturing subpattern count = 1
3652    No options
3653    No first char
3654    No need char
3655        abcabcabc
3656    --->abcabcabc
3657      0 ^             (abc(?C1))*
3658      1 ^  ^          )
3659      1 ^     ^       )
3660      1 ^        ^    )
3661     0: abcabcabc
3662     1: abc
3663        abcabc\C!1!3
3664    --->abcabc
3665      0 ^          (abc(?C1))*
3666      1 ^  ^       )
3667      1 ^     ^    )
3668     0: abcabc
3669     1: abc
3670        *** Failers
3671    --->*** Failers
3672      0 ^               (abc(?C1))*
3673     0:
3674        abcabcabc\C!1!3
3675    --->abcabcabc
3676      0 ^             (abc(?C1))*
3677      1 ^  ^          )
3678      1 ^     ^       )
3679      1 ^        ^    )
3680     0: abcabc
3681     1: abc
3682    
3683    /(\d{3}(?C))*/I
3684    Capturing subpattern count = 1
3685    No options
3686    No first char
3687    No need char
3688        123\C+
3689    Callout 0: last capture = -1
3690     0: <unset>
3691    --->123
3692        ^  ^    )
3693     0: 123
3694     1: 123
3695        123456\C+
3696    Callout 0: last capture = -1
3697     0: <unset>
3698    --->123456
3699        ^  ^       )
3700    Callout 0: last capture = 1
3701     0: <unset>
3702     1: 123
3703    --->123456
3704        ^     ^    )
3705     0: 123456
3706     1: 456
3707        123456789\C+
3708    Callout 0: last capture = -1
3709     0: <unset>
3710    --->123456789
3711        ^  ^          )
3712    Callout 0: last capture = 1
3713     0: <unset>
3714     1: 123
3715    --->123456789
3716        ^     ^       )
3717    Callout 0: last capture = 1
3718     0: <unset>
3719     1: 456
3720    --->123456789
3721        ^        ^    )
3722     0: 123456789
3723     1: 789
3724    
3725    /((xyz)(?C)p|(?C1)xyzabc)/I
3726    Capturing subpattern count = 2
3727    No options
3728    First char = 'x'
3729    No need char
3730        xyzabc\C+
3731    Callout 0: last capture = 2
3732     0: <unset>
3733     1: <unset>
3734     2: xyz
3735    --->xyzabc
3736        ^  ^       p
3737    Callout 1: last capture = -1
3738     0: <unset>
3739    --->xyzabc
3740        ^          x
3741     0: xyzabc
3742     1: xyzabc
3743    
3744    /(X)((xyz)(?C)p|(?C1)xyzabc)/I
3745    Capturing subpattern count = 3
3746    No options
3747    First char = 'X'
3748    Need char = 'x'
3749        Xxyzabc\C+
3750    Callout 0: last capture = 3
3751     0: <unset>
3752     1: X
3753     2: <unset>
3754     3: xyz
3755    --->Xxyzabc
3756        ^   ^       p
3757    Callout 1: last capture = 1
3758     0: <unset>
3759     1: X
3760    --->Xxyzabc
3761        ^^          x
3762     0: Xxyzabc
3763     1: X
3764     2: xyzabc
3765    
3766    /(?=(abc))(?C)abcdef/I
3767    Capturing subpattern count = 1
3768    No options
3769    First char = 'a'
3770    Need char = 'f'
3771        abcdef\C+
3772    Callout 0: last capture = 1
3773     0: <unset>
3774     1: abc
3775    --->abcdef
3776        ^          a
3777     0: abcdef
3778     1: abc
3779    
3780    /(?!(abc)(?C1)d)(?C2)abcxyz/I
3781    Capturing subpattern count = 1
3782    No options
3783    First char = 'a'
3784    Need char = 'z'
3785        abcxyz\C+
3786    Callout 1: last capture = 1
3787     0: <unset>
3788     1: abc
3789    --->abcxyz
3790        ^  ^       d
3791    Callout 2: last capture = -1
3792     0: <unset>
3793    --->abcxyz
3794        ^          a
3795     0: abcxyz
3796    
3797    /(?<=(abc)(?C))xyz/I
3798    Capturing subpattern count = 1
3799    No options
3800    First char = 'x'
3801    Need char = 'z'
3802       abcxyz\C+
3803    Callout 0: last capture = 1
3804     0: <unset>
3805     1: abc
3806    --->abcxyz
3807           ^       )
3808     0: xyz
3809     1: abc
3810    
3811    /a(b+)(c*)(?C1)/I
3812    Capturing subpattern count = 2
3813    No options
3814    First char = 'a'
3815    Need char = 'b'
3816        abbbbbccc\C*1
3817    --->abbbbbccc
3818      1 ^        ^
3819    Callout data = 1
3820      1 ^       ^
3821    Callout data = 1
3822      1 ^      ^
3823    Callout data = 1
3824      1 ^     ^
3825    Callout data = 1
3826      1 ^    ^
3827    Callout data = 1
3828      1 ^   ^
3829    Callout data = 1
3830      1 ^  ^
3831    Callout data = 1
3832      1 ^ ^
3833    Callout data = 1
3834    No match
3835    
3836    /a(b+?)(c*?)(?C1)/I
3837    Capturing subpattern count = 2
3838    No options
3839    First char = 'a'
3840    Need char = 'b'
3841        abbbbbccc\C*1
3842    --->abbbbbccc
3843      1 ^ ^
3844    Callout data = 1
3845      1 ^  ^
3846    Callout data = 1
3847      1 ^   ^
3848    Callout data = 1
3849      1 ^    ^
3850    Callout data = 1
3851      1 ^     ^
3852    Callout data = 1
3853      1 ^      ^
3854    Callout data = 1
3855      1 ^       ^
3856    Callout data = 1
3857      1 ^        ^
3858    Callout data = 1
3859    No match
3860    
3861    /(?C)abc/I
3862    Capturing subpattern count = 0
3863    No options
3864    First char = 'a'
3865    Need char = 'c'
3866    
3867    /(?C)^abc/I
3868    Capturing subpattern count = 0
3869    Options: anchored
3870    No first char
3871    No need char
3872    
3873    /(?C)a|b/IS
3874    Capturing subpattern count = 0
3875    No options
3876    No first char
3877    No need char
3878    Subject length lower bound = 1
3879    Starting byte set: a b
3880    
3881    /(?R)/I
3882    Failed: recursive call could loop indefinitely at offset 3
3883    
3884    /(a|(?R))/I
3885    Failed: recursive call could loop indefinitely at offset 6
3886    
3887    /(ab|(bc|(de|(?R))))/I
3888    Failed: recursive call could loop indefinitely at offset 15
3889    
3890    /x(ab|(bc|(de|(?R))))/I
3891    Capturing subpattern count = 3
3892    No options
3893    First char = 'x'
3894    No need char
3895        xab
3896     0: xab
3897     1: ab
3898        xbc
3899     0: xbc
3900     1: bc
3901     2: bc
3902        xde
3903     0: xde
3904     1: de
3905     2: de
3906     3: de
3907        xxab
3908     0: xxab
3909     1: xab
3910     2: xab
3911     3: xab
3912        xxxab
3913     0: xxxab
3914     1: xxab
3915     2: xxab
3916     3: xxab
3917        *** Failers
3918    No match
3919        xyab
3920    No match
3921    
3922    /(ab|(bc|(de|(?1))))/I
3923    Failed: recursive call could loop indefinitely at offset 15
3924    
3925    /x(ab|(bc|(de|(?1)x)x)x)/I
3926    Failed: recursive call could loop indefinitely at offset 16
3927    
3928    /^([^()]|\((?1)*\))*$/I
3929    Capturing subpattern count = 1
3930    Options: anchored
3931    No first char
3932    No need char
3933        abc
3934     0: abc
3935     1: c
3936        a(b)c
3937     0: a(b)c
3938     1: c
3939        a(b(c))d
3940     0: a(b(c))d
3941     1: d
3942        *** Failers)
3943    No match
3944        a(b(c)d
3945    No match
3946    
3947    /^>abc>([^()]|\((?1)*\))*<xyz<$/I
3948    Capturing subpattern count = 1
3949    Options: anchored
3950    No first char
3951    Need char = '<'
3952       >abc>123<xyz<
3953     0: >abc>123<xyz<
3954     1: 3
3955       >abc>1(2)3<xyz<
3956     0: >abc>1(2)3<xyz<
3957     1: 3
3958       >abc>(1(2)3)<xyz<
3959     0: >abc>(1(2)3)<xyz<
3960     1: (1(2)3)
3961    
3962    /(a(?1)b)/DZ
3963    ------------------------------------------------------------------
3964            Bra
3965            CBra 1
3966            a
3967            Once
3968            Recurse
3969            Ket
3970            b
3971            Ket
3972            Ket
3973            End
3974    ------------------------------------------------------------------
3975    Capturing subpattern count = 1
3976    No options
3977    First char = 'a'
3978    Need char = 'b'
3979    
3980    /(a(?1)+b)/DZ
3981    ------------------------------------------------------------------
3982            Bra
3983            CBra 1
3984            a
3985            Once
3986            Recurse
3987            KetRmax
3988            b
3989            Ket
3990            Ket
3991            End
3992    ------------------------------------------------------------------
3993    Capturing subpattern count = 1
3994    No options
3995    First char = 'a'
3996    Need char = 'b'
3997    
3998    /^(\d+|\((?1)([+*-])(?1)\)|-(?1))$/I
3999    Capturing subpattern count = 2
4000    Options: anchored
4001    No first char
4002    No need char
4003        12
4004     0: 12
4005     1: 12
4006        (((2+2)*-3)-7)
4007     0: (((2+2)*-3)-7)
4008     1: (((2+2)*-3)-7)
4009     2: -
4010        -12
4011     0: -12
4012     1: -12
4013        *** Failers
4014    No match
4015        ((2+2)*-3)-7)
4016    No match
4017    
4018    /^(x(y|(?1){2})z)/I
4019    Capturing subpattern count = 2
4020    Options: anchored
4021    No first char
4022    No need char
4023        xyz
4024     0: xyz
4025     1: xyz
4026     2: y
4027        xxyzxyzz
4028     0: xxyzxyzz
4029     1: xxyzxyzz
4030     2: xyzxyz
4031        *** Failers
4032    No match
4033        xxyzz
4034    No match
4035        xxyzxyzxyzz
4036    No match
4037    
4038    /((< (?: (?(R) \d++  | [^<>]*+) | (?2)) * >))/Ix
4039    Capturing subpattern count = 2
4040    Options: extended
4041    First char = '<'
4042    Need char = '>'
4043        <>
4044     0: <>
4045     1: <>
4046     2: <>
4047        <abcd>
4048     0: <abcd>
4049     1: <abcd>
4050     2: <abcd>
4051        <abc <123> hij>
4052     0: <abc <123> hij>
4053     1: <abc <123> hij>
4054     2: <abc <123> hij>
4055        <abc <def> hij>
4056     0: <def>
4057     1: <def>
4058     2: <def>
4059        <abc<>def>
4060     0: <abc<>def>
4061     1: <abc<>def>
4062     2: <abc<>def>
4063        <abc<>
4064     0: <>
4065     1: <>
4066     2: <>
4067        *** Failers
4068    No match
4069        <abc
4070    No match
4071    
4072    /(?1)/I
4073    Failed: reference to non-existent subpattern at offset 3
4074    
4075    /((?2)(abc)/I
4076    Failed: missing ) at offset 10
4077    
4078    /^(abc)def(?1)/I
4079    Capturing subpattern count = 1
4080    Options: anchored
4081    No first char
4082    No need char
4083        abcdefabc
4084     0: abcdefabc
4085     1: abc
4086    
4087    /^(a|b|c)=(?1)+/I
4088    Capturing subpattern count = 1
4089    Options: anchored
4090    No first char
4091    No need char
4092        a=a
4093     0: a=a
4094     1: a