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

Contents of /code/trunk/testdata/testinput5

Parent Directory Parent Directory | Revision Log Revision Log


Revision 560 - (show annotations)
Wed Oct 27 09:59:43 2010 UTC (8 years, 9 months ago) by ph10
File size: 11636 byte(s)
Further test tidies for Perl comparisons.
1 /-- This set of tests checks the API, internals, and non-Perl stuff for UTF-8
2 support, excluding Unicode properties. --/
3
4 /\x{100}/8DZ
5
6 /\x{1000}/8DZ
7
8 /\x{10000}/8DZ
9
10 /\x{100000}/8DZ
11
12 /\x{1000000}/8DZ
13
14 /\x{4000000}/8DZ
15
16 /\x{7fffFFFF}/8DZ
17
18 /[\x{ff}]/8DZ
19
20 /[\x{100}]/8DZ
21
22 /\x{ffffffff}/8
23
24 /\x{100000000}/8
25
26 /^\x{100}a\x{1234}/8
27 \x{100}a\x{1234}bcd
28
29 /\x80/8DZ
30
31 /\xff/8DZ
32
33 /\x{0041}\x{2262}\x{0391}\x{002e}/DZ8
34 \x{0041}\x{2262}\x{0391}\x{002e}
35
36 /\x{D55c}\x{ad6d}\x{C5B4}/DZ8
37 \x{D55c}\x{ad6d}\x{C5B4}
38
39 /\x{65e5}\x{672c}\x{8a9e}/DZ8
40 \x{65e5}\x{672c}\x{8a9e}
41
42 /\x{80}/DZ8
43
44 /\x{084}/DZ8
45
46 /\x{104}/DZ8
47
48 /\x{861}/DZ8
49
50 /\x{212ab}/DZ8
51
52 /.{3,5}X/DZ8
53 \x{212ab}\x{212ab}\x{212ab}\x{861}X
54
55
56 /.{3,5}?/DZ8
57 \x{212ab}\x{212ab}\x{212ab}\x{861}
58
59 /(?<=\C)X/8
60 Should produce an error diagnostic
61
62 /-- This one is here not because it's different to Perl, but because the way
63 the captured single-byte is displayed. (In Perl it becomes a character, and you
64 can't tell the difference.) --/
65
66 /X(\C)(.*)/8
67 X\x{1234}
68 X\nabc
69
70 /-- This one is here because Perl gives out a grumbly error message (quite
71 correctly, but that messes up comparisons). --/
72
73 /a\Cb/8
74 *** Failers
75 a\x{100}b
76
77 /^[ab]/8DZ
78 bar
79 *** Failers
80 c
81 \x{ff}
82 \x{100}
83
84 /^[^ab]/8DZ
85 c
86 \x{ff}
87 \x{100}
88 *** Failers
89 aaa
90
91 /[^ab\xC0-\xF0]/8SDZ
92 \x{f1}
93 \x{bf}
94 \x{100}
95 \x{1000}
96 *** Failers
97 \x{c0}
98 \x{f0}
99
100 /Ā{3,4}/8SDZ
101 \x{100}\x{100}\x{100}\x{100\x{100}
102
103 /(\x{100}+|x)/8SDZ
104
105 /(\x{100}*a|x)/8SDZ
106
107 /(\x{100}{0,2}a|x)/8SDZ
108
109 /(\x{100}{1,2}a|x)/8SDZ
110
111 /\x{100}*(\d+|"(?1)")/8
112 1234
113 "1234"
114 \x{100}1234
115 "\x{100}1234"
116 \x{100}\x{100}12ab
117 \x{100}\x{100}"12"
118 *** Failers
119 \x{100}\x{100}abcd
120
121 /\x{100}/8DZ
122
123 /\x{100}*/8DZ
124
125 /a\x{100}*/8DZ
126
127 /ab\x{100}*/8DZ
128
129 /a\x{100}\x{101}*/8DZ
130
131 /a\x{100}\x{101}+/8DZ
132
133 /\x{100}*A/8DZ
134 A
135
136 /\x{100}*\d(?R)/8DZ
137
138 /[^\x{c4}]/DZ
139
140 /[^\x{c4}]/8DZ
141
142 /[\x{100}]/8DZ
143 \x{100}
144 Z\x{100}
145 \x{100}Z
146 *** Failers
147
148 /[Z\x{100}]/8DZ
149 Z\x{100}
150 \x{100}
151 \x{100}Z
152 *** Failers
153
154 /[\x{200}-\x{100}]/8
155
156 /[Ā-Ą]/8
157 \x{100}
158 \x{104}
159 *** Failers
160 \x{105}
161 \x{ff}
162
163 /[z-\x{100}]/8DZ
164
165 /[z\Qa-d]Ā\E]/8DZ
166 \x{100}
167 Ā
168
169 /[\xFF]/DZ
170 >\xff<
171
172 /[\xff]/DZ8
173 >\x{ff}<
174
175 /[^\xFF]/DZ
176
177 /[^\xff]/8DZ
178
179 /[Ä-Ü]/8
180 Ö # Matches without Study
181 \x{d6}
182
183 /[Ä-Ü]/8S
184 Ö <-- Same with Study
185 \x{d6}
186
187 /[\x{c4}-\x{dc}]/8
188 Ö # Matches without Study
189 \x{d6}
190
191 /[\x{c4}-\x{dc}]/8S
192 Ö <-- Same with Study
193 \x{d6}
194
195 /[]/8
196
197 //8
198
199 /xxx/8
200
201 /xxx/8?DZ
202
203 /abc/8
204 ]
205
206
207 \?
208
209 /anything/8
210 \xc0\x80
211 \xc1\x8f
212 \xe0\x9f\x80
213 \xf0\x8f\x80\x80
214 \xf8\x87\x80\x80\x80
215 \xfc\x83\x80\x80\x80\x80
216 \xfe\x80\x80\x80\x80\x80
217 \xff\x80\x80\x80\x80\x80
218 \xc3\x8f
219 \xe0\xaf\x80
220 \xe1\x80\x80
221 \xf0\x9f\x80\x80
222 \xf1\x8f\x80\x80
223 \xf8\x88\x80\x80\x80
224 \xf9\x87\x80\x80\x80
225 \xfc\x84\x80\x80\x80\x80
226 \xfd\x83\x80\x80\x80\x80
227 \?\xf8\x88\x80\x80\x80
228 \?\xf9\x87\x80\x80\x80
229 \?\xfc\x84\x80\x80\x80\x80
230 \?\xfd\x83\x80\x80\x80\x80
231
232 /\x{100}abc(xyz(?1))/8DZ
233
234 /[^\x{100}]abc(xyz(?1))/8DZ
235
236 /[ab\x{100}]abc(xyz(?1))/8DZ
237
238 /(\x{100}(b(?2)c))?/DZ8
239
240 /(\x{100}(b(?2)c)){0,2}/DZ8
241
242 /(\x{100}(b(?1)c))?/DZ8
243
244 /(\x{100}(b(?1)c)){0,2}/DZ8
245
246 /\W/8
247 A.B
248 A\x{100}B
249
250 /\w/8
251 \x{100}X
252
253 /a\x{1234}b/P8
254 a\x{1234}b
255
256 /^\ሴ/8DZ
257
258 /\777/I
259
260 /\777/8I
261 \x{1ff}
262 \777
263
264 /\x{100}*\d/8DZ
265
266 /\x{100}*\s/8DZ
267
268 /\x{100}*\w/8DZ
269
270 /\x{100}*\D/8DZ
271
272 /\x{100}*\S/8DZ
273
274 /\x{100}*\W/8DZ
275
276 /\x{100}+\x{200}/8DZ
277
278 /\x{100}+X/8DZ
279
280 /X+\x{200}/8DZ
281
282 /()()()()()()()()()()
283 ()()()()()()()()()()
284 ()()()()()()()()()()
285 ()()()()()()()()()()
286 A (x) (?41) B/8x
287 AxxB
288
289 /^[\x{100}\E-\Q\E\x{150}]/BZ8
290
291 /^[\QĀ\E-\QŐ\E]/BZ8
292
293 /^[\QĀ\E-\QŐ\E/BZ8
294
295 /^abc./mgx8<any>
296 abc1 \x0aabc2 \x0babc3xx \x0cabc4 \x0dabc5xx \x0d\x0aabc6 \x{0085}abc7 \x{2028}abc8 \x{2029}abc9 JUNK
297
298 /abc.$/mgx8<any>
299 abc1\x0a abc2\x0b abc3\x0c abc4\x0d abc5\x0d\x0a abc6\x{0085} abc7\x{2028} abc8\x{2029} abc9
300
301 /^a\Rb/8<bsr_unicode>
302 a\nb
303 a\rb
304 a\r\nb
305 a\x0bb
306 a\x0cb
307 a\x{85}b
308 a\x{2028}b
309 a\x{2029}b
310 ** Failers
311 a\n\rb
312
313 /^a\R*b/8<bsr_unicode>
314 ab
315 a\nb
316 a\rb
317 a\r\nb
318 a\x0bb
319 a\x0c\x{2028}\x{2029}b
320 a\x{85}b
321 a\n\rb
322 a\n\r\x{85}\x0cb
323
324 /^a\R+b/8<bsr_unicode>
325 a\nb
326 a\rb
327 a\r\nb
328 a\x0bb
329 a\x0c\x{2028}\x{2029}b
330 a\x{85}b
331 a\n\rb
332 a\n\r\x{85}\x0cb
333 ** Failers
334 ab
335
336 /^a\R{1,3}b/8<bsr_unicode>
337 a\nb
338 a\n\rb
339 a\n\r\x{85}b
340 a\r\n\r\nb
341 a\r\n\r\n\r\nb
342 a\n\r\n\rb
343 a\n\n\r\nb
344 ** Failers
345 a\n\n\n\rb
346 a\r
347
348 /\H\h\V\v/8
349 X X\x0a
350 X\x09X\x0b
351 ** Failers
352 \x{a0} X\x0a
353
354 /\H*\h+\V?\v{3,4}/8
355 \x09\x20\x{a0}X\x0a\x0b\x0c\x0d\x0a
356 \x09\x20\x{a0}\x0a\x0b\x0c\x0d\x0a
357 \x09\x20\x{a0}\x0a\x0b\x0c
358 ** Failers
359 \x09\x20\x{a0}\x0a\x0b
360
361 /\H\h\V\v/8
362 \x{3001}\x{3000}\x{2030}\x{2028}
363 X\x{180e}X\x{85}
364 ** Failers
365 \x{2009} X\x0a
366
367 /\H*\h+\V?\v{3,4}/8
368 \x{1680}\x{180e}\x{2007}X\x{2028}\x{2029}\x0c\x0d\x0a
369 \x09\x{205f}\x{a0}\x0a\x{2029}\x0c\x{2028}\x0a
370 \x09\x20\x{202f}\x0a\x0b\x0c
371 ** Failers
372 \x09\x{200a}\x{a0}\x{2028}\x0b
373
374 /[\h]/8BZ
375 >\x{1680}
376
377 /[\h]{3,}/8BZ
378 >\x{1680}\x{180e}\x{2000}\x{2003}\x{200a}\x{202f}\x{205f}\x{3000}<
379
380 /[\v]/8BZ
381
382 /[\H]/8BZ
383
384 /[\V]/8BZ
385
386 /.*$/8<any>
387 \x{1ec5}
388
389 /-- This tests the stricter UTF-8 check according to RFC 3629. --/
390
391 /X/8
392 \x{0}\x{d7ff}\x{e000}\x{10ffff}
393 \x{d800}
394 \x{d800}\?
395 \x{da00}
396 \x{da00}\?
397 \x{dfff}
398 \x{dfff}\?
399 \x{110000}
400 \x{110000}\?
401 \x{2000000}
402 \x{2000000}\?
403 \x{7fffffff}
404 \x{7fffffff}\?
405
406 /a\Rb/I8<bsr_anycrlf>
407 a\rb
408 a\nb
409 a\r\nb
410 ** Failers
411 a\x{85}b
412 a\x0bb
413
414 /a\Rb/I8<bsr_unicode>
415 a\rb
416 a\nb
417 a\r\nb
418 a\x{85}b
419 a\x0bb
420 ** Failers
421 a\x{85}b\<bsr_anycrlf>
422 a\x0bb\<bsr_anycrlf>
423
424 /a\R?b/I8<bsr_anycrlf>
425 a\rb
426 a\nb
427 a\r\nb
428 ** Failers
429 a\x{85}b
430 a\x0bb
431
432 /a\R?b/I8<bsr_unicode>
433 a\rb
434 a\nb
435 a\r\nb
436 a\x{85}b
437 a\x0bb
438 ** Failers
439 a\x{85}b\<bsr_anycrlf>
440 a\x0bb\<bsr_anycrlf>
441
442 /.*a.*=.b.*/8<ANY>
443 QQQ\x{2029}ABCaXYZ=!bPQR
444 ** Failers
445 a\x{2029}b
446 \x61\xe2\x80\xa9\x62
447
448 /[[:a\x{100}b:]]/8
449
450 /a[^]b/<JS>8
451 a\x{1234}b
452 a\nb
453 ** Failers
454 ab
455
456 /a[^]+b/<JS>8
457 aXb
458 a\nX\nX\x{1234}b
459 ** Failers
460 ab
461
462 /(\x{de})\1/
463 \x{de}\x{de}
464 \x{123}
465
466 /X/8f<any>
467 A\x{1ec5}ABCXYZ
468
469 /(*UTF8)\x{1234}/
470 abcd\x{1234}pqr
471
472 /(*CRLF)(*UTF8)(*BSR_UNICODE)a\Rb/I
473
474 /Xa{2,4}b/8
475 X\P
476 Xa\P
477 Xaa\P
478 Xaaa\P
479 Xaaaa\P
480
481 /Xa{2,4}?b/8
482 X\P
483 Xa\P
484 Xaa\P
485 Xaaa\P
486 Xaaaa\P
487
488 /Xa{2,4}+b/8
489 X\P
490 Xa\P
491 Xaa\P
492 Xaaa\P
493 Xaaaa\P
494
495 /X\x{123}{2,4}b/8
496 X\P
497 X\x{123}\P
498 X\x{123}\x{123}\P
499 X\x{123}\x{123}\x{123}\P
500 X\x{123}\x{123}\x{123}\x{123}\P
501
502 /X\x{123}{2,4}?b/8
503 X\P
504 X\x{123}\P
505 X\x{123}\x{123}\P
506 X\x{123}\x{123}\x{123}\P
507 X\x{123}\x{123}\x{123}\x{123}\P
508
509 /X\x{123}{2,4}+b/8
510 X\P
511 X\x{123}\P
512 X\x{123}\x{123}\P
513 X\x{123}\x{123}\x{123}\P
514 X\x{123}\x{123}\x{123}\x{123}\P
515
516 /X\x{123}{2,4}b/8
517 Xx\P
518 X\x{123}x\P
519 X\x{123}\x{123}x\P
520 X\x{123}\x{123}\x{123}x\P
521 X\x{123}\x{123}\x{123}\x{123}x\P
522
523 /X\x{123}{2,4}?b/8
524 Xx\P
525 X\x{123}x\P
526 X\x{123}\x{123}x\P
527 X\x{123}\x{123}\x{123}x\P
528 X\x{123}\x{123}\x{123}\x{123}x\P
529
530 /X\x{123}{2,4}+b/8
531 Xx\P
532 X\x{123}x\P
533 X\x{123}\x{123}x\P
534 X\x{123}\x{123}\x{123}x\P
535 X\x{123}\x{123}\x{123}\x{123}x\P
536
537 /X\d{2,4}b/8
538 X\P
539 X3\P
540 X33\P
541 X333\P
542 X3333\P
543
544 /X\d{2,4}?b/8
545 X\P
546 X3\P
547 X33\P
548 X333\P
549 X3333\P
550
551 /X\d{2,4}+b/8
552 X\P
553 X3\P
554 X33\P
555 X333\P
556 X3333\P
557
558 /X\D{2,4}b/8
559 X\P
560 Xa\P
561 Xaa\P
562 Xaaa\P
563 Xaaaa\P
564
565 /X\D{2,4}?b/8
566 X\P
567 Xa\P
568 Xaa\P
569 Xaaa\P
570 Xaaaa\P
571
572 /X\D{2,4}+b/8
573 X\P
574 Xa\P
575 Xaa\P
576 Xaaa\P
577 Xaaaa\P
578
579 /X\D{2,4}b/8
580 X\P
581 X\x{123}\P
582 X\x{123}\x{123}\P
583 X\x{123}\x{123}\x{123}\P
584 X\x{123}\x{123}\x{123}\x{123}\P
585
586 /X\D{2,4}?b/8
587 X\P
588 X\x{123}\P
589 X\x{123}\x{123}\P
590 X\x{123}\x{123}\x{123}\P
591 X\x{123}\x{123}\x{123}\x{123}\P
592
593 /X\D{2,4}+b/8
594 X\P
595 X\x{123}\P
596 X\x{123}\x{123}\P
597 X\x{123}\x{123}\x{123}\P
598 X\x{123}\x{123}\x{123}\x{123}\P
599
600 /X[abc]{2,4}b/8
601 X\P
602 Xa\P
603 Xaa\P
604 Xaaa\P
605 Xaaaa\P
606
607 /X[abc]{2,4}?b/8
608 X\P
609 Xa\P
610 Xaa\P
611 Xaaa\P
612 Xaaaa\P
613
614 /X[abc]{2,4}+b/8
615 X\P
616 Xa\P
617 Xaa\P
618 Xaaa\P
619 Xaaaa\P
620
621 /X[abc\x{123}]{2,4}b/8
622 X\P
623 X\x{123}\P
624 X\x{123}\x{123}\P
625 X\x{123}\x{123}\x{123}\P
626 X\x{123}\x{123}\x{123}\x{123}\P
627
628 /X[abc\x{123}]{2,4}?b/8
629 X\P
630 X\x{123}\P
631 X\x{123}\x{123}\P
632 X\x{123}\x{123}\x{123}\P
633 X\x{123}\x{123}\x{123}\x{123}\P
634
635 /X[abc\x{123}]{2,4}+b/8
636 X\P
637 X\x{123}\P
638 X\x{123}\x{123}\P
639 X\x{123}\x{123}\x{123}\P
640 X\x{123}\x{123}\x{123}\x{123}\P
641
642 /X[^a]{2,4}b/8
643 X\P
644 Xz\P
645 Xzz\P
646 Xzzz\P
647 Xzzzz\P
648
649 /X[^a]{2,4}?b/8
650 X\P
651 Xz\P
652 Xzz\P
653 Xzzz\P
654 Xzzzz\P
655
656 /X[^a]{2,4}+b/8
657 X\P
658 Xz\P
659 Xzz\P
660 Xzzz\P
661 Xzzzz\P
662
663 /X[^a]{2,4}b/8
664 X\P
665 X\x{123}\P
666 X\x{123}\x{123}\P
667 X\x{123}\x{123}\x{123}\P
668 X\x{123}\x{123}\x{123}\x{123}\P
669
670 /X[^a]{2,4}?b/8
671 X\P
672 X\x{123}\P
673 X\x{123}\x{123}\P
674 X\x{123}\x{123}\x{123}\P
675 X\x{123}\x{123}\x{123}\x{123}\P
676
677 /X[^a]{2,4}+b/8
678 X\P
679 X\x{123}\P
680 X\x{123}\x{123}\P
681 X\x{123}\x{123}\x{123}\P
682 X\x{123}\x{123}\x{123}\x{123}\P
683
684 /(Y)X\1{2,4}b/8
685 YX\P
686 YXY\P
687 YXYY\P
688 YXYYY\P
689 YXYYYY\P
690
691 /(Y)X\1{2,4}?b/8
692 YX\P
693 YXY\P
694 YXYY\P
695 YXYYY\P
696 YXYYYY\P
697
698 /(Y)X\1{2,4}+b/8
699 YX\P
700 YXY\P
701 YXYY\P
702 YXYYY\P
703 YXYYYY\P
704
705 /(\x{123})X\1{2,4}b/8
706 \x{123}X\P
707 \x{123}X\x{123}\P
708 \x{123}X\x{123}\x{123}\P
709 \x{123}X\x{123}\x{123}\x{123}\P
710 \x{123}X\x{123}\x{123}\x{123}\x{123}\P
711
712 /(\x{123})X\1{2,4}?b/8
713 \x{123}X\P
714 \x{123}X\x{123}\P
715 \x{123}X\x{123}\x{123}\P
716 \x{123}X\x{123}\x{123}\x{123}\P
717 \x{123}X\x{123}\x{123}\x{123}\x{123}\P
718
719 /(\x{123})X\1{2,4}+b/8
720 \x{123}X\P
721 \x{123}X\x{123}\P
722 \x{123}X\x{123}\x{123}\P
723 \x{123}X\x{123}\x{123}\x{123}\P
724 \x{123}X\x{123}\x{123}\x{123}\x{123}\P
725
726 /\bthe cat\b/8
727 the cat\P
728 the cat\P\P
729
730 /abcd*/8
731 xxxxabcd\P
732 xxxxabcd\P\P
733
734 /abcd*/i8
735 xxxxabcd\P
736 xxxxabcd\P\P
737 XXXXABCD\P
738 XXXXABCD\P\P
739
740 /abc\d*/8
741 xxxxabc1\P
742 xxxxabc1\P\P
743
744 /(a)bc\1*/8
745 xxxxabca\P
746 xxxxabca\P\P
747
748 /abc[de]*/8
749 xxxxabcde\P
750 xxxxabcde\P\P
751
752 /X\W{3}X/8
753 \PX
754
755 /\h/SI
756
757 /\h/SI8
758 ABC\x{09}
759 ABC\x{20}
760 ABC\x{a0}
761 ABC\x{1680}
762 ABC\x{180e}
763 ABC\x{2000}
764 ABC\x{202f}
765 ABC\x{205f}
766 ABC\x{3000}
767
768 /\v/SI
769
770 /\v/SI8
771 ABC\x{0a}
772 ABC\x{0b}
773 ABC\x{0c}
774 ABC\x{0d}
775 ABC\x{85}
776 ABC\x{2028}
777
778 /\R/SI
779
780 /\R/SI8
781
782 /\h*A/SI8
783 CDBABC
784
785 /\v+A/SI8
786
787 /\s?xxx\s/8SI
788
789 /\sxxx\s/8T1
790 AB\x{85}xxx\x{a0}XYZ
791 AB\x{a0}xxx\x{85}XYZ
792
793 /\sxxx\s/I8ST1
794 AB\x{85}xxx\x{a0}XYZ
795 AB\x{a0}xxx\x{85}XYZ
796
797 /\S \S/8T1
798 \x{a2} \x{84}
799
800 /\S \S/I8ST1
801 \x{a2} \x{84}
802 A Z
803
804 'A#хц'8x<any>BZ
805
806 'A#хц
807 PQ'8x<any>BZ
808
809 /a+#хaa
810 z#XX?/8x<any>BZ
811
812 /a+#хaa
813 z#х?/8x<any>BZ
814
815 /\g{A}xxx#bXX(?'A'123) (?'A'456)/8x<any>BZ
816
817 /\g{A}xxx#bх(?'A'123) (?'A'456)/8x<any>BZ
818
819 /-- End of testinput5 --/

Properties

Name Value
svn:keywords "Author Date Id Revision Url"

  ViewVC Help
Powered by ViewVC 1.1.5