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

Contents of /code/trunk/testdata/testoutput2

Parent Directory Parent Directory | Revision Log Revision Log


Revision 295 - (hide annotations) (download)
Mon Dec 31 17:00:24 2007 UTC (6 years, 10 months ago) by ph10
File size: 190938 byte(s)
Make POSIX character class parsing more like Perl.

1 nigel 93 /(a)b|/I
2 nigel 43 Capturing subpattern count = 1
3 nigel 41 No options
4     No first char
5 nigel 43 No need char
6 nigel 41
7 nigel 93 /abc/I
8 nigel 43 Capturing subpattern count = 0
9 nigel 41 No options
10     First char = 'a'
11 nigel 43 Need char = 'c'
12 nigel 41 abc
13     0: abc
14     defabc
15     0: abc
16     \Aabc
17     0: abc
18     *** Failers
19     No match
20     \Adefabc
21     No match
22     ABC
23     No match
24    
25 nigel 93 /^abc/I
26 nigel 43 Capturing subpattern count = 0
27 nigel 41 Options: anchored
28     No first char
29 nigel 65 No need char
30 nigel 41 abc
31     0: abc
32     \Aabc
33     0: abc
34     *** Failers
35     No match
36     defabc
37     No match
38     \Adefabc
39     No match
40    
41 nigel 93 /a+bc/I
42 nigel 43 Capturing subpattern count = 0
43 nigel 75 Partial matching not supported
44 nigel 41 No options
45     First char = 'a'
46 nigel 43 Need char = 'c'
47 nigel 41
48 nigel 93 /a*bc/I
49 nigel 43 Capturing subpattern count = 0
50 nigel 75 Partial matching not supported
51 nigel 41 No options
52     No first char
53 nigel 43 Need char = 'c'
54 nigel 41
55 nigel 93 /a{3}bc/I
56 nigel 43 Capturing subpattern count = 0
57 nigel 75 Partial matching not supported
58 nigel 41 No options
59     First char = 'a'
60 nigel 43 Need char = 'c'
61 nigel 41
62 nigel 93 /(abc|a+z)/I
63 nigel 43 Capturing subpattern count = 1
64 nigel 75 Partial matching not supported
65 nigel 41 No options
66     First char = 'a'
67 nigel 43 No need char
68 nigel 41
69 nigel 93 /^abc$/I
70 nigel 43 Capturing subpattern count = 0
71 nigel 41 Options: anchored
72     No first char
73 nigel 65 No need char
74 nigel 41 abc
75     0: abc
76     *** Failers
77     No match
78     def\nabc
79     No match
80    
81 ph10 178 /ab\idef/X
82 nigel 41 Failed: unrecognized character follows \ at offset 3
83    
84 ph10 178 /(?X)ab\idef/X
85 nigel 41 Failed: unrecognized character follows \ at offset 7
86    
87     /x{5,4}/
88     Failed: numbers out of order in {} quantifier at offset 5
89    
90     /z{65536}/
91     Failed: number too big in {} quantifier at offset 7
92    
93     /[abcd/
94     Failed: missing terminating ] for character class at offset 5
95    
96 nigel 63 /(?X)[\B]/
97     Failed: invalid escape sequence in character class at offset 6
98 nigel 41
99     /[z-a]/
100     Failed: range out of order in character class at offset 3
101    
102     /^*/
103     Failed: nothing to repeat at offset 1
104    
105     /(abc/
106     Failed: missing ) at offset 4
107    
108     /(?# abc/
109     Failed: missing ) after comment at offset 7
110    
111     /(?z)abc/
112 ph10 269 Failed: unrecognized character after (? or (?- at offset 2
113 nigel 41
114 nigel 93 /.*b/I
115 nigel 43 Capturing subpattern count = 0
116 nigel 75 Partial matching not supported
117 nigel 41 No options
118 nigel 91 First char at start or follows newline
119 nigel 43 Need char = 'b'
120 nigel 41
121 nigel 93 /.*?b/I
122 nigel 43 Capturing subpattern count = 0
123 nigel 75 Partial matching not supported
124 nigel 41 No options
125 nigel 91 First char at start or follows newline
126 nigel 43 Need char = 'b'
127 nigel 41
128 nigel 93 /cat|dog|elephant/I
129 nigel 43 Capturing subpattern count = 0
130 nigel 41 No options
131     No first char
132 nigel 43 No need char
133 nigel 41 this sentence eventually mentions a cat
134     0: cat
135     this sentences rambles on and on for a while and then reaches elephant
136     0: elephant
137    
138 nigel 93 /cat|dog|elephant/IS
139 nigel 43 Capturing subpattern count = 0
140 nigel 41 No options
141     No first char
142 nigel 43 No need char
143 nigel 75 Starting byte set: c d e
144 nigel 41 this sentence eventually mentions a cat
145     0: cat
146     this sentences rambles on and on for a while and then reaches elephant
147     0: elephant
148    
149 nigel 93 /cat|dog|elephant/IiS
150 nigel 43 Capturing subpattern count = 0
151 nigel 41 Options: caseless
152     No first char
153 nigel 43 No need char
154 nigel 75 Starting byte set: C D E c d e
155 nigel 41 this sentence eventually mentions a CAT cat
156     0: CAT
157     this sentences rambles on and on for a while to elephant ElePhant
158     0: elephant
159    
160 nigel 93 /a|[bcd]/IS
161 nigel 43 Capturing subpattern count = 0
162 nigel 41 No options
163     No first char
164 nigel 43 No need char
165 nigel 75 Starting byte set: a b c d
166 nigel 41
167 nigel 93 /(a|[^\dZ])/IS
168 nigel 43 Capturing subpattern count = 1
169 nigel 41 No options
170     No first char
171 nigel 43 No need char
172 nigel 75 Starting byte set: \x00 \x01 \x02 \x03 \x04 \x05 \x06 \x07 \x08 \x09 \x0a
173 nigel 41 \x0b \x0c \x0d \x0e \x0f \x10 \x11 \x12 \x13 \x14 \x15 \x16 \x17 \x18 \x19
174     \x1a \x1b \x1c \x1d \x1e \x1f \x20 ! " # $ % & ' ( ) * + , - . / : ; < = >
175     ? @ 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
176     e f g h i j k l m n o p q r s t u v w x y z { | } ~ \x7f \x80 \x81 \x82 \x83
177     \x84 \x85 \x86 \x87 \x88 \x89 \x8a \x8b \x8c \x8d \x8e \x8f \x90 \x91 \x92
178     \x93 \x94 \x95 \x96 \x97 \x98 \x99 \x9a \x9b \x9c \x9d \x9e \x9f \xa0 \xa1
179     \xa2 \xa3 \xa4 \xa5 \xa6 \xa7 \xa8 \xa9 \xaa \xab \xac \xad \xae \xaf \xb0
180     \xb1 \xb2 \xb3 \xb4 \xb5 \xb6 \xb7 \xb8 \xb9 \xba \xbb \xbc \xbd \xbe \xbf
181     \xc0 \xc1 \xc2 \xc3 \xc4 \xc5 \xc6 \xc7 \xc8 \xc9 \xca \xcb \xcc \xcd \xce
182     \xcf \xd0 \xd1 \xd2 \xd3 \xd4 \xd5 \xd6 \xd7 \xd8 \xd9 \xda \xdb \xdc \xdd
183     \xde \xdf \xe0 \xe1 \xe2 \xe3 \xe4 \xe5 \xe6 \xe7 \xe8 \xe9 \xea \xeb \xec
184     \xed \xee \xef \xf0 \xf1 \xf2 \xf3 \xf4 \xf5 \xf6 \xf7 \xf8 \xf9 \xfa \xfb
185     \xfc \xfd \xfe \xff
186    
187 nigel 93 /(a|b)*[\s]/IS
188 nigel 43 Capturing subpattern count = 1
189 nigel 41 No options
190     No first char
191 nigel 43 No need char
192 nigel 75 Starting byte set: \x09 \x0a \x0c \x0d \x20 a b
193 nigel 41
194     /(ab\2)/
195 nigel 63 Failed: reference to non-existent subpattern at offset 6
196 nigel 41
197     /{4,5}abc/
198     Failed: nothing to repeat at offset 4
199    
200 nigel 93 /(a)(b)(c)\2/I
201 nigel 43 Capturing subpattern count = 3
202     Max back reference = 2
203 nigel 41 No options
204     First char = 'a'
205 nigel 43 Need char = 'c'
206 nigel 41 abcb
207     0: abcb
208     1: a
209     2: b
210     3: c
211     \O0abcb
212     Matched, but too many substrings
213     \O3abcb
214     Matched, but too many substrings
215     0: abcb
216     \O6abcb
217     Matched, but too many substrings
218     0: abcb
219     1: a
220     \O9abcb
221     Matched, but too many substrings
222     0: abcb
223     1: a
224     2: b
225 ph10 102 \O12abcb
226 nigel 41 0: abcb
227     1: a
228     2: b
229     3: c
230    
231 nigel 93 /(a)bc|(a)(b)\2/I
232 nigel 43 Capturing subpattern count = 3
233     Max back reference = 2
234 nigel 41 No options
235     First char = 'a'
236 nigel 43 No need char
237 nigel 41 abc
238     0: abc
239     1: a
240     \O0abc
241     Matched, but too many substrings
242     \O3abc
243     Matched, but too many substrings
244     0: abc
245     \O6abc
246     0: abc
247     1: a
248     aba
249     0: aba
250     1: <unset>
251     2: a
252     3: b
253     \O0aba
254     Matched, but too many substrings
255     \O3aba
256     Matched, but too many substrings
257     0: aba
258     \O6aba
259     Matched, but too many substrings
260     0: aba
261     1: <unset>
262     \O9aba
263     Matched, but too many substrings
264     0: aba
265     1: <unset>
266     2: a
267     \O12aba
268     0: aba
269     1: <unset>
270     2: a
271     3: b
272    
273 nigel 93 /abc$/IE
274 nigel 43 Capturing subpattern count = 0
275 nigel 41 Options: dollar_endonly
276     First char = 'a'
277 nigel 43 Need char = 'c'
278 nigel 41 abc
279     0: abc
280     *** Failers
281     No match
282     abc\n
283     No match
284     abc\ndef
285     No match
286    
287     /(a)(b)(c)(d)(e)\6/
288 nigel 63 Failed: reference to non-existent subpattern at offset 17
289 nigel 41
290 nigel 93 /the quick brown fox/I
291 nigel 43 Capturing subpattern count = 0
292 nigel 41 No options
293     First char = 't'
294 nigel 43 Need char = 'x'
295 nigel 41 the quick brown fox
296     0: the quick brown fox
297     this is a line with the quick brown fox
298     0: the quick brown fox
299    
300 nigel 93 /the quick brown fox/IA
301 nigel 43 Capturing subpattern count = 0
302 nigel 41 Options: anchored
303     No first char
304 nigel 65 No need char
305 nigel 41 the quick brown fox
306     0: the quick brown fox
307     *** Failers
308     No match
309     this is a line with the quick brown fox
310     No match
311    
312     /ab(?z)cd/
313 ph10 269 Failed: unrecognized character after (? or (?- at offset 4
314 nigel 41
315 nigel 93 /^abc|def/I
316 nigel 43 Capturing subpattern count = 0
317 nigel 41 No options
318     No first char
319 nigel 43 No need char
320 nigel 41 abcdef
321     0: abc
322     abcdef\B
323     0: def
324    
325 nigel 93 /.*((abc)$|(def))/I
326 nigel 43 Capturing subpattern count = 3
327 nigel 75 Partial matching not supported
328 nigel 41 No options
329 nigel 91 First char at start or follows newline
330 nigel 43 No need char
331 nigel 41 defabc
332     0: defabc
333     1: abc
334     2: abc
335     \Zdefabc
336     0: def
337     1: def
338     2: <unset>
339     3: def
340    
341 nigel 93 /abc/IP
342 nigel 41 abc
343     0: abc
344     *** Failers
345     No match: POSIX code 17: match failed
346 ph10 102
347 nigel 93 /^abc|def/IP
348 nigel 41 abcdef
349     0: abc
350     abcdef\B
351     0: def
352    
353 nigel 93 /.*((abc)$|(def))/IP
354 nigel 41 defabc
355     0: defabc
356     1: abc
357     2: abc
358     \Zdefabc
359     0: def
360     1: def
361     3: def
362 ph10 102
363 nigel 93 /the quick brown fox/IP
364 nigel 41 the quick brown fox
365     0: the quick brown fox
366 ph10 102 *** Failers
367 nigel 41 No match: POSIX code 17: match failed
368 ph10 102 The Quick Brown Fox
369 nigel 41 No match: POSIX code 17: match failed
370    
371 nigel 93 /the quick brown fox/IPi
372 nigel 41 the quick brown fox
373     0: the quick brown fox
374 ph10 102 The Quick Brown Fox
375 nigel 41 0: The Quick Brown Fox
376    
377 nigel 93 /abc.def/IP
378 nigel 41 *** Failers
379     No match: POSIX code 17: match failed
380     abc\ndef
381     No match: POSIX code 17: match failed
382 ph10 102
383 nigel 93 /abc$/IP
384 nigel 41 abc
385     0: abc
386 ph10 102 abc\n
387 nigel 41 0: abc
388    
389 nigel 93 /(abc)\2/IP
390 nigel 41 Failed: POSIX code 15: bad back reference at offset 7
391    
392 nigel 93 /(abc\1)/IP
393 nigel 41 abc
394     No match: POSIX code 17: match failed
395    
396     /)/
397     Failed: unmatched parentheses at offset 0
398    
399     /a[]b/
400     Failed: missing terminating ] for character class at offset 4
401    
402 nigel 93 /[^aeiou ]{3,}/I
403 nigel 43 Capturing subpattern count = 0
404 nigel 75 Partial matching not supported
405 nigel 41 No options
406     No first char
407 nigel 43 No need char
408 ph10 102 co-processors, and for
409 nigel 41 0: -pr
410 ph10 102
411 nigel 93 /<.*>/I
412 nigel 43 Capturing subpattern count = 0
413 nigel 75 Partial matching not supported
414 nigel 41 No options
415     First char = '<'
416 nigel 43 Need char = '>'
417 nigel 41 abc<def>ghi<klm>nop
418     0: <def>ghi<klm>
419    
420 nigel 93 /<.*?>/I
421 nigel 43 Capturing subpattern count = 0
422 nigel 75 Partial matching not supported
423 nigel 41 No options
424     First char = '<'
425 nigel 43 Need char = '>'
426 nigel 41 abc<def>ghi<klm>nop
427     0: <def>
428    
429 nigel 93 /<.*>/IU
430 nigel 43 Capturing subpattern count = 0
431 nigel 75 Partial matching not supported
432 nigel 41 Options: ungreedy
433     First char = '<'
434 nigel 43 Need char = '>'
435 nigel 41 abc<def>ghi<klm>nop
436     0: <def>
437 ph10 102
438 nigel 93 /(?U)<.*>/I
439 nigel 43 Capturing subpattern count = 0
440 nigel 75 Partial matching not supported
441 nigel 41 Options: ungreedy
442     First char = '<'
443 nigel 43 Need char = '>'
444 nigel 41 abc<def>ghi<klm>nop
445     0: <def>
446    
447 nigel 93 /<.*?>/IU
448 nigel 43 Capturing subpattern count = 0
449 nigel 75 Partial matching not supported
450 nigel 41 Options: ungreedy
451     First char = '<'
452 nigel 43 Need char = '>'
453 nigel 41 abc<def>ghi<klm>nop
454     0: <def>ghi<klm>
455 ph10 102
456 nigel 93 /={3,}/IU
457 nigel 43 Capturing subpattern count = 0
458 nigel 75 Partial matching not supported
459 nigel 41 Options: ungreedy
460     First char = '='
461 nigel 43 Need char = '='
462 nigel 41 abc========def
463     0: ===
464 ph10 102
465 nigel 93 /(?U)={3,}?/I
466 nigel 43 Capturing subpattern count = 0
467 nigel 75 Partial matching not supported
468 nigel 41 Options: ungreedy
469     First char = '='
470 nigel 43 Need char = '='
471 nigel 41 abc========def
472     0: ========
473 ph10 102
474 nigel 93 /(?<!bar|cattle)foo/I
475 nigel 43 Capturing subpattern count = 0
476 nigel 41 No options
477     First char = 'f'
478 nigel 43 Need char = 'o'
479 nigel 41 foo
480     0: foo
481 ph10 102 catfoo
482 nigel 41 0: foo
483     *** Failers
484     No match
485     the barfoo
486     No match
487 ph10 102 and cattlefoo
488 nigel 41 No match
489    
490     /(?<=a+)b/
491     Failed: lookbehind assertion is not fixed length at offset 6
492    
493     /(?<=aaa|b{0,3})b/
494     Failed: lookbehind assertion is not fixed length at offset 14
495    
496     /(?<!(foo)a\1)bar/
497     Failed: lookbehind assertion is not fixed length at offset 12
498    
499 nigel 93 /(?i)abc/I
500 nigel 43 Capturing subpattern count = 0
501 nigel 41 Options: caseless
502 nigel 63 First char = 'a' (caseless)
503     Need char = 'c' (caseless)
504 nigel 41
505 nigel 93 /(a|(?m)a)/I
506 nigel 43 Capturing subpattern count = 1
507 nigel 41 No options
508     First char = 'a'
509 nigel 43 No need char
510 nigel 41
511 nigel 93 /(?i)^1234/I
512 nigel 43 Capturing subpattern count = 0
513 nigel 41 Options: anchored caseless
514     No first char
515 nigel 65 No need char
516 nigel 41
517 nigel 93 /(^b|(?i)^d)/I
518 nigel 43 Capturing subpattern count = 1
519 nigel 41 Options: anchored
520     No first char
521 nigel 43 No need char
522 nigel 41
523 nigel 93 /(?s).*/I
524 nigel 43 Capturing subpattern count = 0
525 nigel 75 Partial matching not supported
526 nigel 41 Options: anchored dotall
527     No first char
528 nigel 43 No need char
529 nigel 41
530 nigel 93 /[abcd]/IS
531 nigel 43 Capturing subpattern count = 0
532 nigel 41 No options
533     No first char
534 nigel 43 No need char
535 nigel 75 Starting byte set: a b c d
536 nigel 41
537 nigel 93 /(?i)[abcd]/IS
538 nigel 43 Capturing subpattern count = 0
539 nigel 41 Options: caseless
540     No first char
541 nigel 43 No need char
542 nigel 75 Starting byte set: A B C D a b c d
543 nigel 41
544 nigel 93 /(?m)[xy]|(b|c)/IS
545 nigel 43 Capturing subpattern count = 1
546 nigel 41 Options: multiline
547     No first char
548 nigel 43 No need char
549 nigel 75 Starting byte set: b c x y
550 nigel 41
551 nigel 93 /(^a|^b)/Im
552 nigel 43 Capturing subpattern count = 1
553 nigel 41 Options: multiline
554 nigel 91 First char at start or follows newline
555 nigel 43 No need char
556 nigel 41
557 nigel 93 /(?i)(^a|^b)/Im
558 nigel 43 Capturing subpattern count = 1
559 nigel 41 Options: caseless multiline
560 nigel 91 First char at start or follows newline
561 nigel 43 No need char
562 nigel 41
563     /(a)(?(1)a|b|c)/
564     Failed: conditional group contains more than two branches at offset 13
565    
566     /(?(?=a)a|b|c)/
567     Failed: conditional group contains more than two branches at offset 12
568    
569     /(?(1a)/
570 nigel 93 Failed: missing ) at offset 6
571    
572     /(?(1a))/
573 nigel 91 Failed: reference to non-existent subpattern at offset 6
574 nigel 41
575     /(?(?i))/
576     Failed: assertion expected after (?( at offset 3
577    
578     /(?(abc))/
579 nigel 91 Failed: reference to non-existent subpattern at offset 7
580 nigel 41
581     /(?(?<ab))/
582 nigel 93 Failed: syntax error in subpattern name (missing terminator) at offset 7
583 nigel 41
584 nigel 93 /((?s)blah)\s+\1/I
585 nigel 43 Capturing subpattern count = 1
586     Max back reference = 1
587 nigel 75 Partial matching not supported
588 nigel 41 No options
589     First char = 'b'
590 nigel 43 Need char = 'h'
591 nigel 41
592 nigel 93 /((?i)blah)\s+\1/I
593 nigel 43 Capturing subpattern count = 1
594     Max back reference = 1
595 nigel 75 Partial matching not supported
596 nigel 41 No options
597 nigel 63 First char = 'b' (caseless)
598     Need char = 'h' (caseless)
599 nigel 41
600 ph10 161 /((?i)b)/IDZS
601 nigel 41 ------------------------------------------------------------------
602 ph10 192 Bra
603     CBra 1
604 ph10 161 01 Opt
605     NC b
606     Ket
607     00 Opt
608     Ket
609     End
610 nigel 41 ------------------------------------------------------------------
611 nigel 43 Capturing subpattern count = 1
612 nigel 41 No options
613 nigel 63 First char = 'b' (caseless)
614     No need char
615     Study returned NULL
616 nigel 41
617 nigel 93 /(a*b|(?i:c*(?-i)d))/IS
618 nigel 43 Capturing subpattern count = 1
619 nigel 75 Partial matching not supported
620 nigel 41 No options
621     No first char
622 nigel 43 No need char
623 nigel 75 Starting byte set: C a b c d
624 nigel 41
625 nigel 93 /a$/I
626 nigel 43 Capturing subpattern count = 0
627 nigel 41 No options
628     First char = 'a'
629 nigel 43 No need char
630 nigel 41 a
631     0: a
632     a\n
633     0: a
634 ph10 102 *** Failers
635 nigel 41 No match
636     \Za
637     No match
638 ph10 102 \Za\n
639 nigel 41 No match
640    
641 nigel 93 /a$/Im
642 nigel 43 Capturing subpattern count = 0
643 nigel 41 Options: multiline
644     First char = 'a'
645 nigel 43 No need char
646 nigel 41 a
647     0: a
648     a\n
649     0: a
650 ph10 102 \Za\n
651 nigel 41 0: a
652 ph10 102 *** Failers
653 nigel 41 No match
654     \Za
655     No match
656 ph10 102
657 nigel 93 /\Aabc/Im
658 nigel 43 Capturing subpattern count = 0
659 nigel 41 Options: anchored multiline
660     No first char
661 nigel 65 No need char
662 nigel 41
663 ph10 102 /^abc/Im
664 nigel 43 Capturing subpattern count = 0
665 nigel 41 Options: multiline
666 nigel 91 First char at start or follows newline
667 nigel 43 Need char = 'c'
668 nigel 41
669 nigel 93 /^((a+)(?U)([ab]+)(?-U)([bc]+)(\w*))/I
670 nigel 43 Capturing subpattern count = 5
671 nigel 75 Partial matching not supported
672 nigel 41 Options: anchored
673     No first char
674 nigel 65 No need char
675 nigel 41 aaaaabbbbbcccccdef
676     0: aaaaabbbbbcccccdef
677     1: aaaaabbbbbcccccdef
678     2: aaaaa
679     3: b
680     4: bbbbccccc
681     5: def
682    
683 nigel 93 /(?<=foo)[ab]/IS
684 nigel 43 Capturing subpattern count = 0
685 nigel 41 No options
686     No first char
687 nigel 43 No need char
688 nigel 75 Starting byte set: a b
689 nigel 41
690 nigel 93 /(?<!foo)(alpha|omega)/IS
691 nigel 43 Capturing subpattern count = 1
692 nigel 41 No options
693     No first char
694 nigel 43 Need char = 'a'
695 nigel 75 Starting byte set: a o
696 nigel 41
697 nigel 93 /(?!alphabet)[ab]/IS
698 nigel 43 Capturing subpattern count = 0
699 nigel 41 No options
700     No first char
701 nigel 43 No need char
702 nigel 75 Starting byte set: a b
703 nigel 41
704 nigel 93 /(?<=foo\n)^bar/Im
705 nigel 43 Capturing subpattern count = 0
706 ph10 226 Contains explicit CR or LF match
707 nigel 41 Options: multiline
708 nigel 75 No first char
709     Need char = 'r'
710 ph10 102 foo\nbarbar
711 nigel 75 0: bar
712     ***Failers
713     No match
714 ph10 102 rhubarb
715 nigel 75 No match
716     barbell
717     No match
718 ph10 102 abc\nbarton
719 nigel 75 No match
720    
721 nigel 93 /^(?<=foo\n)bar/Im
722 nigel 75 Capturing subpattern count = 0
723 ph10 226 Contains explicit CR or LF match
724 nigel 75 Options: multiline
725 nigel 91 First char at start or follows newline
726 nigel 43 Need char = 'r'
727 ph10 102 foo\nbarbar
728 nigel 75 0: bar
729     ***Failers
730     No match
731 ph10 102 rhubarb
732 nigel 75 No match
733     barbell
734     No match
735 ph10 102 abc\nbarton
736 nigel 75 No match
737 nigel 41
738 nigel 93 /(?>^abc)/Im
739 nigel 43 Capturing subpattern count = 0
740 nigel 41 Options: multiline
741 nigel 91 First char at start or follows newline
742 nigel 43 Need char = 'c'
743 nigel 41 abc
744     0: abc
745     def\nabc
746     0: abc
747     *** Failers
748     No match
749 ph10 102 defabc
750 nigel 41 No match
751    
752     /(?<=ab(c+)d)ef/
753     Failed: lookbehind assertion is not fixed length at offset 11
754    
755     /(?<=ab(?<=c+)d)ef/
756     Failed: lookbehind assertion is not fixed length at offset 12
757    
758     /(?<=ab(c|de)f)g/
759     Failed: lookbehind assertion is not fixed length at offset 13
760    
761     /The next three are in testinput2 because they have variable length branches/
762    
763 nigel 93 /(?<=bullock|donkey)-cart/I
764 nigel 43 Capturing subpattern count = 0
765 nigel 41 No options
766     First char = '-'
767 nigel 43 Need char = 't'
768 nigel 41 the bullock-cart
769     0: -cart
770     a donkey-cart race
771     0: -cart
772     *** Failers
773     No match
774     cart
775     No match
776 ph10 102 horse-and-cart
777 nigel 41 No match
778 ph10 102
779 nigel 93 /(?<=ab(?i)x|y|z)/I
780 nigel 43 Capturing subpattern count = 0
781 nigel 41 No options
782     No first char
783 nigel 43 No need char
784 nigel 41
785 nigel 93 /(?>.*)(?<=(abcd)|(xyz))/I
786 nigel 43 Capturing subpattern count = 2
787 nigel 75 Partial matching not supported
788 nigel 41 No options
789 nigel 91 First char at start or follows newline
790 nigel 43 No need char
791 nigel 41 alphabetabcd
792     0: alphabetabcd
793     1: abcd
794     endingxyz
795     0: endingxyz
796     1: <unset>
797     2: xyz
798    
799 nigel 93 /(?<=ab(?i)x(?-i)y|(?i)z|b)ZZ/I
800 nigel 43 Capturing subpattern count = 0
801 nigel 41 No options
802     First char = 'Z'
803 nigel 43 Need char = 'Z'
804 nigel 41 abxyZZ
805     0: ZZ
806     abXyZZ
807     0: ZZ
808     ZZZ
809     0: ZZ
810     zZZ
811     0: ZZ
812     bZZ
813     0: ZZ
814 ph10 102 BZZ
815 nigel 41 0: ZZ
816     *** Failers
817     No match
818 ph10 102 ZZ
819 nigel 41 No match
820 ph10 102 abXYZZ
821 nigel 41 No match
822     zzz
823     No match
824 ph10 102 bzz
825 nigel 41 No match
826    
827 nigel 93 /(?<!(foo)a)bar/I
828 nigel 43 Capturing subpattern count = 1
829 nigel 41 No options
830     First char = 'b'
831 nigel 43 Need char = 'r'
832 nigel 41 bar
833     0: bar
834 ph10 102 foobbar
835 nigel 41 0: bar
836     *** Failers
837     No match
838 ph10 102 fooabar
839 nigel 41 No match
840    
841 nigel 93 /This one is here because Perl 5.005_02 doesn't fail it/I
842 nigel 43 Capturing subpattern count = 0
843 nigel 41 No options
844     First char = 'T'
845 nigel 43 Need char = 't'
846 nigel 41
847 nigel 93 /^(a)?(?(1)a|b)+$/I
848 nigel 43 Capturing subpattern count = 1
849 nigel 41 Options: anchored
850     No first char
851 nigel 43 No need char
852 nigel 41 *** Failers
853     No match
854 ph10 102 a
855 nigel 41 No match
856    
857 nigel 93 /This one is here because I think Perl 5.005_02 gets the setting of $1 wrong/I
858 nigel 43 Capturing subpattern count = 0
859 nigel 41 No options
860     First char = 'T'
861 nigel 43 Need char = 'g'
862 nigel 41
863 nigel 93 /^(a\1?){4}$/I
864 nigel 43 Capturing subpattern count = 1
865     Max back reference = 1
866 nigel 41 Options: anchored
867     No first char
868 nigel 65 No need char
869 nigel 41 aaaaaa
870     0: aaaaaa
871     1: aa
872 ph10 102
873 nigel 93 /These are syntax tests from Perl 5.005/I
874 nigel 43 Capturing subpattern count = 0
875 nigel 41 No options
876     First char = 'T'
877 nigel 43 Need char = '5'
878 nigel 41
879     /a[b-a]/
880     Failed: range out of order in character class at offset 4
881    
882     /a[]b/
883     Failed: missing terminating ] for character class at offset 4
884    
885     /a[/
886     Failed: missing terminating ] for character class at offset 2
887    
888     /*a/
889     Failed: nothing to repeat at offset 0
890    
891     /(*)b/
892     Failed: nothing to repeat at offset 1
893    
894     /abc)/
895     Failed: unmatched parentheses at offset 3
896    
897     /(abc/
898     Failed: missing ) at offset 4
899    
900     /a**/
901     Failed: nothing to repeat at offset 2
902    
903     /)(/
904     Failed: unmatched parentheses at offset 0
905    
906     /\1/
907 nigel 63 Failed: reference to non-existent subpattern at offset 2
908 nigel 41
909     /\2/
910 nigel 63 Failed: reference to non-existent subpattern at offset 2
911 nigel 41
912     /(a)|\2/
913 nigel 63 Failed: reference to non-existent subpattern at offset 6
914 nigel 41
915 nigel 93 /a[b-a]/Ii
916 nigel 41 Failed: range out of order in character class at offset 4
917    
918 nigel 93 /a[]b/Ii
919 nigel 41 Failed: missing terminating ] for character class at offset 4
920    
921 nigel 93 /a[/Ii
922 nigel 41 Failed: missing terminating ] for character class at offset 2
923    
924 nigel 93 /*a/Ii
925 nigel 41 Failed: nothing to repeat at offset 0
926    
927 nigel 93 /(*)b/Ii
928 nigel 41 Failed: nothing to repeat at offset 1
929    
930 nigel 93 /abc)/Ii
931 nigel 41 Failed: unmatched parentheses at offset 3
932    
933 nigel 93 /(abc/Ii
934 nigel 41 Failed: missing ) at offset 4
935    
936 nigel 93 /a**/Ii
937 nigel 41 Failed: nothing to repeat at offset 2
938    
939 nigel 93 /)(/Ii
940 nigel 41 Failed: unmatched parentheses at offset 0
941    
942     /:(?:/
943     Failed: missing ) at offset 4
944    
945     /(?<%)b/
946 nigel 63 Failed: unrecognized character after (?< at offset 3
947 nigel 41
948     /a(?{)b/
949 ph10 269 Failed: unrecognized character after (? or (?- at offset 3
950 nigel 41
951     /a(?{{})b/
952 ph10 269 Failed: unrecognized character after (? or (?- at offset 3
953 nigel 41
954     /a(?{}})b/
955 ph10 269 Failed: unrecognized character after (? or (?- at offset 3
956 nigel 41
957     /a(?{"{"})b/
958 ph10 269 Failed: unrecognized character after (? or (?- at offset 3
959 nigel 41
960     /a(?{"{"}})b/
961 ph10 269 Failed: unrecognized character after (? or (?- at offset 3
962 nigel 41
963     /(?(1?)a|b)/
964 nigel 91 Failed: malformed number or name after (?( at offset 4
965 nigel 41
966     /[a[:xyz:/
967     Failed: missing terminating ] for character class at offset 8
968    
969     /(?<=x+)y/
970     Failed: lookbehind assertion is not fixed length at offset 6
971    
972     /a{37,17}/
973     Failed: numbers out of order in {} quantifier at offset 7
974    
975     /abc/\
976     Failed: \ at end of pattern at offset 4
977    
978     /abc/\P
979     Failed: POSIX code 9: bad escape sequence at offset 4
980    
981     /abc/\i
982     Failed: \ at end of pattern at offset 4
983    
984 nigel 93 /(a)bc(d)/I
985 nigel 43 Capturing subpattern count = 2
986 nigel 41 No options
987     First char = 'a'
988 nigel 43 Need char = 'd'
989 nigel 41 abcd
990     0: abcd
991     1: a
992     2: d
993     abcd\C2
994     0: abcd
995     1: a
996     2: d
997     2C d (1)
998     abcd\C5
999     0: abcd
1000     1: a
1001     2: d
1002     copy substring 5 failed -7
1003 ph10 102
1004 nigel 93 /(.{20})/I
1005 nigel 43 Capturing subpattern count = 1
1006 nigel 75 Partial matching not supported
1007 nigel 41 No options
1008     No first char
1009 nigel 43 No need char
1010 nigel 41 abcdefghijklmnopqrstuvwxyz
1011     0: abcdefghijklmnopqrst
1012     1: abcdefghijklmnopqrst
1013     abcdefghijklmnopqrstuvwxyz\C1
1014     0: abcdefghijklmnopqrst
1015     1: abcdefghijklmnopqrst
1016 nigel 91 1C abcdefghijklmnopqrst (20)
1017 nigel 41 abcdefghijklmnopqrstuvwxyz\G1
1018     0: abcdefghijklmnopqrst
1019     1: abcdefghijklmnopqrst
1020     1G abcdefghijklmnopqrst (20)
1021 ph10 102
1022 nigel 93 /(.{15})/I
1023 nigel 43 Capturing subpattern count = 1
1024 nigel 75 Partial matching not supported
1025 nigel 41 No options
1026     No first char
1027 nigel 43 No need char
1028 nigel 41 abcdefghijklmnopqrstuvwxyz
1029     0: abcdefghijklmno
1030     1: abcdefghijklmno
1031     abcdefghijklmnopqrstuvwxyz\C1\G1
1032     0: abcdefghijklmno
1033     1: abcdefghijklmno
1034     1C abcdefghijklmno (15)
1035     1G abcdefghijklmno (15)
1036    
1037 nigel 93 /(.{16})/I
1038 nigel 43 Capturing subpattern count = 1
1039 nigel 75 Partial matching not supported
1040 nigel 41 No options
1041     No first char
1042 nigel 43 No need char
1043 nigel 41 abcdefghijklmnopqrstuvwxyz
1044     0: abcdefghijklmnop
1045     1: abcdefghijklmnop
1046     abcdefghijklmnopqrstuvwxyz\C1\G1\L
1047     0: abcdefghijklmnop
1048     1: abcdefghijklmnop
1049 nigel 91 1C abcdefghijklmnop (16)
1050 nigel 41 1G abcdefghijklmnop (16)
1051     0L abcdefghijklmnop
1052     1L abcdefghijklmnop
1053 ph10 102
1054 nigel 93 /^(a|(bc))de(f)/I
1055 nigel 43 Capturing subpattern count = 3
1056 nigel 41 Options: anchored
1057     No first char
1058 nigel 65 No need char
1059 ph10 102 adef\G1\G2\G3\G4\L
1060 nigel 41 0: adef
1061     1: a
1062     2: <unset>
1063     3: f
1064     1G a (1)
1065     2G (0)
1066     3G f (1)
1067     get substring 4 failed -7
1068     0L adef
1069     1L a
1070     2L
1071     3L f
1072 ph10 102 bcdef\G1\G2\G3\G4\L
1073 nigel 41 0: bcdef
1074     1: bc
1075     2: bc
1076     3: f
1077     1G bc (2)
1078     2G bc (2)
1079     3G f (1)
1080     get substring 4 failed -7
1081     0L bcdef
1082     1L bc
1083     2L bc
1084     3L f
1085 ph10 102 adefghijk\C0
1086 nigel 41 0: adef
1087     1: a
1088     2: <unset>
1089     3: f
1090     0C adef (4)
1091 ph10 102
1092 nigel 93 /^abc\00def/I
1093 nigel 43 Capturing subpattern count = 0
1094 nigel 41 Options: anchored
1095     No first char
1096 nigel 65 No need char
1097 ph10 102 abc\00def\L\C0
1098 nigel 41 0: abc\x00def
1099     0C abc (7)
1100     0L abc
1101 ph10 102
1102     /word ((?:[a-zA-Z0-9]+ )((?:[a-zA-Z0-9]+ )((?:[a-zA-Z0-9]+ )((?:[a-zA-Z0-9]+
1103     )((?:[a-zA-Z0-9]+ )((?:[a-zA-Z0-9]+ )((?:[a-zA-Z0-9]+ )((?:[a-zA-Z0-9]+
1104 ph10 162 )?)?)?)?)?)?)?)?)?otherword/I
1105 nigel 43 Capturing subpattern count = 8
1106 nigel 75 Partial matching not supported
1107 ph10 226 Contains explicit CR or LF match
1108 nigel 41 No options
1109     First char = 'w'
1110 nigel 43 Need char = 'd'
1111 nigel 41
1112 ph10 161 /.*X/IDZ
1113 nigel 41 ------------------------------------------------------------------
1114 ph10 192 Bra
1115 ph10 161 Any*
1116     X
1117     Ket
1118     End
1119 nigel 41 ------------------------------------------------------------------
1120 nigel 43 Capturing subpattern count = 0
1121 nigel 75 Partial matching not supported
1122 nigel 41 No options
1123 nigel 91 First char at start or follows newline
1124 nigel 43 Need char = 'X'
1125 nigel 41
1126 ph10 161 /.*X/IDZs
1127 nigel 41 ------------------------------------------------------------------
1128 ph10 192 Bra
1129 ph10 161 Any*
1130     X
1131     Ket
1132     End
1133 nigel 41 ------------------------------------------------------------------
1134 nigel 43 Capturing subpattern count = 0
1135 nigel 75 Partial matching not supported
1136 nigel 41 Options: anchored dotall
1137     No first char
1138 nigel 43 Need char = 'X'
1139 nigel 41
1140 ph10 161 /(.*X|^B)/IDZ
1141 nigel 41 ------------------------------------------------------------------
1142 ph10 192 Bra
1143     CBra 1
1144 ph10 161 Any*
1145     X
1146     Alt
1147     ^
1148     B
1149     Ket
1150     Ket
1151     End
1152 nigel 41 ------------------------------------------------------------------
1153 nigel 43 Capturing subpattern count = 1
1154 nigel 75 Partial matching not supported
1155 nigel 41 No options
1156 nigel 91 First char at start or follows newline
1157 nigel 43 No need char
1158 nigel 41
1159 ph10 161 /(.*X|^B)/IDZs
1160 nigel 41 ------------------------------------------------------------------
1161 ph10 192 Bra
1162     CBra 1
1163 ph10 161 Any*
1164     X
1165     Alt
1166     ^
1167     B
1168     Ket
1169     Ket
1170     End
1171 nigel 41 ------------------------------------------------------------------
1172 nigel 43 Capturing subpattern count = 1
1173 nigel 75 Partial matching not supported
1174 nigel 41 Options: anchored dotall
1175     No first char
1176 nigel 43 No need char
1177 ph10 102
1178 ph10 161 /(?s)(.*X|^B)/IDZ
1179 nigel 41 ------------------------------------------------------------------
1180 ph10 192 Bra
1181     CBra 1
1182 ph10 161 Any*
1183     X
1184     Alt
1185     ^
1186     B
1187     Ket
1188     Ket
1189     End
1190 nigel 41 ------------------------------------------------------------------
1191 nigel 43 Capturing subpattern count = 1
1192 nigel 75 Partial matching not supported
1193 nigel 41 Options: anchored dotall
1194     No first char
1195 nigel 43 No need char
1196 nigel 41
1197 ph10 161 /(?s:.*X|^B)/IDZ
1198 nigel 41 ------------------------------------------------------------------
1199 ph10 192 Bra
1200     Bra
1201 ph10 161 04 Opt
1202     Any*
1203     X
1204     Alt
1205     04 Opt
1206     ^
1207     B
1208     Ket
1209     00 Opt
1210     Ket
1211     End
1212 nigel 41 ------------------------------------------------------------------
1213 nigel 43 Capturing subpattern count = 0
1214 nigel 75 Partial matching not supported
1215 nigel 41 No options
1216 nigel 91 First char at start or follows newline
1217 nigel 43 No need char
1218 nigel 41
1219 nigel 93 /\Biss\B/I+
1220 nigel 43 Capturing subpattern count = 0
1221 nigel 41 No options
1222     First char = 'i'
1223 nigel 43 Need char = 's'
1224 nigel 41 Mississippi
1225     0: iss
1226     0+ issippi
1227    
1228 nigel 93 /\Biss\B/I+P
1229 nigel 41 Mississippi
1230     0: iss
1231     0+ issippi
1232    
1233 nigel 93 /iss/IG+
1234 nigel 43 Capturing subpattern count = 0
1235 nigel 41 No options
1236     First char = 'i'
1237 nigel 43 Need char = 's'
1238 nigel 41 Mississippi
1239     0: iss
1240     0+ issippi
1241     0: iss
1242     0+ ippi
1243    
1244 nigel 93 /\Biss\B/IG+
1245 nigel 43 Capturing subpattern count = 0
1246 nigel 41 No options
1247     First char = 'i'
1248 nigel 43 Need char = 's'
1249 nigel 41 Mississippi
1250     0: iss
1251     0+ issippi
1252    
1253 nigel 93 /\Biss\B/Ig+
1254 nigel 43 Capturing subpattern count = 0
1255 nigel 41 No options
1256     First char = 'i'
1257 nigel 43 Need char = 's'
1258 nigel 41 Mississippi
1259     0: iss
1260     0+ issippi
1261     0: iss
1262     0+ ippi
1263     *** Failers
1264     No match
1265     Mississippi\A
1266     No match
1267    
1268 nigel 93 /(?<=[Ms])iss/Ig+
1269 nigel 43 Capturing subpattern count = 0
1270 nigel 41 No options
1271     First char = 'i'
1272 nigel 43 Need char = 's'
1273 nigel 41 Mississippi
1274     0: iss
1275     0+ issippi
1276     0: iss
1277     0+ ippi
1278    
1279 nigel 93 /(?<=[Ms])iss/IG+
1280 nigel 43 Capturing subpattern count = 0
1281 nigel 41 No options
1282     First char = 'i'
1283 nigel 43 Need char = 's'
1284 nigel 41 Mississippi
1285     0: iss
1286     0+ issippi
1287    
1288 nigel 93 /^iss/Ig+
1289 nigel 43 Capturing subpattern count = 0
1290 nigel 41 Options: anchored
1291     No first char
1292 nigel 65 No need char
1293 nigel 41 ississippi
1294     0: iss
1295     0+ issippi
1296 ph10 102
1297 nigel 93 /.*iss/Ig+
1298 nigel 43 Capturing subpattern count = 0
1299 nigel 75 Partial matching not supported
1300 nigel 41 No options
1301 nigel 91 First char at start or follows newline
1302 nigel 43 Need char = 's'
1303 ph10 102 abciss\nxyzisspqr
1304 nigel 41 0: abciss
1305     0+ \x0axyzisspqr
1306     0: xyziss
1307     0+ pqr
1308    
1309 nigel 93 /.i./I+g
1310 nigel 43 Capturing subpattern count = 0
1311 nigel 41 No options
1312     No first char
1313 nigel 43 Need char = 'i'
1314 nigel 41 Mississippi
1315     0: Mis
1316     0+ sissippi
1317     0: sis
1318     0+ sippi
1319     0: sip
1320     0+ pi
1321     Mississippi\A
1322     0: Mis
1323     0+ sissippi
1324     0: sis
1325     0+ sippi
1326     0: sip
1327     0+ pi
1328     Missouri river
1329     0: Mis
1330     0+ souri river
1331     0: ri
1332     0+ river
1333     0: riv
1334     0+ er
1335 ph10 102 Missouri river\A
1336 nigel 41 0: Mis
1337     0+ souri river
1338    
1339 nigel 93 /^.is/I+g
1340 nigel 43 Capturing subpattern count = 0
1341 nigel 41 Options: anchored
1342     No first char
1343 nigel 65 No need char
1344 nigel 41 Mississippi
1345     0: Mis
1346     0+ sissippi
1347    
1348 nigel 93 /^ab\n/Ig+
1349 nigel 43 Capturing subpattern count = 0
1350 ph10 226 Contains explicit CR or LF match
1351 nigel 41 Options: anchored
1352     No first char
1353 nigel 65 No need char
1354 nigel 41 ab\nab\ncd
1355     0: ab\x0a
1356     0+ ab\x0acd
1357    
1358 nigel 93 /^ab\n/Img+
1359 nigel 43 Capturing subpattern count = 0
1360 ph10 226 Contains explicit CR or LF match
1361 nigel 41 Options: multiline
1362 nigel 91 First char at start or follows newline
1363 nigel 43 Need char = 10
1364 nigel 41 ab\nab\ncd
1365     0: ab\x0a
1366     0+ ab\x0acd
1367     0: ab\x0a
1368     0+ cd
1369    
1370 nigel 93 /abc/I
1371 nigel 43 Capturing subpattern count = 0
1372 nigel 41 No options
1373     First char = 'a'
1374 nigel 43 Need char = 'c'
1375 nigel 41
1376 nigel 93 /abc|bac/I
1377 nigel 43 Capturing subpattern count = 0
1378 nigel 41 No options
1379     No first char
1380 nigel 43 Need char = 'c'
1381 nigel 41
1382 nigel 93 /(abc|bac)/I
1383 nigel 43 Capturing subpattern count = 1
1384 nigel 41 No options
1385     No first char
1386 nigel 43 Need char = 'c'
1387 nigel 41
1388 nigel 93 /(abc|(c|dc))/I
1389 nigel 43 Capturing subpattern count = 2
1390 nigel 41 No options
1391     No first char
1392 nigel 43 Need char = 'c'
1393 nigel 41
1394 nigel 93 /(abc|(d|de)c)/I
1395 nigel 43 Capturing subpattern count = 2
1396 nigel 41 No options
1397     No first char
1398 nigel 43 Need char = 'c'
1399 nigel 41
1400 nigel 93 /a*/I
1401 nigel 43 Capturing subpattern count = 0
1402 nigel 75 Partial matching not supported
1403 nigel 41 No options
1404     No first char
1405 nigel 43 No need char
1406 nigel 41
1407 nigel 93 /a+/I
1408 nigel 43 Capturing subpattern count = 0
1409 nigel 75 Partial matching not supported
1410 nigel 41 No options
1411     First char = 'a'
1412 nigel 43 No need char
1413 nigel 41
1414 nigel 93 /(baa|a+)/I
1415 nigel 43 Capturing subpattern count = 1
1416 nigel 75 Partial matching not supported
1417 nigel 41 No options
1418     No first char
1419 nigel 43 Need char = 'a'
1420 nigel 41
1421 nigel 93 /a{0,3}/I
1422 nigel 43 Capturing subpattern count = 0
1423 nigel 75 Partial matching not supported
1424 nigel 41 No options
1425     No first char
1426 nigel 43 No need char
1427 nigel 41
1428 nigel 93 /baa{3,}/I
1429 nigel 43 Capturing subpattern count = 0
1430 nigel 75 Partial matching not supported
1431 nigel 41 No options
1432     First char = 'b'
1433 nigel 43 Need char = 'a'
1434 nigel 41
1435 nigel 93 /"([^\\"]+|\\.)*"/I
1436 nigel 43 Capturing subpattern count = 1
1437 nigel 75 Partial matching not supported
1438 nigel 41 No options
1439     First char = '"'
1440 nigel 43 Need char = '"'
1441 nigel 41
1442 nigel 93 /(abc|ab[cd])/I
1443 nigel 43 Capturing subpattern count = 1
1444 nigel 41 No options
1445     First char = 'a'
1446 nigel 43 No need char
1447 nigel 41
1448 nigel 93 /(a|.)/I
1449 nigel 43 Capturing subpattern count = 1
1450 nigel 41 No options
1451     No first char
1452 nigel 43 No need char
1453 nigel 41
1454 nigel 93 /a|ba|\w/I
1455 nigel 43 Capturing subpattern count = 0
1456 nigel 41 No options
1457     No first char
1458 nigel 43 No need char
1459 nigel 41
1460 nigel 93 /abc(?=pqr)/I
1461 nigel 43 Capturing subpattern count = 0
1462 nigel 41 No options
1463     First char = 'a'
1464 nigel 43 Need char = 'r'
1465 nigel 41
1466 nigel 93 /...(?<=abc)/I
1467 nigel 43 Capturing subpattern count = 0
1468 nigel 41 No options
1469     No first char
1470 nigel 43 No need char
1471 nigel 41
1472 nigel 93 /abc(?!pqr)/I
1473 nigel 43 Capturing subpattern count = 0
1474 nigel 41 No options
1475     First char = 'a'
1476 nigel 43 Need char = 'c'
1477 nigel 41
1478 nigel 93 /ab./I
1479 nigel 43 Capturing subpattern count = 0
1480 nigel 41 No options
1481     First char = 'a'
1482 nigel 43 Need char = 'b'
1483 nigel 41
1484 nigel 93 /ab[xyz]/I
1485 nigel 43 Capturing subpattern count = 0
1486 nigel 41 No options
1487     First char = 'a'
1488 nigel 43 Need char = 'b'
1489 nigel 41
1490 nigel 93 /abc*/I
1491 nigel 43 Capturing subpattern count = 0
1492 nigel 75 Partial matching not supported
1493 nigel 41 No options
1494     First char = 'a'
1495 nigel 43 Need char = 'b'
1496 nigel 41
1497 nigel 93 /ab.c*/I
1498 nigel 43 Capturing subpattern count = 0
1499 nigel 75 Partial matching not supported
1500 nigel 41 No options
1501     First char = 'a'
1502 nigel 43 Need char = 'b'
1503 nigel 41
1504 nigel 93 /a.c*/I
1505 nigel 43 Capturing subpattern count = 0
1506 nigel 75 Partial matching not supported
1507 nigel 41 No options
1508     First char = 'a'
1509 nigel 43 No need char
1510 nigel 41
1511 nigel 93 /.c*/I
1512 nigel 43 Capturing subpattern count = 0
1513 nigel 75 Partial matching not supported
1514 nigel 41 No options
1515     No first char
1516 nigel 43 No need char
1517 nigel 41
1518 nigel 93 /ac*/I
1519 nigel 43 Capturing subpattern count = 0
1520 nigel 75 Partial matching not supported
1521 nigel 41 No options
1522     First char = 'a'
1523 nigel 43 No need char
1524 nigel 41
1525 nigel 93 /(a.c*|b.c*)/I
1526 nigel 43 Capturing subpattern count = 1
1527 nigel 75 Partial matching not supported
1528 nigel 41 No options
1529     No first char
1530 nigel 43 No need char
1531 nigel 41
1532 nigel 93 /a.c*|aba/I
1533 nigel 43 Capturing subpattern count = 0
1534 nigel 75 Partial matching not supported
1535 nigel 41 No options
1536     First char = 'a'
1537 nigel 43 No need char
1538 nigel 41
1539 nigel 93 /.+a/I
1540 nigel 43 Capturing subpattern count = 0
1541 nigel 75 Partial matching not supported
1542 nigel 41 No options
1543     No first char
1544 nigel 43 Need char = 'a'
1545 nigel 41
1546 nigel 93 /(?=abcda)a.*/I
1547 nigel 43 Capturing subpattern count = 0
1548 nigel 75 Partial matching not supported
1549 nigel 41 No options
1550     First char = 'a'
1551 nigel 63 Need char = 'a'
1552 nigel 41
1553 nigel 93 /(?=a)a.*/I
1554 nigel 43 Capturing subpattern count = 0
1555 nigel 75 Partial matching not supported
1556 nigel 41 No options
1557     First char = 'a'
1558 nigel 43 No need char
1559 nigel 41
1560 nigel 93 /a(b)*/I
1561 nigel 43 Capturing subpattern count = 1
1562 nigel 41 No options
1563     First char = 'a'
1564 nigel 43 No need char
1565 nigel 41
1566 nigel 93 /a\d*/I
1567 nigel 43 Capturing subpattern count = 0
1568 nigel 75 Partial matching not supported
1569 nigel 41 No options
1570     First char = 'a'
1571 nigel 43 No need char
1572 nigel 41
1573 nigel 93 /ab\d*/I
1574 nigel 43 Capturing subpattern count = 0
1575 nigel 75 Partial matching not supported
1576 nigel 41 No options
1577     First char = 'a'
1578 nigel 43 Need char = 'b'
1579 nigel 41
1580 nigel 93 /a(\d)*/I
1581 nigel 43 Capturing subpattern count = 1
1582 nigel 41 No options
1583     First char = 'a'
1584 nigel 43 No need char
1585 nigel 41
1586 nigel 93 /abcde{0,0}/I
1587 nigel 43 Capturing subpattern count = 0
1588 nigel 41 No options
1589     First char = 'a'
1590 nigel 43 Need char = 'd'
1591 nigel 41
1592 nigel 93 /ab\d+/I
1593 nigel 43 Capturing subpattern count = 0
1594 nigel 75 Partial matching not supported
1595 nigel 41 No options
1596     First char = 'a'
1597 nigel 43 Need char = 'b'
1598 nigel 41
1599 ph10 270 /a(?(1)b)(.)/I
1600     Capturing subpattern count = 1
1601 nigel 41 No options
1602     First char = 'a'
1603 nigel 43 No need char
1604 nigel 41
1605 ph10 270 /a(?(1)bag|big)(.)/I
1606     Capturing subpattern count = 1
1607 nigel 41 No options
1608     First char = 'a'
1609 nigel 43 Need char = 'g'
1610 nigel 41
1611 ph10 270 /a(?(1)bag|big)*(.)/I
1612     Capturing subpattern count = 1
1613 nigel 41 No options
1614     First char = 'a'
1615 nigel 43 No need char
1616 nigel 41
1617 ph10 270 /a(?(1)bag|big)+(.)/I
1618     Capturing subpattern count = 1
1619 nigel 41 No options
1620     First char = 'a'
1621 nigel 43 Need char = 'g'
1622 nigel 41
1623 ph10 270 /a(?(1)b..|b..)(.)/I
1624     Capturing subpattern count = 1
1625 nigel 41 No options
1626     First char = 'a'
1627 nigel 43 Need char = 'b'
1628 nigel 41
1629 nigel 93 /ab\d{0}e/I
1630 nigel 43 Capturing subpattern count = 0
1631 nigel 41 No options
1632     First char = 'a'
1633 nigel 43 Need char = 'e'
1634 nigel 41
1635 nigel 93 /a?b?/I
1636 nigel 43 Capturing subpattern count = 0
1637 nigel 41 No options
1638     No first char
1639 nigel 43 No need char
1640 nigel 41 a
1641     0: a
1642     b
1643     0: b
1644     ab
1645     0: ab
1646     \
1647     0:
1648     *** Failers
1649     0:
1650 ph10 102 \N
1651 nigel 41 No match
1652 ph10 102
1653 nigel 93 /|-/I
1654 nigel 43 Capturing subpattern count = 0
1655 nigel 41 No options
1656     No first char
1657 nigel 43 No need char
1658 nigel 41 abcd
1659     0:
1660     -abc
1661     0:
1662     \Nab-c
1663     0: -
1664     *** Failers
1665     0:
1666 ph10 102 \Nabc
1667 nigel 41 No match
1668    
1669 nigel 93 /a*(b+)(z)(z)/IP
1670 nigel 41 aaaabbbbzzzz
1671     0: aaaabbbbzz
1672     1: bbbb
1673     2: z
1674     3: z
1675     aaaabbbbzzzz\O0
1676     aaaabbbbzzzz\O1
1677     0: aaaabbbbzz
1678     aaaabbbbzzzz\O2
1679     0: aaaabbbbzz
1680     1: bbbb
1681     aaaabbbbzzzz\O3
1682     0: aaaabbbbzz
1683     1: bbbb
1684     2: z
1685     aaaabbbbzzzz\O4
1686     0: aaaabbbbzz
1687     1: bbbb
1688     2: z
1689     3: z
1690     aaaabbbbzzzz\O5
1691     0: aaaabbbbzz
1692     1: bbbb
1693     2: z
1694     3: z
1695 ph10 102
1696     /^.?abcd/IS
1697 nigel 43 Capturing subpattern count = 0
1698     Options: anchored
1699     No first char
1700     Need char = 'd'
1701     Study returned NULL
1702 nigel 41
1703 nigel 43 /\( # ( at start
1704     (?: # Non-capturing bracket
1705     (?>[^()]+) # Either a sequence of non-brackets (no backtracking)
1706     | # Or
1707     (?R) # Recurse - i.e. nested bracketed string
1708     )* # Zero or more contents
1709     \) # Closing )
1710 nigel 93 /Ix
1711 nigel 43 Capturing subpattern count = 0
1712 nigel 75 Partial matching not supported
1713 nigel 43 Options: extended
1714     First char = '('
1715     Need char = ')'
1716     (abcd)
1717     0: (abcd)
1718     (abcd)xyz
1719     0: (abcd)
1720     xyz(abcd)
1721     0: (abcd)
1722 ph10 102 (ab(xy)cd)pqr
1723 nigel 43 0: (ab(xy)cd)
1724 ph10 102 (ab(xycd)pqr
1725 nigel 43 0: (xycd)
1726 ph10 102 () abc ()
1727 nigel 43 0: ()
1728     12(abcde(fsh)xyz(foo(bar))lmno)89
1729     0: (abcde(fsh)xyz(foo(bar))lmno)
1730     *** Failers
1731     No match
1732 ph10 102 abcd
1733 nigel 43 No match
1734     abcd)
1735     No match
1736 ph10 102 (abcd
1737 nigel 43 No match
1738    
1739 nigel 93 /\( ( (?>[^()]+) | (?R) )* \) /Ixg
1740 nigel 43 Capturing subpattern count = 1
1741 nigel 75 Partial matching not supported
1742 nigel 43 Options: extended
1743     First char = '('
1744     Need char = ')'
1745 ph10 102 (ab(xy)cd)pqr
1746 nigel 43 0: (ab(xy)cd)
1747     1: cd
1748     1(abcd)(x(y)z)pqr
1749     0: (abcd)
1750     1: abcd
1751     0: (x(y)z)
1752     1: z
1753    
1754 nigel 93 /\( (?: (?>[^()]+) | (?R) ) \) /Ix
1755 nigel 43 Capturing subpattern count = 0
1756 nigel 75 Partial matching not supported
1757 nigel 43 Options: extended
1758     First char = '('
1759     Need char = ')'
1760     (abcd)
1761     0: (abcd)
1762     (ab(xy)cd)
1763     0: (xy)
1764 ph10 102 (a(b(c)d)e)
1765 nigel 43 0: (c)
1766 ph10 102 ((ab))
1767 nigel 43 0: ((ab))
1768     *** Failers
1769     No match
1770 ph10 102 ()
1771 nigel 43 No match
1772    
1773 nigel 93 /\( (?: (?>[^()]+) | (?R) )? \) /Ix
1774 nigel 43 Capturing subpattern count = 0
1775 nigel 75 Partial matching not supported
1776 nigel 43 Options: extended
1777     First char = '('
1778     Need char = ')'
1779     ()
1780     0: ()
1781     12(abcde(fsh)xyz(foo(bar))lmno)89
1782     0: (fsh)
1783    
1784 nigel 93 /\( ( (?>[^()]+) | (?R) )* \) /Ix
1785 nigel 43 Capturing subpattern count = 1
1786 nigel 75 Partial matching not supported
1787 nigel 43 Options: extended
1788     First char = '('
1789     Need char = ')'
1790     (ab(xy)cd)
1791     0: (ab(xy)cd)
1792     1: cd
1793    
1794 nigel 93 /\( ( ( (?>[^()]+) | (?R) )* ) \) /Ix
1795 nigel 43 Capturing subpattern count = 2
1796 nigel 75 Partial matching not supported
1797 nigel 43 Options: extended
1798     First char = '('
1799     Need char = ')'
1800     (ab(xy)cd)
1801     0: (ab(xy)cd)
1802     1: ab(xy)cd
1803     2: cd
1804    
1805 nigel 93 /\( (123)? ( ( (?>[^()]+) | (?R) )* ) \) /Ix
1806 nigel 43 Capturing subpattern count = 3
1807 nigel 75 Partial matching not supported
1808 nigel 43 Options: extended
1809     First char = '('
1810     Need char = ')'
1811     (ab(xy)cd)
1812     0: (ab(xy)cd)
1813     1: <unset>
1814     2: ab(xy)cd
1815     3: cd
1816     (123ab(xy)cd)
1817     0: (123ab(xy)cd)
1818     1: 123
1819     2: ab(xy)cd
1820     3: cd
1821    
1822 nigel 93 /\( ( (123)? ( (?>[^()]+) | (?R) )* ) \) /Ix
1823 nigel 43 Capturing subpattern count = 3
1824 nigel 75 Partial matching not supported
1825 nigel 43 Options: extended
1826     First char = '('
1827     Need char = ')'
1828     (ab(xy)cd)
1829     0: (ab(xy)cd)
1830     1: ab(xy)cd
1831     2: <unset>
1832     3: cd
1833     (123ab(xy)cd)
1834     0: (123ab(xy)cd)
1835     1: 123ab(xy)cd
1836     2: 123
1837     3: cd
1838    
1839 nigel 93 /\( (((((((((( ( (?>[^()]+) | (?R) )* )))))))))) \) /Ix
1840 nigel 43 Capturing subpattern count = 11
1841 nigel 75 Partial matching not supported
1842 nigel 43 Options: extended
1843     First char = '('
1844     Need char = ')'
1845     (ab(xy)cd)
1846     0: (ab(xy)cd)
1847     1: ab(xy)cd
1848     2: ab(xy)cd
1849     3: ab(xy)cd
1850     4: ab(xy)cd
1851     5: ab(xy)cd
1852     6: ab(xy)cd
1853     7: ab(xy)cd
1854     8: ab(xy)cd
1855     9: ab(xy)cd
1856     10: ab(xy)cd
1857     11: cd
1858    
1859 nigel 93 /\( ( ( (?>[^()<>]+) | ((?>[^()]+)) | (?R) )* ) \) /Ix
1860 nigel 43 Capturing subpattern count = 3
1861 nigel 75 Partial matching not supported
1862 nigel 43 Options: extended
1863     First char = '('
1864     Need char = ')'
1865     (abcd(xyz<p>qrs)123)
1866     0: (abcd(xyz<p>qrs)123)
1867     1: abcd(xyz<p>qrs)123
1868     2: 123
1869 nigel 63 3: <unset>
1870 nigel 43
1871 nigel 93 /\( ( ( (?>[^()]+) | ((?R)) )* ) \) /Ix
1872 nigel 43 Capturing subpattern count = 3
1873 nigel 75 Partial matching not supported
1874 nigel 43 Options: extended
1875     First char = '('
1876     Need char = ')'
1877     (ab(cd)ef)
1878     0: (ab(cd)ef)
1879     1: ab(cd)ef
1880     2: ef
1881     3: (cd)
1882     (ab(cd(ef)gh)ij)
1883     0: (ab(cd(ef)gh)ij)
1884     1: ab(cd(ef)gh)ij
1885     2: ij
1886     3: (cd(ef)gh)
1887    
1888 ph10 161 /^[[:alnum:]]/DZ
1889 nigel 43 ------------------------------------------------------------------
1890 ph10 192 Bra
1891 ph10 161 ^
1892     [0-9A-Za-z]
1893     Ket
1894     End
1895 nigel 43 ------------------------------------------------------------------
1896     Capturing subpattern count = 0
1897     Options: anchored
1898     No first char
1899     No need char
1900    
1901 ph10 161 /^[[:^alnum:]]/DZ
1902 nigel 75 ------------------------------------------------------------------
1903 ph10 192 Bra
1904 ph10 161 ^
1905 ph10 265 [\x00-/:-@[-`{-\xff] (neg)
1906 ph10 161 Ket
1907     End
1908 nigel 75 ------------------------------------------------------------------
1909     Capturing subpattern count = 0
1910     Options: anchored
1911     No first char
1912     No need char
1913    
1914 ph10 161 /^[[:alpha:]]/DZ
1915 nigel 43 ------------------------------------------------------------------
1916 ph10 192 Bra
1917 ph10 161 ^
1918     [A-Za-z]
1919     Ket
1920     End
1921 nigel 43 ------------------------------------------------------------------
1922     Capturing subpattern count = 0
1923     Options: anchored
1924     No first char
1925     No need char
1926 nigel 75
1927 ph10 161 /^[[:^alpha:]]/DZ
1928 nigel 75 ------------------------------------------------------------------
1929 ph10 192 Bra
1930 ph10 161 ^
1931 ph10 265 [\x00-@[-`{-\xff] (neg)
1932 ph10 161 Ket
1933     End
1934 nigel 75 ------------------------------------------------------------------
1935     Capturing subpattern count = 0
1936     Options: anchored
1937     No first char
1938     No need char
1939 ph10 102
1940 nigel 87 /[_[:alpha:]]/IS
1941     Capturing subpattern count = 0
1942     No options
1943     No first char
1944     No need char
1945     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
1946     _ 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
1947    
1948 ph10 161 /^[[:ascii:]]/DZ
1949 nigel 43 ------------------------------------------------------------------
1950 ph10 192 Bra
1951 ph10 161 ^
1952     [\x00-\x7f]
1953     Ket
1954     End
1955 nigel 43 ------------------------------------------------------------------
1956     Capturing subpattern count = 0
1957     Options: anchored
1958     No first char
1959     No need char
1960    
1961 ph10 161 /^[[:^ascii:]]/DZ
1962 nigel 75 ------------------------------------------------------------------
1963 ph10 192 Bra
1964 ph10 161 ^
1965 ph10 265 [\x80-\xff] (neg)
1966 ph10 161 Ket
1967     End
1968 nigel 75 ------------------------------------------------------------------
1969     Capturing subpattern count = 0
1970     Options: anchored
1971     No first char
1972     No need char
1973    
1974 ph10 161 /^[[:blank:]]/DZ
1975 nigel 63 ------------------------------------------------------------------
1976 ph10 192 Bra
1977 ph10 161 ^
1978     [\x09 ]
1979     Ket
1980     End
1981 nigel 63 ------------------------------------------------------------------
1982     Capturing subpattern count = 0
1983     Options: anchored
1984     No first char
1985     No need char
1986    
1987 ph10 161 /^[[:^blank:]]/DZ
1988 nigel 87 ------------------------------------------------------------------
1989 ph10 192 Bra
1990 ph10 161 ^
1991 ph10 265 [\x00-\x08\x0a-\x1f!-\xff] (neg)
1992 ph10 161 Ket
1993     End
1994 nigel 87 ------------------------------------------------------------------
1995     Capturing subpattern count = 0
1996     Options: anchored
1997     No first char
1998     No need char
1999    
2000     /[\n\x0b\x0c\x0d[:blank:]]/IS
2001     Capturing subpattern count = 0
2002 ph10 226 Contains explicit CR or LF match
2003 nigel 87 No options
2004     No first char
2005     No need char
2006     Starting byte set: \x09 \x0a \x0b \x0c \x0d \x20
2007    
2008 ph10 161 /^[[:cntrl:]]/DZ
2009 nigel 43 ------------------------------------------------------------------
2010 ph10 192 Bra
2011 ph10 161 ^
2012     [\x00-\x1f\x7f]
2013     Ket
2014     End
2015 nigel 43 ------------------------------------------------------------------
2016     Capturing subpattern count = 0
2017     Options: anchored
2018     No first char
2019     No need char
2020    
2021 ph10 161 /^[[:digit:]]/DZ
2022 nigel 43 ------------------------------------------------------------------
2023 ph10 192 Bra
2024 ph10 161 ^
2025     [0-9]
2026     Ket
2027     End
2028 nigel 43 ------------------------------------------------------------------
2029     Capturing subpattern count = 0
2030     Options: anchored
2031     No first char
2032     No need char
2033    
2034 ph10 161 /^[[:graph:]]/DZ
2035 nigel 43 ------------------------------------------------------------------
2036 ph10 192 Bra
2037 ph10 161 ^
2038     [!-~]
2039     Ket
2040     End
2041 nigel 43 ------------------------------------------------------------------
2042     Capturing subpattern count = 0
2043     Options: anchored
2044     No first char
2045     No need char
2046    
2047 ph10 161 /^[[:lower:]]/DZ
2048 nigel 43 ------------------------------------------------------------------
2049 ph10 192 Bra
2050 ph10 161 ^
2051     [a-z]
2052     Ket
2053     End
2054 nigel 43 ------------------------------------------------------------------
2055     Capturing subpattern count = 0
2056     Options: anchored
2057     No first char
2058     No need char
2059    
2060 ph10 161 /^[[:print:]]/DZ
2061 nigel 43 ------------------------------------------------------------------
2062 ph10 192 Bra
2063 ph10 161 ^
2064     [ -~]
2065     Ket
2066     End
2067 nigel 43 ------------------------------------------------------------------
2068     Capturing subpattern count = 0
2069     Options: anchored
2070     No first char
2071     No need char
2072    
2073 ph10 161 /^[[:punct:]]/DZ
2074 nigel 43 ------------------------------------------------------------------
2075 ph10 192 Bra
2076 ph10 161 ^
2077     [!-/:-@[-`{-~]
2078     Ket
2079     End
2080 nigel 43 ------------------------------------------------------------------
2081     Capturing subpattern count = 0
2082     Options: anchored
2083     No first char
2084     No need char
2085    
2086 ph10 161 /^[[:space:]]/DZ
2087 nigel 43 ------------------------------------------------------------------
2088 ph10 192 Bra
2089 ph10 161 ^
2090     [\x09-\x0d ]
2091     Ket
2092     End
2093 nigel 43 ------------------------------------------------------------------
2094     Capturing subpattern count = 0
2095     Options: anchored
2096     No first char
2097     No need char
2098    
2099 ph10 161 /^[[:upper:]]/DZ
2100 nigel 43 ------------------------------------------------------------------
2101 ph10 192 Bra
2102 ph10 161 ^
2103     [A-Z]
2104     Ket
2105     End
2106 nigel 43 ------------------------------------------------------------------
2107     Capturing subpattern count = 0
2108     Options: anchored
2109     No first char
2110     No need char
2111    
2112 ph10 161 /^[[:xdigit:]]/DZ
2113 nigel 43 ------------------------------------------------------------------
2114 ph10 192 Bra
2115 ph10 161 ^
2116     [0-9A-Fa-f]
2117     Ket
2118     End
2119 nigel 43 ------------------------------------------------------------------
2120     Capturing subpattern count = 0
2121     Options: anchored
2122     No first char
2123     No need char
2124    
2125 ph10 161 /^[[:word:]]/DZ
2126 nigel 43 ------------------------------------------------------------------
2127 ph10 192 Bra
2128 ph10 161 ^
2129     [0-9A-Z_a-z]
2130     Ket
2131     End
2132 nigel 43 ------------------------------------------------------------------
2133     Capturing subpattern count = 0
2134     Options: anchored
2135     No first char
2136     No need char
2137    
2138 ph10 161 /^[[:^cntrl:]]/DZ
2139 nigel 43 ------------------------------------------------------------------
2140 ph10 192 Bra
2141 ph10 161 ^
2142 ph10 265 [ -~\x80-\xff] (neg)
2143 ph10 161 Ket
2144     End
2145 nigel 43 ------------------------------------------------------------------
2146     Capturing subpattern count = 0
2147     Options: anchored
2148     No first char
2149     No need char
2150    
2151 ph10 161 /^[12[:^digit:]]/DZ
2152 nigel 43 ------------------------------------------------------------------
2153 ph10 192 Bra
2154 ph10 161 ^
2155 ph10 265 [\x00-/12:-\xff] (neg)
2156 ph10 161 Ket
2157     End
2158 nigel 43 ------------------------------------------------------------------
2159     Capturing subpattern count = 0
2160     Options: anchored
2161     No first char
2162     No need char
2163    
2164 ph10 161 /^[[:^blank:]]/DZ
2165 nigel 63 ------------------------------------------------------------------
2166 ph10 192 Bra
2167 ph10 161 ^
2168 ph10 265 [\x00-\x08\x0a-\x1f!-\xff] (neg)
2169 ph10 161 Ket
2170     End
2171 nigel 63 ------------------------------------------------------------------
2172     Capturing subpattern count = 0
2173     Options: anchored
2174     No first char
2175     No need char
2176    
2177 ph10 161 /[01[:alpha:]%]/DZ
2178 nigel 43 ------------------------------------------------------------------
2179 ph10 192 Bra
2180 ph10 161 [%01A-Za-z]
2181     Ket
2182     End
2183 nigel 43 ------------------------------------------------------------------
2184     Capturing subpattern count = 0
2185     No options
2186     No first char
2187     No need char
2188    
2189 nigel 93 /[[.ch.]]/I
2190 nigel 43 Failed: POSIX collating elements are not supported at offset 1
2191    
2192 nigel 93 /[[=ch=]]/I
2193 nigel 43 Failed: POSIX collating elements are not supported at offset 1
2194    
2195 nigel 93 /[[:rhubarb:]]/I
2196 nigel 43 Failed: unknown POSIX class name at offset 3
2197    
2198 nigel 93 /[[:upper:]]/Ii
2199 nigel 43 Capturing subpattern count = 0
2200     Options: caseless
2201     No first char
2202     No need char
2203     A
2204     0: A
2205 ph10 102 a
2206 nigel 43 0: a
2207 ph10 102
2208 nigel 93 /[[:lower:]]/Ii
2209 nigel 43 Capturing subpattern count = 0
2210     Options: caseless
2211     No first char
2212     No need char
2213     A
2214     0: A
2215 ph10 102 a
2216 nigel 43 0: a
2217    
2218 nigel 93 /((?-i)[[:lower:]])[[:lower:]]/Ii
2219 nigel 43 Capturing subpattern count = 1
2220     Options: caseless
2221     No first char
2222     No need char
2223     ab
2224     0: ab
2225     1: a
2226     aB
2227     0: aB
2228     1: a
2229     *** Failers
2230     0: ai
2231     1: a
2232     Ab
2233     No match
2234 ph10 102 AB
2235 nigel 43 No match
2236    
2237 nigel 93 /[\200-\110]/I
2238 nigel 49 Failed: range out of order in character class at offset 9
2239    
2240 nigel 93 /^(?(0)f|b)oo/I
2241 nigel 91 Failed: invalid condition (?(0) at offset 6
2242 nigel 51
2243 nigel 93 /This one's here because of the large output vector needed/I
2244 nigel 53 Capturing subpattern count = 0
2245     No options
2246     First char = 'T'
2247     Need char = 'd'
2248    
2249 nigel 93 /(\d+(?:\s|$))(\d+(?:\s|$))(\d+(?:\s|$))(\d+(?:\s|$))(\d+(?:\s|$))(\d+(?:\s|$))(\d+(?:\s|$))(\d+(?:\s|$))(\d+(?:\s|$))(\d+(?:\s|$))(\d+(?:\s|$))(\d+(?:\s|$))(\d+(?:\s|$))(\d+(?:\s|$))(\d+(?:\s|$))(\d+(?:\s|$))(\d+(?:\s|$))(\d+(?:\s|$))(\d+(?:\s|$))(\d+(?:\s|$))(\d+(?:\s|$))(\d+(?:\s|$))(\d+(?:\s|$))(\d+(?:\s|$))(\d+(?:\s|$))(\d+(?:\s|$))(\d+(?:\s|$))(\d+(?:\s|$))(\d+(?:\s|$))(\d+(?:\s|$))(\d+(?:\s|$))(\d+(?:\s|$))(\d+(?:\s|$))(\d+(?:\s|$))(\d+(?:\s|$))(\d+(?:\s|$))(\d+(?:\s|$))(\d+(?:\s|$))(\d+(?:\s|$))(\d+(?:\s|$))(\d+(?:\s|$))(\d+(?:\s|$))(\d+(?:\s|$))(\d+(?:\s|$))(\d+(?:\s|$))(\d+(?:\s|$))(\d+(?:\s|$))(\d+(?:\s|$))(\d+(?:\s|$))(\d+(?:\s|$))(\d+(?:\s|$))(\d+(?:\s|$))(\d+(?:\s|$))(\d+(?:\s|$))(\d+(?:\s|$))(\d+(?:\s|$))(\d+(?:\s|$))(\d+(?:\s|$))(\d+(?:\s|$))(\d+(?:\s|$))(\d+(?:\s|$))(\d+(?:\s|$))(\d+(?:\s|$))(\d+(?:\s|$))(\d+(?:\s|$))(\d+(?:\s|$))(\d+(?:\s|$))(\d+(?:\s|$))(\d+(?:\s|$))(\d+(?:\s|$))(\d+(?:\s|$))(\d+(?:\s|$))(\d+(?:\s|$))(\d+(?:\s|$))(\d+(?:\s|$))(\d+(?:\s|$))(\d+(?:\s|$))(\d+(?:\s|$))(\d+(?:\s|$))(\d+(?:\s|$))(\d+(?:\s|$))(\d+(?:\s|$))(\d+(?:\s|$))(\d+(?:\s|$))(\d+(?:\s|$))(\d+(?:\s|$))(\d+(?:\s|$))(\d+(?:\s|$))(\d+(?:\s|$))(\d+(?:\s|$))(\d+(?:\s|$))(\d+(?:\s|$))(\d+(?:\s|$))(\d+(?:\s|$))(\d+(?:\s|$))(\d+(?:\s|$))(\d+(?:\s|$))(\d+(?:\s|$))(\d+(?:\s|$))(\d+(?:\s|$))(\d+(?:\s|$))(\d+(?:\s|$))(\d+(?:\s|$))(\d+(?:\s|$))(\d+(?:\s|$))(\d+(?:\s|$))(\d+(?:\s|$))(\d+(?:\s|$))(\d+(?:\s|$))(\d+(?:\s|$))(\d+(?:\s|$))(\d+(?:\s|$))(\d+(?:\s|$))(\d+(?:\s|$))(\d+(?:\s|$))(\d+(?:\s|$))(\d+(?:\s|$))(\d+(?:\s|$))(\d+(?:\s|$))(\d+(?:\s|$))(\d+(?:\s|$))(\d+(?:\s|$))(\d+(?:\s|$))(\d+(?:\s|$))(\d+(?:\s|$))(\d+(?:\s|$))(\d+(?:\s|$))(\d+(?:\s|$))(\d+(?:\s|$))(\d+(?:\s|$))(\d+(?:\s|$))(\d+(?:\s|$))(\d+(?:\s|$))(\d+(?:\s|$))(\d+(?:\s|$))(\d+(?:\s|$))(\d+(?:\s|$))(\d+(?:\s|$))(\d+(?:\s|$))(\d+(?:\s|$))(\d+(?:\s|$))(\d+(?:\s|$))(\d+(?:\s|$))(\d+(?:\s|$))(\d+(?:\s|$))(\d+(?:\s|$))(\d+(?:\s|$))(\d+(?:\s|$))(\d+(?:\s|$))(\d+(?:\s|$))(\d+(?:\s|$))(\d+(?:\s|$))(\d+(?:\s|$))(\d+(?:\s|$))(\d+(?:\s|$))(\d+(?:\s|$))(\d+(?:\s|$))(\d+(?:\s|$))(\d+(?:\s|$))(\d+(?:\s|$))(\d+(?:\s|$))(\d+(?:\s|$))(\d+(?:\s|$))(\d+(?:\s|$))(\d+(?:\s|$))(\d+(?:\s|$))(\d+(?:\s|$))(\d+(?:\s|$))(\d+(?:\s|$))(\d+(?:\s|$))(\d+(?:\s|$))(\d+(?:\s|$))(\d+(?:\s|$))(\d+(?:\s|$))(\d+(?:\s|$))(\d+(?:\s|$))(\d+(?:\s|$))(\d+(?:\s|$))(\d+(?:\s|$))(\d+(?:\s|$))(\d+(?:\s|$))(\d+(?:\s|$))(\d+(?:\s|$))(\d+(?:\s|$))(\d+(?:\s|$))(\d+(?:\s|$))(\d+(?:\s|$))(\d+(?:\s|$))(\d+(?:\s|$))(\d+(?:\s|$))(\d+(?:\s|$))(\d+(?:\s|$))(\d+(?:\s|$))(\d+(?:\s|$))(\d+(?:\s|$))(\d+(?:\s|$))(\d+(?:\s|$))(\d+(?:\s|$))(\d+(?:\s|$))(\d+(?:\s|$))(\d+(?:\s|$))(\d+(?:\s|$))(\d+(?:\s|$))(\d+(?:\s|$))(\d+(?:\s|$))(\d+(?:\s|$))(\d+(?:\s|$))(\d+(?:\s|$))(\d+(?:\s|$))(\d+(?:\s|$))(\d+(?:\s|$))(\d+(?:\s|$))(\d+(?:\s|$))(\d+(?:\s|$))(\d+(?:\s|$))(\d+(?:\s|$))(\d+(?:\s|$))(\d+(?:\s|$))(\d+(?:\s|$))(\d+(?:\s|$))(\d+(?:\s|$))(\d+(?:\s|$))(\d+(?:\s|$))(\d+(?:\s|$))(\d+(?:\s|$))(\d+(?:\s|$))(\d+(?:\s|$))(\d+(?:\s|$))(\d+(?:\s|$))(\d+(?:\s|$))(\d+(?:\s|$))(\d+(?:\s|$))(\d+(?:\s|$))(\d+(?:\s|$))(\d+(?:\s|$))(\d+(?:\s|$))(\d+(?:\s|$))(\d+(?:\s|$))(\d+(?:\s|$))(\d+(?:\s|$))(\d+(?:\s|$))(\d+(?:\s|$))(\d+(?:\s|$))(\d+(?:\s|$))(\d+(?:\s|$))(\d+(?:\s|$))(\d+(?:\s|$))(\d+(?:\s|$))(\d+(?:\s|$))(\d+(?:\s|$))(\d+(?:\s|$))(\d+(?:\s|$))(\d+(?:\s|$))(\d+(?:\s|$))(\d+(?:\s|$))(\d+(?:\s|$))(\d+(?:\s|$))(\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
2250 nigel 53 Capturing subpattern count = 271
2251     Max back reference = 270
2252 nigel 75 Partial matching not supported
2253 nigel 53 No options
2254     No first char
2255     No need char
2256     \O900 1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 23 24 25 26 27 28 29 30 31 32 33 34 35 36 37 38 39 40 41 42 43 44 45 46 47 48 49 50 51 52 53 54 55 56 57 58 59 60 61 62 63 64 65 66 67 68 69 70 71 72 73 74 75 76 77 78 79 80 81 82 83 84 85 86 87 88 89 90 91 92 93 94 95 96 97 98 99 100 101 102 103 104 105 106 107 108 109 110 111 112 113 114 115 116 117 118 119 120 121 122 123 124 125 126 127 128 129 130 131 132 133 134 135 136 137 138 139 140 141 142 143 144 145 146 147 148 149 150 151 152 153 154 155 156 157 158 159 160 161 162 163 164 165 166 167 168 169 170 171 172 173 174 175 176 177 178 179 180 181 182 183 184 185 186 187 188 189 190 191 192 193 194 195 196 197 198 199 200 201 202 203 204 205 206 207 208 209 210 211 212 213 214 215 216 217 218 219 220 221 222 223 224 225 226 227 228 229 230 231 232 233 234 235 236 237 238 239 240 241 242 243 244 245 246 247 248 249 250 251 252 253 254 255 256 257 258 259 260 261 262 263 264 265 266 267 268 269 ABC ABC
2257     0: 1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 23 24 25 26 27 28 29 30 31 32 33 34 35 36 37 38 39 40 41 42 43 44 45 46 47 48 49 50 51 52 53 54 55 56 57 58 59 60 61 62 63 64 65 66 67 68 69 70 71 72 73 74 75 76 77 78 79 80 81 82 83 84 85 86 87 88 89 90 91 92 93 94 95 96 97 98 99 100 101 102 103 104 105 106 107 108 109 110 111 112 113 114 115 116 117 118 119 120 121 122 123 124 125 126 127 128 129 130 131 132 133 134 135 136 137 138 139 140 141 142 143 144 145 146 147 148 149 150 151 152 153 154 155 156 157 158 159 160 161 162 163 164 165 166 167 168 169 170 171 172 173 174 175 176 177 178 179 180 181 182 183 184 185 186 187 188 189 190 191 192 193 194 195 196 197 198 199 200 201 202 203 204 205 206 207 208 209 210 211 212 213 214 215 216 217 218 219 220 221 222 223 224 225 226 227 228 229 230 231 232 233 234 235 236 237 238 239 240 241 242 243 244 245 246 247 248 249 250 251 252 253 254 255 256 257 258 259 260 261 262 263 264 265 266 267 268 269 ABC ABC
2258     1: 1
2259     2: 2
2260     3: 3
2261     4: 4
2262     5: 5
2263     6: 6
2264     7: 7
2265     8: 8
2266     9: 9
2267     10: 10
2268     11: 11
2269     12: 12
2270     13: 13
2271     14: 14
2272     15: 15
2273     16: 16
2274     17: 17
2275     18: 18
2276     19: 19
2277     20: 20
2278     21: 21
2279     22: 22
2280     23: 23
2281     24: 24
2282     25: 25
2283     26: 26
2284     27: 27
2285     28: 28
2286     29: 29
2287     30: 30
2288     31: 31
2289     32: 32
2290     33: 33
2291     34: 34
2292     35: 35
2293     36: 36
2294     37: 37
2295     38: 38
2296     39: 39
2297     40: 40
2298     41: 41
2299     42: 42
2300     43: 43
2301     44: 44
2302     45: 45
2303     46: 46
2304     47: 47
2305     48: 48
2306     49: 49
2307     50: 50
2308     51: 51
2309     52: 52
2310     53: 53
2311     54: 54
2312     55: 55
2313     56: 56
2314     57: 57
2315     58: 58
2316     59: 59
2317     60: 60
2318     61: 61
2319     62: 62
2320     63: 63
2321     64: 64
2322     65: 65
2323     66: 66
2324     67: 67
2325     68: 68
2326     69: 69
2327     70: 70
2328     71: 71
2329     72: 72
2330     73: 73
2331     74: 74
2332     75: 75
2333     76: 76
2334     77: 77
2335     78: 78
2336     79: 79
2337     80: 80
2338     81: 81
2339     82: 82
2340     83: 83
2341     84: 84
2342     85: 85
2343     86: 86
2344     87: 87
2345     88: 88
2346     89: 89
2347     90: 90
2348     91: 91
2349     92: 92
2350     93: 93
2351     94: 94
2352     95: 95
2353     96: 96
2354     97: 97
2355     98: 98
2356     99: 99
2357     100: 100
2358     101: 101
2359     102: 102
2360     103: 103
2361     104: 104
2362     105: 105
2363     106: 106
2364     107: 107
2365     108: 108
2366     109: 109
2367     110: 110
2368     111: 111
2369     112: 112
2370     113: 113
2371     114: 114
2372     115: 115
2373     116: 116
2374     117: 117
2375     118: 118
2376     119: 119
2377     120: 120
2378     121: 121
2379     122: 122
2380     123: 123
2381     124: 124
2382     125: 125
2383     126: 126
2384     127: 127
2385     128: 128
2386     129: 129
2387     130: 130
2388     131: 131
2389     132: 132
2390     133: 133
2391     134: 134
2392     135: 135
2393     136: 136
2394     137: 137
2395     138: 138
2396     139: 139
2397     140: 140
2398     141: 141
2399     142: 142
2400     143: 143
2401     144: 144
2402     145: 145
2403     146: 146
2404     147: 147
2405     148: 148
2406     149: 149
2407     150: 150
2408     151: 151
2409     152: 152
2410     153: 153
2411     154: 154
2412     155: 155
2413     156: 156
2414     157: 157
2415     158: 158
2416     159: 159
2417     160: 160
2418     161: 161
2419     162: 162
2420     163: 163
2421     164: 164
2422     165: 165
2423     166: 166
2424     167: 167
2425     168: 168
2426     169: 169
2427     170: 170
2428     171: 171
2429     172: 172
2430     173: 173
2431     174: 174
2432     175: 175
2433     176: 176
2434     177: 177
2435     178: 178
2436     179: 179
2437     180: 180
2438     181: 181
2439     182: 182
2440     183: 183
2441     184: 184
2442     185: 185
2443     186: 186
2444     187: 187
2445     188: 188
2446     189: 189
2447     190: 190
2448     191: 191
2449     192: 192
2450     193: 193
2451     194: 194
2452     195: 195
2453     196: 196
2454     197: 197
2455     198: 198
2456     199: 199
2457     200: 200
2458     201: 201
2459     202: 202
2460     203: 203
2461     204: 204
2462     205: 205
2463     206: 206
2464     207: 207
2465     208: 208
2466     209: 209
2467     210: 210
2468     211: 211
2469     212: 212
2470     213: 213
2471     214: 214
2472     215: 215
2473     216: 216
2474     217: 217
2475     218: 218
2476     219: 219
2477     220: 220
2478     221: 221
2479     222: 222
2480     223: 223
2481     224: 224
2482     225: 225
2483     226: 226
2484     227: 227
2485     228: 228
2486     229: 229
2487     230: 230
2488     231: 231
2489     232: 232
2490     233: 233
2491     234: 234
2492     235: 235
2493     236: 236
2494     237: 237
2495     238: 238
2496     239: 239
2497     240: 240
2498     241: 241
2499     242: 242
2500     243: 243
2501     244: 244
2502     245: 245
2503     246: 246
2504     247: 247
2505     248: 248
2506     249: 249
2507     250: 250
2508     251: 251
2509     252: 252
2510     253: 253
2511     254: 254
2512     255: 255
2513     256: 256
2514     257: 257
2515     258: 258
2516     259: 259
2517     260: 260
2518     261: 261
2519     262: 262
2520     263: 263
2521     264: 264
2522     265: 265
2523     266: 266
2524     267: 267
2525     268: 268
2526     269: 269
2527     270: ABC
2528     271: ABC
2529    
2530 nigel 93 /This one's here because Perl does this differently and PCRE can't at present/I
2531 nigel 53 Capturing subpattern count = 0
2532     No options
2533     First char = 'T'
2534     Need char = 't'
2535    
2536 nigel 93 /(main(O)?)+/I
2537 nigel 53 Capturing subpattern count = 2
2538     No options
2539     First char = 'm'
2540     Need char = 'n'
2541     mainmain
2542     0: mainmain
2543     1: main
2544     mainOmain
2545     0: mainOmain
2546     1: main
2547     2: O
2548 ph10 102
2549 nigel 93 /These are all cases where Perl does it differently (nested captures)/I
2550 nigel 63 Capturing subpattern count = 1
2551     No options
2552     First char = 'T'
2553     Need char = 's'
2554    
2555 nigel 93 /^(a(b)?)+$/I
2556 nigel 63 Capturing subpattern count = 2
2557     Options: anchored
2558     No first char
2559 nigel 65 No need char
2560 nigel 63 aba
2561     0: aba
2562     1: a
2563     2: b
2564 ph10 102
2565 nigel 93 /^(aa(bb)?)+$/I
2566 nigel 63 Capturing subpattern count = 2
2567     Options: anchored
2568     No first char
2569 nigel 65 No need char
2570 ph10 102 aabbaa
2571 nigel 63 0: aabbaa
2572     1: aa
2573     2: bb
2574 ph10 102
2575 nigel 93 /^(aa|aa(bb))+$/I
2576 nigel 63 Capturing subpattern count = 2
2577     Options: anchored
2578     No first char
2579 nigel 65 No need char
2580 ph10 102 aabbaa
2581 nigel 63 0: aabbaa
2582     1: aa
2583     2: bb
2584 ph10 102
2585 nigel 93 /^(aa(bb)??)+$/I
2586 nigel 63 Capturing subpattern count = 2
2587     Options: anchored
2588     No first char
2589 nigel 65 No need char
2590 ph10 102 aabbaa
2591 nigel 63 0: aabbaa
2592     1: aa
2593     2: bb
2594 ph10 102
2595 nigel 93 /^(?:aa(bb)?)+$/I
2596 nigel 63 Capturing subpattern count = 1
2597     Options: anchored
2598     No first char
2599 nigel 65 No need char
2600 ph10 102 aabbaa
2601 nigel 63 0: aabbaa
2602     1: bb
2603 ph10 102
2604 nigel 93 /^(aa(b(b))?)+$/I
2605 nigel 63 Capturing subpattern count = 3
2606     Options: anchored
2607     No first char
2608 nigel 65 No need char
2609 ph10 102 aabbaa
2610 nigel 63 0: aabbaa
2611     1: aa
2612     2: bb
2613     3: b
2614    
2615 nigel 93 /^(?:aa(b(b))?)+$/I
2616 nigel 63 Capturing subpattern count = 2
2617     Options: anchored
2618     No first char
2619 nigel 65 No need char
2620 ph10 102 aabbaa
2621 nigel 63 0: aabbaa
2622     1: bb
2623     2: b
2624    
2625 nigel 93 /^(?:aa(b(?:b))?)+$/I
2626 nigel 63 Capturing subpattern count = 1
2627     Options: anchored
2628     No first char
2629 nigel 65 No need char
2630 ph10 102 aabbaa
2631 nigel 63 0: aabbaa
2632     1: bb
2633    
2634 nigel 93 /^(?:aa(bb(?:b))?)+$/I
2635 nigel 63 Capturing subpattern count = 1
2636     Options: anchored
2637     No first char
2638 nigel 65 No need char
2639 ph10 102 aabbbaa
2640 nigel 63 0: aabbbaa
2641     1: bbb
2642 ph10 102
2643 nigel 93 /^(?:aa(b(?:bb))?)+$/I
2644 nigel 63 Capturing subpattern count = 1
2645     Options: anchored
2646     No first char
2647 nigel 65 No need char
2648 ph10 102 aabbbaa
2649 nigel 63 0: aabbbaa
2650     1: bbb
2651    
2652 nigel 93 /^(?:aa(?:b(b))?)+$/I
2653 nigel 63 Capturing subpattern count = 1
2654     Options: anchored
2655     No first char
2656 nigel 65 No need char
2657 ph10 102 aabbaa
2658 nigel 63 0: aabbaa
2659     1: b
2660    
2661 nigel 93 /^(?:aa(?:b(bb))?)+$/I
2662 nigel 63 Capturing subpattern count = 1
2663     Options: anchored
2664     No first char
2665 nigel 65 No need char
2666 ph10 102 aabbbaa
2667 nigel 63 0: aabbbaa
2668     1: bb
2669    
2670 nigel 93 /^(aa(b(bb))?)+$/I
2671 nigel 63 Capturing subpattern count = 3
2672     Options: anchored
2673     No first char
2674 nigel 65 No need char
2675 ph10 102 aabbbaa
2676 nigel 63 0: aabbbaa
2677     1: aa
2678     2: bbb
2679     3: bb
2680    
2681 nigel 93 /^(aa(bb(bb))?)+$/I
2682 nigel 63 Capturing subpattern count = 3
2683     Options: anchored
2684     No first char
2685 nigel 65 No need char
2686 ph10 102 aabbbbaa
2687 nigel 63 0: aabbbbaa
2688     1: aa
2689     2: bbbb
2690     3: bb
2691    
2692 ph10 102 /--------------------------------------------------------------------/I
2693 nigel 63 Capturing subpattern count = 0
2694     No options
2695     First char = '-'
2696     Need char = '-'
2697 ph10 102
2698 ph10 162 /#/IxDZ
2699 nigel 63 ------------------------------------------------------------------
2700 ph10 192 Bra
2701 ph10 161 Ket
2702     End
2703 nigel 63 ------------------------------------------------------------------
2704     Capturing subpattern count = 0
2705     Options: extended
2706     No first char
2707     No need char
2708    
2709 ph10 162 /a#/IxDZ
2710 nigel 63 ------------------------------------------------------------------
2711 ph10 192 Bra
2712 ph10 161 a
2713     Ket
2714     End
2715 nigel 63 ------------------------------------------------------------------
2716     Capturing subpattern count = 0
2717     Options: extended
2718     First char = 'a'
2719     No need char
2720    
2721 ph10 161 /[\s]/DZ
2722 nigel 63 ------------------------------------------------------------------
2723 ph10 192 Bra
2724 ph10 161 [\x09\x0a\x0c\x0d ]
2725     Ket
2726     End
2727 nigel 63 ------------------------------------------------------------------
2728     Capturing subpattern count = 0
2729     No options
2730     No first char
2731     No need char
2732    
2733 ph10 161 /[\S]/DZ
2734 nigel 63 ------------------------------------------------------------------
2735 ph10 192 Bra
2736 ph10 264 [\x00-\x08\x0b\x0e-\x1f!-\xff] (neg)
2737 ph10 161 Ket
2738     End
2739 nigel 63 ------------------------------------------------------------------
2740     Capturing subpattern count = 0
2741     No options
2742     No first char
2743     No need char
2744    
2745 ph10 161 /a(?i)b/DZ
2746 nigel 63 ------------------------------------------------------------------
2747 ph10 192 Bra
2748 ph10 161 a
2749     01 Opt
2750     NC b
2751     Ket
2752     End
2753 nigel 63 ------------------------------------------------------------------
2754     Capturing subpattern count = 0
2755     No options
2756     First char = 'a'
2757     Need char = 'b' (caseless)
2758     ab
2759     0: ab
2760     aB
2761     0: aB
2762 ph10 102 *** Failers
2763 nigel 63 No match
2764 ph10 102 AB
2765 nigel 63 No match
2766    
2767 ph10 161 /(a(?i)b)/DZ
2768 nigel 63 ------------------------------------------------------------------
2769 ph10 192 Bra
2770     CBra 1
2771 ph10 161 a
2772     01 Opt
2773     NC b
2774     Ket
2775     00 Opt
2776     Ket
2777     End
2778 nigel 63 ------------------------------------------------------------------
2779     Capturing subpattern count = 1
2780     No options
2781     First char = 'a'
2782     Need char = 'b' (caseless)
2783     ab
2784     0: ab
2785     1: ab
2786     aB
2787     0: aB
2788     1: aB
2789 ph10 102 *** Failers
2790 nigel 63 No match
2791 ph10 102 AB
2792 nigel 63 No match
2793 ph10 102
2794 ph10 161 / (?i)abc/IxDZ
2795 nigel 63 ------------------------------------------------------------------
2796 ph10 192 Bra
2797 ph10 161 NC abc
2798     Ket
2799     End
2800 nigel 63 ------------------------------------------------------------------
2801     Capturing subpattern count = 0
2802     Options: caseless extended
2803     First char = 'a' (caseless)
2804     Need char = 'c' (caseless)
2805    
2806     /#this is a comment
2807 ph10 161 (?i)abc/IxDZ
2808 nigel 63 ------------------------------------------------------------------
2809 ph10 192 Bra
2810 ph10 161 NC abc
2811     Ket
2812     End
2813 nigel 63 ------------------------------------------------------------------
2814     Capturing subpattern count = 0
2815     Options: caseless extended
2816     First char = 'a' (caseless)
2817     Need char = 'c' (caseless)
2818    
2819 ph10 161 /123456789012345678901234567890123456789012345678901234567890123456789012345678901234567890123456789012345678901234567890123456789012345678901234567890123456789012345678901234567890123456789012345678901234567890123456789012345678901234567890123456789012345678901234567890123456789012345678901234567890/DZ
2820 nigel 63 ------------------------------------------------------------------
2821 ph10 192 Bra
2822 ph10 161 123456789012345678901234567890123456789012345678901234567890123456789012345678901234567890123456789012345678901234567890123456789012345678901234567890123456789012345678901234567890123456789012345678901234567890123456789012345678901234567890123456789012345678901234567890123456789012345678901234567890
2823     Ket
2824     End
2825 nigel 63 ------------------------------------------------------------------
2826     Capturing subpattern count = 0
2827     No options
2828     First char = '1'
2829     Need char = '0'
2830    
2831 ph10 161 /\Q123456789012345678901234567890123456789012345678901234567890123456789012345678901234567890123456789012345678901234567890123456789012345678901234567890123456789012345678901234567890123456789012345678901234567890123456789012345678901234567890123456789012345678901234567890123456789012345678901234567890/DZ
2832 nigel 63 ------------------------------------------------------------------
2833 ph10 192 Bra
2834 ph10 161 123456789012345678901234567890123456789012345678901234567890123456789012345678901234567890123456789012345678901234567890123456789012345678901234567890123456789012345678901234567890123456789012345678901234567890123456789012345678901234567890123456789012345678901234567890123456789012345678901234567890
2835     Ket
2836     End
2837 nigel 63 ------------------------------------------------------------------
2838     Capturing subpattern count = 0
2839     No options
2840     First char = '1'
2841     Need char = '0'
2842    
2843 ph10 161 /\Q\E/DZ
2844 nigel 63 ------------------------------------------------------------------
2845 ph10 192 Bra
2846 ph10 161 Ket
2847     End
2848 nigel 63 ------------------------------------------------------------------
2849     Capturing subpattern count = 0
2850     No options
2851     No first char
2852     No need char
2853     \
2854     0:
2855    
2856 ph10 161 /\Q\Ex/DZ
2857 nigel 63 ------------------------------------------------------------------
2858 ph10 192 Bra
2859 ph10 161 x
2860     Ket
2861     End
2862 nigel 63 ------------------------------------------------------------------
2863     Capturing subpattern count = 0
2864     No options
2865     First char = 'x'
2866     No need char
2867    
2868 ph10 161 / \Q\E/DZ
2869 nigel 63 ------------------------------------------------------------------
2870 ph10 192 Bra
2871 ph10 161
2872     Ket
2873     End
2874 nigel 63 ------------------------------------------------------------------
2875     Capturing subpattern count = 0
2876     No options
2877     First char = ' '
2878     No need char
2879    
2880 ph10 161 /a\Q\E/DZ
2881 nigel 63 ------------------------------------------------------------------
2882 ph10 192 Bra
2883 ph10 161 a
2884     Ket
2885     End
2886 nigel 63 ------------------------------------------------------------------
2887     Capturing subpattern count = 0
2888     No options
2889     First char = 'a'
2890     No need char
2891     abc
2892     0: a
2893     bca
2894     0: a
2895 ph10 102 bac
2896 nigel 63 0: a
2897    
2898 ph10 161 /a\Q\Eb/DZ
2899 nigel 63 ------------------------------------------------------------------
2900 ph10 192 Bra
2901 ph10 161 ab
2902     Ket
2903     End
2904 nigel 63 ------------------------------------------------------------------
2905     Capturing subpattern count = 0
2906     No options
2907     First char = 'a'
2908     Need char = 'b'
2909     abc
2910     0: ab
2911    
2912 ph10 161 /\Q\Eabc/DZ
2913 nigel 63 ------------------------------------------------------------------
2914 ph10 192 Bra
2915 ph10 161 abc
2916     Ket
2917     End
2918 nigel 63 ------------------------------------------------------------------
2919     Capturing subpattern count = 0
2920     No options
2921     First char = 'a'
2922     Need char = 'c'
2923    
2924 ph10 161 /x*+\w/DZ
2925 nigel 63 ------------------------------------------------------------------
2926 ph10 192 Bra
2927 ph10 161 x*+
2928     \w
2929     Ket
2930     End
2931 nigel 63 ------------------------------------------------------------------
2932     Capturing subpattern count = 0
2933 nigel 75 Partial matching not supported
2934 nigel 63 No options
2935     No first char
2936     No need char
2937     *** Failers
2938     0: F
2939     xxxxx
2940     No match
2941 ph10 102
2942 ph10 161 /x?+/DZ
2943 nigel 63 ------------------------------------------------------------------
2944 ph10 192 Bra
2945 ph10 161 x?+
2946     Ket
2947     End
2948 nigel 63 ------------------------------------------------------------------
2949     Capturing subpattern count = 0
2950     No options
2951     No first char
2952     No need char
2953    
2954 ph10 161 /x++/DZ
2955 nigel 63 ------------------------------------------------------------------
2956 ph10 192 Bra
2957 ph10 161 x++
2958     Ket
2959     End
2960 nigel 63 ------------------------------------------------------------------
2961     Capturing subpattern count = 0
2962 nigel 75 Partial matching not supported
2963 nigel 63 No options
2964     First char = 'x'
2965     No need char
2966    
2967 ph10 161 /x{1,3}+/DZ
2968 nigel 63 ------------------------------------------------------------------
2969 ph10 192 Bra
2970 ph10 161 Once
2971     x
2972     x{0,2}
2973     Ket
2974     Ket
2975     End
2976 nigel 63 ------------------------------------------------------------------
2977     Capturing subpattern count = 0
2978 nigel 75 Partial matching not supported
2979 nigel 63 No options
2980     First char = 'x'
2981     No need char
2982    
2983 ph10 161 /(x)*+/DZ
2984 nigel 63 ------------------------------------------------------------------
2985 ph10 192 Bra
2986 ph10 161 Once
2987     Brazero
2988 ph10 192 CBra 1
2989 ph10 161 x
2990     KetRmax
2991     Ket
2992     Ket
2993     End
2994 nigel 63 ------------------------------------------------------------------
2995     Capturing subpattern count = 1
2996     No options
2997     No first char
2998     No need char
2999    
3000 nigel 93 /^(\w++|\s++)*$/I
3001 nigel 63 Capturing subpattern count = 1
3002 nigel 75 Partial matching not supported
3003 nigel 63 Options: anchored
3004     No first char
3005     No need char
3006     now is the time for all good men to come to the aid of the party
3007     0: now is the time for all good men to come to the aid of the party
3008     1: party
3009     *** Failers
3010     No match
3011     this is not a line with only words and spaces!
3012     No match
3013 ph10 102
3014 nigel 93 /(\d++)(\w)/I
3015 nigel 63 Capturing subpattern count = 2
3016 nigel 75 Partial matching not supported
3017 nigel 63 No options
3018     No first char
3019     No need char
3020     12345a
3021     0: 12345a
3022     1: 12345
3023     2: a
3024     *** Failers
3025     No match
3026 ph10 102 12345+
3027 nigel 63 No match
3028    
3029 nigel 93 /a++b/I
3030 nigel 63 Capturing subpattern count = 0
3031 nigel 75 Partial matching not supported
3032 nigel 63 No options
3033     First char = 'a'
3034     Need char = 'b'
3035     aaab
3036     0: aaab
3037    
3038 nigel 93 /(a++b)/I
3039 nigel 63 Capturing subpattern count = 1
3040 nigel 75 Partial matching not supported
3041 nigel 63 No options
3042     First char = 'a'
3043     Need char = 'b'
3044     aaab
3045     0: aaab
3046     1: aaab
3047    
3048 nigel 93 /(a++)b/I
3049 nigel 63 Capturing subpattern count = 1
3050 nigel 75 Partial matching not supported
3051 nigel 63 No options
3052     First char = 'a'
3053     Need char = 'b'
3054     aaab
3055     0: aaab
3056     1: aaa
3057    
3058 nigel 93 /([^()]++|\([^()]*\))+/I
3059 nigel 63 Capturing subpattern count = 1
3060 nigel 75 Partial matching not supported
3061 nigel 63 No options
3062     No first char
3063     No need char
3064     ((abc(ade)ufh()()x
3065     0: abc(ade)ufh()()x
3066     1: x
3067 ph10 102
3068     /\(([^()]++|\([^()]+\))+\)/I
3069 nigel 63 Capturing subpattern count = 1
3070 nigel 75 Partial matching not supported
3071 nigel 63 No options
3072     First char = '('
3073     Need char = ')'
3074     (abc)
3075     0: (abc)
3076     1: abc
3077     (abc(def)xyz)
3078     0: (abc(def)xyz)
3079     1: xyz
3080     *** Failers
3081     No match
3082 ph10 102 ((()aaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaa
3083 nigel 63 No match
3084    
3085 ph10 161 /(abc){1,3}+/DZ
3086 nigel 63 ------------------------------------------------------------------
3087 ph10 192 Bra
3088 ph10 161 Once
3089 ph10 192 CBra 1
3090 ph10 161 abc
3091     Ket
3092     Brazero
3093 ph10 192 Bra
3094     CBra 1
3095 ph10 161 abc
3096     Ket
3097     Brazero
3098 ph10 192 CBra 1
3099 ph10 161 abc
3100     Ket
3101     Ket
3102     Ket
3103     Ket
3104     End
3105 nigel 63 ------------------------------------------------------------------
3106     Capturing subpattern count = 1
3107     No options
3108     First char = 'a'
3109     Need char = 'c'
3110    
3111 nigel 93 /a+?+/I
3112 nigel 63 Failed: nothing to repeat at offset 3
3113    
3114 nigel 93 /a{2,3}?+b/I
3115 nigel 63 Failed: nothing to repeat at offset 7
3116    
3117 nigel 93 /(?U)a+?+/I
3118 nigel 63 Failed: nothing to repeat at offset 7
3119    
3120 nigel 93 /a{2,3}?+b/IU
3121 nigel 63 Failed: nothing to repeat at offset 7
3122    
3123 ph10 161 /x(?U)a++b/DZ
3124 nigel 63 ------------------------------------------------------------------
3125 ph10 192 Bra
3126 ph10 161 x
3127     a++
3128     b
3129     Ket
3130     End
3131 nigel 63 ------------------------------------------------------------------
3132     Capturing subpattern count = 0
3133 nigel 75 Partial matching not supported
3134 nigel 63 No options
3135     First char = 'x'
3136     Need char = 'b'
3137     xaaaab
3138     0: xaaaab
3139    
3140 ph10 161 /(?U)xa++b/DZ
3141 nigel 63 ------------------------------------------------------------------
3142 ph10 192 Bra
3143 ph10 161 x
3144     a++
3145     b
3146     Ket
3147     End
3148 nigel 63 ------------------------------------------------------------------
3149     Capturing subpattern count = 0
3150 nigel 75 Partial matching not supported
3151 nigel 63 Options: ungreedy
3152     First char = 'x'
3153     Need char = 'b'
3154     xaaaab
3155     0: xaaaab
3156    
3157 ph10 161 /^((a+)(?U)([ab]+)(?-U)([bc]+)(\w*))/DZ
3158 nigel 63 ------------------------------------------------------------------
3159 ph10 192 Bra
3160 ph10 161 ^
3161 ph10 192 CBra 1
3162     CBra 2
3163 ph10 161 a+
3164     Ket
3165 ph10 192 CBra 3
3166 ph10 161 [ab]+?
3167     Ket
3168 ph10 192 CBra 4
3169 ph10 161 [bc]+
3170     Ket
3171 ph10 192 CBra 5
3172 ph10 161 \w*
3173     Ket
3174     Ket
3175     Ket
3176     End
3177 nigel 63 ------------------------------------------------------------------
3178     Capturing subpattern count = 5
3179 nigel 75 Partial matching not supported
3180 nigel 63 Options: anchored
3181     No first char
3182 nigel 65 No need char
3183 nigel 63
3184 ph10 161 /^x(?U)a+b/DZ
3185 nigel 63 ------------------------------------------------------------------
3186 ph10 192 Bra
3187 ph10 161 ^
3188     x
3189     a++
3190     b
3191     Ket
3192     End
3193 nigel 63 ------------------------------------------------------------------
3194     Capturing subpattern count = 0
3195 nigel 75 Partial matching not supported
3196 nigel 63 Options: anchored
3197     No first char
3198     Need char = 'b'
3199    
3200 ph10 161 /^x(?U)(a+)b/DZ
3201 nigel 63 ------------------------------------------------------------------
3202 ph10 192 Bra
3203 ph10 161 ^
3204     x
3205 ph10 192 CBra 1
3206 ph10 161 a+?
3207     Ket
3208     b
3209     Ket
3210     End
3211 nigel 63 ------------------------------------------------------------------
3212     Capturing subpattern count = 1
3213 nigel 75 Partial matching not supported
3214 nigel 63 Options: anchored
3215     No first char
3216     Need char = 'b'
3217    
3218 nigel 93 /[.x.]/I
3219 nigel 63 Failed: POSIX collating elements are not supported at offset 0
3220    
3221 nigel 93 /[=x=]/I
3222 nigel 63 Failed: POSIX collating elements are not supported at offset 0
3223    
3224 nigel 93 /[:x:]/I
3225 nigel 63 Failed: POSIX named classes are supported only within a class at offset 0
3226    
3227 nigel 93 /\l/I
3228 nigel 75 Failed: PCRE does not support \L, \l, \N, \U, or \u at offset 1
3229 nigel 63
3230 nigel 93 /\L/I
3231 nigel 75 Failed: PCRE does not support \L, \l, \N, \U, or \u at offset 1
3232 nigel 63
3233 nigel 93 /\N{name}/I
3234 nigel 75 Failed: PCRE does not support \L, \l, \N, \U, or \u at offset 1
3235 nigel 63
3236 nigel 93 /\u/I
3237 nigel 75 Failed: PCRE does not support \L, \l, \N, \U, or \u at offset 1
3238 nigel 63
3239 nigel 93 /\U/I
3240 nigel 75 Failed: PCRE does not support \L, \l, \N, \U, or \u at offset 1
3241 nigel 63
3242 nigel 93 /[/I
3243 nigel 63 Failed: missing terminating ] for character class at offset 1
3244    
3245 nigel 93 /[a-/I
3246 nigel 63 Failed: missing terminating ] for character class at offset 3
3247    
3248 nigel 93 /[[:space:]/I
3249 nigel 63 Failed: missing terminating ] for character class at offset 10
3250    
3251 ph10 162 /[\s]/IDZ
3252 nigel 63 ------------------------------------------------------------------
3253 ph10 192 Bra
3254 ph10 161 [\x09\x0a\x0c\x0d ]
3255     Ket
3256     End
3257 nigel 63 ------------------------------------------------------------------
3258     Capturing subpattern count = 0
3259     No options
3260     No first char
3261     No need char
3262    
3263 ph10 162 /[[:space:]]/IDZ
3264 nigel 63 ------------------------------------------------------------------
3265 ph10 192 Bra
3266 ph10 161 [\x09-\x0d ]
3267     Ket
3268     End
3269 nigel 63 ------------------------------------------------------------------
3270     Capturing subpattern count = 0
3271     No options
3272     No first char
3273     No need char
3274    
3275 ph10 162 /[[:space:]abcde]/IDZ
3276 nigel 63 ------------------------------------------------------------------
3277 ph10 192 Bra
3278 ph10 161 [\x09-\x0d a-e]
3279     Ket
3280     End
3281 nigel 63 ------------------------------------------------------------------
3282     Capturing subpattern count = 0
3283     No options
3284     No first char
3285     No need char
3286    
3287 nigel 93 /< (?: (?(R) \d++ | [^<>]*+) | (?R)) * >/Ix
3288 nigel 63 Capturing subpattern count = 0
3289 nigel 75 Partial matching not supported
3290 nigel 63 Options: extended
3291     First char = '<'
3292     Need char = '>'
3293     <>
3294     0: <>
3295     <abcd>
3296     0: <abcd>
3297     <abc <123> hij>
3298     0: <abc <123> hij>
3299     <abc <def> hij>
3300     0: <def>
3301 ph10 102 <abc<>def>
3302 nigel 63 0: <abc<>def>
3303 ph10 102 <abc<>
3304 nigel 63 0: <>
3305     *** Failers
3306     No match
3307     <abc
3308     No match
3309    
3310 ph10 162 |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
3311 nigel 63 ------------------------------------------------------------------
3312 ph10 192 Bra
3313 ph10 161 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
3314     \b
3315     Ket
3316     End
3317 nigel 63 ------------------------------------------------------------------
3318     Capturing subpattern count = 0
3319     No options
3320     First char = '8'
3321     Need char = 'X'
3322    
3323 ph10 162 |\$\<\.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
3324 nigel 63 ------------------------------------------------------------------
3325 ph10 192 Bra
3326 ph10 161 $<.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
3327     \b
3328     Ket
3329     End
3330 nigel 63 ------------------------------------------------------------------
3331     Capturing subpattern count = 0
3332     No options
3333     First char = '$'
3334     Need char = 'X'
3335    
3336     /(.*)\d+\1/I
3337     Capturing subpattern count = 1
3338     Max back reference = 1
3339 nigel 75 Partial matching not supported
3340 nigel 63 No options
3341     No first char
3342     No need char
3343    
3344     /(.*)\d+/I
3345     Capturing subpattern count = 1
3346 nigel 75 Partial matching not supported
3347 nigel 63 No options
3348 nigel 91 First char at start or follows newline
3349 nigel 63 No need char
3350 ph10 102
3351 nigel 63 /(.*)\d+\1/Is
3352     Capturing subpattern count = 1
3353     Max back reference = 1
3354 nigel 75 Partial matching not supported
3355 nigel 63 Options: dotall
3356     No first char
3357     No need char
3358    
3359     /(.*)\d+/Is
3360     Capturing subpattern count = 1
3361 nigel 75 Partial matching not supported
3362 nigel 63 Options: anchored dotall
3363     No first char
3364     No need char
3365    
3366     /(.*(xyz))\d+\2/I
3367     Capturing subpattern count = 2
3368     Max back reference = 2
3369 nigel 75 Partial matching not supported
3370 nigel 63 No options
3371 nigel 91 First char at start or follows newline
3372 nigel 63 Need char = 'z'
3373    
3374     /((.*))\d+\1/I
3375     Capturing subpattern count = 2
3376     Max back reference = 1
3377 nigel 75 Partial matching not supported
3378 nigel 63 No options
3379     No first char
3380     No need char
3381     abc123bc
3382     0: bc123bc
3383     1: bc
3384     2: bc
3385 ph10 102
3386 nigel 63 /a[b]/I
3387     Capturing subpattern count = 0
3388     No options
3389     First char = 'a'
3390     Need char = 'b'
3391    
3392     /(?=a).*/I
3393     Capturing subpattern count = 0
3394 nigel 75 Partial matching not supported
3395 nigel 63 No options
3396     First char = 'a'
3397     No need char
3398    
3399 nigel 93 /(?=abc).xyz/IiI
3400 nigel 63 Capturing subpattern count = 0
3401     Options: caseless
3402     First char = 'a' (caseless)
3403     Need char = 'z' (caseless)
3404    
3405     /(?=abc)(?i).xyz/I
3406     Capturing subpattern count = 0
3407     No options
3408     First char = 'a'
3409     Need char = 'z' (caseless)
3410    
3411     /(?=a)(?=b)/I
3412     Capturing subpattern count = 0
3413     No options
3414     First char = 'a'
3415     No need char
3416    
3417     /(?=.)a/I
3418     Capturing subpattern count = 0
3419     No options
3420     First char = 'a'
3421     No need char
3422    
3423     /((?=abcda)a)/I
3424     Capturing subpattern count = 1
3425     No options
3426     First char = 'a'
3427     Need char = 'a'
3428    
3429     /((?=abcda)ab)/I
3430     Capturing subpattern count = 1
3431     No options
3432     First char = 'a'
3433     Need char = 'b'
3434    
3435     /()a/I
3436     Capturing subpattern count = 1
3437     No options
3438     No first char
3439     Need char = 'a'
3440    
3441 ph10 270 /(?(1)ab|ac)(.)/I
3442     Capturing subpattern count = 1
3443 nigel 63 No options
3444     First char = 'a'
3445     No need char
3446    
3447 ph10 270 /(?(1)abz|acz)(.)/I
3448     Capturing subpattern count = 1
3449 nigel 63 No options
3450     First char = 'a'
3451     Need char = 'z'
3452    
3453 ph10 270 /(?(1)abz)(.)/I
3454     Capturing subpattern count = 1
3455 nigel 63 No options
3456     No first char
3457     No need char
3458    
3459 ph10 270 /(?(1)abz)(1)23/I
3460     Capturing subpattern count = 1
3461 nigel 63 No options
3462     No first char
3463     Need char = '3'
3464    
3465     /(a)+/I
3466     Capturing subpattern count = 1
3467     No options
3468     First char = 'a'
3469     No need char
3470    
3471     /(a){2,3}/I
3472     Capturing subpattern count = 1
3473     No options
3474     First char = 'a'
3475     Need char = 'a'
3476    
3477     /(a)*/I
3478     Capturing subpattern count = 1
3479     No options
3480     No first char
3481     No need char
3482    
3483     /[a]/I
3484     Capturing subpattern count = 0
3485     No options
3486     First char = 'a'
3487     No need char
3488    
3489     /[ab]/I
3490     Capturing subpattern count = 0
3491     No options
3492     No first char
3493     No need char
3494    
3495     /[ab]/IS
3496     Capturing subpattern count = 0
3497     No options
3498     No first char
3499     No need char
3500 nigel 75 Starting byte set: a b
3501 nigel 63
3502     /[^a]/I
3503     Capturing subpattern count = 0
3504     No options
3505     No first char
3506     No need char
3507    
3508     /\d456/I
3509     Capturing subpattern count = 0
3510     No options
3511     No first char
3512     Need char = '6'
3513    
3514     /\d456/IS
3515     Capturing subpattern count = 0
3516     No options
3517     No first char
3518     Need char = '6'
3519 nigel 75 Starting byte set: 0 1 2 3 4 5 6 7 8 9
3520 nigel 63
3521     /a^b/I
3522     Capturing subpattern count = 0
3523     No options
3524     First char = 'a'
3525     Need char = 'b'
3526    
3527 nigel 93 /^a/Im
3528 nigel 63 Capturing subpattern count = 0
3529     Options: multiline
3530 nigel 91 First char at start or follows newline
3531 nigel 63 Need char = 'a'
3532     abcde
3533     0: a
3534 ph10 102 xy\nabc
3535 nigel 63 0: a
3536 ph10 102 *** Failers
3537 nigel 63 No match
3538 ph10 102 xyabc
3539 nigel 63 No match
3540    
3541     /c|abc/I
3542     Capturing subpattern count = 0
3543     No options
3544     No first char
3545     Need char = 'c'
3546    
3547     /(?i)[ab]/IS
3548     Capturing subpattern count = 0
3549     Options: caseless
3550     No first char
3551     No need char
3552 nigel 75 Starting byte set: A B a b
3553 nigel 63
3554     /[ab](?i)cd/IS
3555     Capturing subpattern count = 0
3556     No options
3557     No first char
3558     Need char = 'd' (caseless)
3559 nigel 75 Starting byte set: a b
3560 nigel 63
3561 nigel 93 /abc(?C)def/I
3562 nigel 63 Capturing subpattern count = 0
3563     No options
3564     First char = 'a'
3565     Need char = 'f'
3566     abcdef
3567     --->abcdef
3568 nigel 75 0 ^ ^ d
3569 nigel 63 0: abcdef
3570 ph10 102 1234abcdef
3571 nigel 63 --->1234abcdef
3572 nigel 75 0 ^ ^ d
3573 nigel 63 0: abcdef
3574     *** Failers
3575     No match
3576     abcxyz
3577     No match
3578 ph10 102 abcxyzf
3579 nigel 63 --->abcxyzf
3580 nigel 75 0 ^ ^ d
3581 nigel 63 No match
3582    
3583 nigel 93 /abc(?C)de(?C1)f/I
3584 nigel 63 Capturing subpattern count = 0
3585     No options
3586     First char = 'a'
3587     Need char = 'f'
3588     123abcdef
3589     --->123abcdef
3590 nigel 75 0 ^ ^ d
3591     1 ^ ^ f
3592 nigel 63 0: abcdef
3593 ph10 102
3594     /(?C1)\dabc(?C2)def/I
3595 nigel 63 Capturing subpattern count = 0
3596     No options
3597     No first char
3598     Need char = 'f'
3599     1234abcdef
3600     --->1234abcdef
3601 nigel 75 1 ^ \d
3602     1 ^ \d
3603     1 ^ \d
3604     1 ^ \d
3605     2 ^ ^ d
3606 nigel 63 0: 4abcdef
3607     *** Failers
3608     No match
3609 ph10 102 abcdef
3610 nigel 63 --->abcdef
3611 nigel 75 1 ^ \d
3612     1 ^ \d
3613     1 ^ \d
3614     1 ^ \d
3615     1 ^ \d
3616     1 ^ \d
3617 nigel 63 No match
3618 ph10 102
3619 nigel 93 /(?C255)ab/I
3620 nigel 63 Capturing subpattern count = 0
3621     No options
3622     First char = 'a'
3623     Need char = 'b'
3624    
3625 nigel 93 /(?C256)ab/I
3626 nigel 63 Failed: number after (?C is > 255 at offset 6
3627    
3628 ph10 102 /(?Cab)xx/I
3629 nigel 63 Failed: closing ) for (?C expected at offset 3
3630    
3631 nigel 93 /(?C12vr)x/I
3632 nigel 63 Failed: closing ) for (?C expected at offset 5
3633    
3634 nigel 93 /abc(?C)def/I
3635 nigel 63 Capturing subpattern count = 0
3636     No options
3637     First char = 'a'
3638     Need char = 'f'
3639     *** Failers
3640     No match
3641     \x83\x0\x61bcdef
3642     --->\x83\x00abcdef
3643 nigel 75 0 ^ ^ d
3644 nigel 63 0: abcdef
3645    
3646 nigel 93 /(abc)(?C)de(?C1)f/I
3647 nigel 63 Capturing subpattern count = 1
3648     No options
3649     First char = 'a'
3650     Need char = 'f'
3651     123abcdef
3652     --->123abcdef
3653 nigel 75 0 ^ ^ d
3654     1 ^ ^ f
3655 nigel 63 0: abcdef
3656     1: abc
3657 ph10 102 123abcdef\C+
3658 nigel 63 Callout 0: last capture = 1
3659     0: <unset>
3660     1: abc
3661     --->123abcdef
3662 nigel 75 ^ ^ d
3663 nigel 63 Callout 1: last capture = 1
3664     0: <unset>
3665     1: abc
3666     --->123abcdef
3667 nigel 75 ^ ^ f
3668 nigel 63 0: abcdef
3669     1: abc
3670 ph10 102 123abcdef\C-
3671 nigel 63 0: abcdef
3672     1: abc
3673     *** Failers
3674     No match
3675 ph10 102 123abcdef\C!1
3676 nigel 63 --->123abcdef
3677 nigel 75 0 ^ ^ d
3678     1 ^ ^ f
3679 nigel 63 No match
3680 ph10 102
3681 nigel 93 /(?C0)(abc(?C1))*/I
3682 nigel 63 Capturing subpattern count = 1
3683     No options
3684     No first char
3685     No need char
3686     abcabcabc
3687     --->abcabcabc
3688 nigel 75 0 ^ (abc(?C1))*
3689     1 ^ ^ )
3690     1 ^ ^ )
3691     1 ^ ^ )
3692 nigel 63 0: abcabcabc
3693     1: abc
3694 ph10 102 abcabc\C!1!3
3695 nigel 63 --->abcabc
3696 nigel 75 0 ^ (abc(?C1))*
3697     1 ^ ^ )
3698     1 ^ ^ )
3699 nigel 63 0: abcabc
3700     1: abc
3701     *** Failers
3702     --->*** Failers
3703 nigel 75 0 ^ (abc(?C1))*
3704 nigel 63 0:
3705 ph10 102 abcabcabc\C!1!3
3706 nigel 63 --->abcabcabc
3707 nigel 75 0 ^ (abc(?C1))*
3708     1 ^ ^ )
3709     1 ^ ^ )
3710     1 ^ ^ )
3711 nigel 63 0: abcabc
3712     1: abc
3713    
3714 nigel 93 /(\d{3}(?C))*/I
3715 nigel 63 Capturing subpattern count = 1
3716 nigel 75 Partial matching not supported
3717 nigel 63 No options
3718     No first char
3719     No need char
3720     123\C+
3721     Callout 0: last capture = -1
3722     0: <unset>
3723     --->123
3724 nigel 75 ^ ^ )
3725 nigel 63 0: 123
3726     1: 123
3727     123456\C+
3728     Callout 0: last capture = -1
3729     0: <unset>
3730     --->123456
3731 nigel 75 ^ ^ )
3732 nigel 63 Callout 0: last capture = 1
3733     0: <unset>
3734     1: 123
3735     --->123456
3736 nigel 75 ^ ^ )
3737 nigel 63 0: 123456
3738     1: 456
3739 ph10 102 123456789\C+
3740 nigel 63 Callout 0: last capture = -1
3741     0: <unset>
3742     --->123456789
3743 nigel 75 ^ ^ )
3744 nigel 63 Callout 0: last capture = 1
3745     0: <unset>
3746     1: 123
3747     --->123456789
3748 nigel 75 ^ ^ )
3749 nigel 63 Callout 0: last capture = 1
3750     0: <unset>
3751     1: 456
3752     --->123456789
3753 nigel 75 ^ ^ )
3754 nigel 63 0: 123456789
3755     1: 789
3756    
3757 nigel 93 /((xyz)(?C)p|(?C1)xyzabc)/I
3758 nigel 63 Capturing subpattern count = 2
3759     No options
3760     First char = 'x'
3761     No need char
3762     xyzabc\C+
3763     Callout 0: last capture = 2
3764     0: <unset>
3765     1: <unset>
3766     2: xyz
3767     --->xyzabc
3768 nigel 75 ^ ^ p
3769 nigel 63 Callout 1: last capture = -1
3770     0: <unset>
3771     --->xyzabc
3772 nigel 75 ^ x
3773 nigel 63 0: xyzabc
3774     1: xyzabc
3775    
3776 nigel 93 /(X)((xyz)(?C)p|(?C1)xyzabc)/I
3777 nigel 63 Capturing subpattern count = 3
3778     No options
3779     First char = 'X'
3780     Need char = 'x'
3781     Xxyzabc\C+
3782     Callout 0: last capture = 3
3783     0: <unset>
3784     1: X
3785     2: <unset>
3786     3: xyz
3787     --->Xxyzabc
3788 nigel 75 ^ ^ p
3789 nigel 63 Callout 1: last capture = 1
3790     0: <unset>
3791     1: X
3792     --->Xxyzabc
3793 nigel 75 ^^ x
3794 nigel 63 0: Xxyzabc
3795     1: X
3796     2: xyzabc
3797    
3798 nigel 93 /(?=(abc))(?C)abcdef/I
3799 nigel 63 Capturing subpattern count = 1
3800     No options
3801     First char = 'a'
3802     Need char = 'f'
3803     abcdef\C+
3804     Callout 0: last capture = 1
3805     0: <unset>
3806     1: abc
3807     --->abcdef
3808 nigel 75 ^ a
3809 nigel 63 0: abcdef
3810     1: abc
3811 ph10 102
3812 nigel 93 /(?!(abc)(?C1)d)(?C2)abcxyz/I
3813 nigel 63 Capturing subpattern count = 1
3814     No options
3815     First char = 'a'
3816     Need char = 'z'
3817 ph10 102 abcxyz\C+
3818 nigel 63 Callout 1: last capture = 1
3819     0: <unset>
3820     1: abc
3821     --->abcxyz
3822 nigel 75 ^ ^ d
3823 nigel 63 Callout 2: last capture = -1
3824     0: <unset>
3825     --->abcxyz
3826 nigel 75 ^ a
3827 nigel 63 0: abcxyz
3828    
3829 nigel 93 /(?<=(abc)(?C))xyz/I
3830 nigel 63 Capturing subpattern count = 1
3831     No options
3832     First char = 'x'
3833     Need char = 'z'
3834     abcxyz\C+
3835     Callout 0: last capture = 1
3836     0: <unset>
3837     1: abc
3838     --->abcxyz
3839 nigel 75 ^ )
3840 nigel 63 0: xyz
3841     1: abc
3842 ph10 102
3843 nigel 93 /a(b+)(c*)(?C1)/I
3844 nigel 77 Capturing subpattern count = 2
3845     Partial matching not supported
3846     No options
3847     First char = 'a'
3848     Need char = 'b'
3849     abbbbbccc\C*1
3850     --->abbbbbccc
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     1 ^ ^
3860     Callout data = 1
3861     1 ^ ^
3862     Callout data = 1
3863     1 ^ ^
3864     Callout data = 1
3865     1 ^ ^
3866     Callout data = 1
3867     No match
3868    
3869 nigel 93 /a(b+?)(c*?)(?C1)/I
3870 nigel 77 Capturing subpattern count = 2
3871     Partial matching not supported
3872     No options
3873     First char = 'a'
3874     Need char = 'b'
3875     abbbbbccc\C*1
3876     --->abbbbbccc
3877     1 ^ ^
3878     Callout data = 1
3879     1 ^ ^
3880     Callout data = 1
3881     1 ^ ^
3882     Callout data = 1
3883     1 ^ ^
3884     Callout data = 1
3885     1 ^ ^
3886     Callout data = 1
3887     1 ^ ^
3888     Callout data = 1
3889     1 ^ ^
3890     Callout data = 1
3891     1 ^ ^
3892     Callout data = 1
3893     No match
3894 ph10 102
3895     /(?C)abc/I
3896 nigel 63 Capturing subpattern count = 0
3897