1 /-- This set of tests check the DFA matching functionality of pcre_dfa_exec(). 2 The -dfa flag must be used with pcretest when running it. --/ 3 4 /abc/ 5 abc 6 0: abc 7 8 /ab*c/ 9 abc 10 0: abc 11 abbbbc 12 0: abbbbc 13 ac 14 0: ac 15 16 /ab+c/ 17 abc 18 0: abc 19 abbbbbbc 20 0: abbbbbbc 21 *** Failers 22 No match 23 ac 24 No match 25 ab 26 No match 27 28 /a*/ 29 a 30 0: a 31 1: 32 aaaaaaaaaaaaaaaaa 33 0: aaaaaaaaaaaaaaaaa 34 1: aaaaaaaaaaaaaaaa 35 2: aaaaaaaaaaaaaaa 36 3: aaaaaaaaaaaaaa 37 4: aaaaaaaaaaaaa 38 5: aaaaaaaaaaaa 39 6: aaaaaaaaaaa 40 7: aaaaaaaaaa 41 8: aaaaaaaaa 42 9: aaaaaaaa 43 10: aaaaaaa 44 11: aaaaaa 45 12: aaaaa 46 13: aaaa 47 14: aaa 48 15: aa 49 16: a 50 17: 51 aaaaaaaaaaaaaaaaaaaaaaaaaaaaaa 52 Matched, but too many subsidiary matches 53 0: aaaaaaaaaaaaaaaaaaaaaaaaaaaaaa 54 1: aaaaaaaaaaaaaaaaaaaaaaaaaaaaa 55 2: aaaaaaaaaaaaaaaaaaaaaaaaaaaa 56 3: aaaaaaaaaaaaaaaaaaaaaaaaaaa 57 4: aaaaaaaaaaaaaaaaaaaaaaaaaa 58 5: aaaaaaaaaaaaaaaaaaaaaaaaa 59 6: aaaaaaaaaaaaaaaaaaaaaaaa 60 7: aaaaaaaaaaaaaaaaaaaaaaa 61 8: aaaaaaaaaaaaaaaaaaaaaa 62 9: aaaaaaaaaaaaaaaaaaaaa 63 10: aaaaaaaaaaaaaaaaaaaa 64 11: aaaaaaaaaaaaaaaaaaa 65 12: aaaaaaaaaaaaaaaaaa 66 13: aaaaaaaaaaaaaaaaa 67 14: aaaaaaaaaaaaaaaa 68 15: aaaaaaaaaaaaaaa 69 16: aaaaaaaaaaaaaa 70 17: aaaaaaaaaaaaa 71 18: aaaaaaaaaaaa 72 19: aaaaaaaaaaa 73 20: aaaaaaaaaa 74 21: aaaaaaaaa 75 aaaaaaaaaaaaaaaaaaaaaaaaaaaaaa\F 76 0: 77 78 /(a|abcd|african)/ 79 a 80 0: a 81 abcd 82 0: abcd 83 1: a 84 african 85 0: african 86 1: a 87 88 /^abc/ 89 abcdef 90 0: abc 91 *** Failers 92 No match 93 xyzabc 94 No match 95 xyz\nabc 96 No match 97 98 /^abc/m 99 abcdef 100 0: abc 101 xyz\nabc 102 0: abc 103 *** Failers 104 No match 105 xyzabc 106 No match 107 108 /\Aabc/ 109 abcdef 110 0: abc 111 *** Failers 112 No match 113 xyzabc 114 No match 115 xyz\nabc 116 No match 117 118 /\Aabc/m 119 abcdef 120 0: abc 121 *** Failers 122 No match 123 xyzabc 124 No match 125 xyz\nabc 126 No match 127 128 /\Gabc/ 129 abcdef 130 0: abc 131 xyzabc\>3 132 0: abc 133 *** Failers 134 No match 135 xyzabc 136 No match 137 xyzabc\>2 138 No match 139 140 /x\dy\Dz/ 141 x9yzz 142 0: x9yzz 143 x0y+z 144 0: x0y+z 145 *** Failers 146 No match 147 xyz 148 No match 149 xxy0z 150 No match 151 152 /x\sy\Sz/ 153 x yzz 154 0: x yzz 155 x y+z 156 0: x y+z 157 *** Failers 158 No match 159 xyz 160 No match 161 xxyyz 162 No match 163 164 /x\wy\Wz/ 165 xxy+z 166 0: xxy+z 167 *** Failers 168 No match 169 xxy0z 170 No match 171 x+y+z 172 No match 173 174 /x.y/ 175 x+y 176 0: x+y 177 x-y 178 0: x-y 179 *** Failers 180 No match 181 x\ny 182 No match 183 184 /x.y/s 185 x+y 186 0: x+y 187 x-y 188 0: x-y 189 x\ny 190 0: x\x0ay 191 192 /(a.b(?s)c.d|x.y)p.q/ 193 a+bc+dp+q 194 0: a+bc+dp+q 195 a+bc\ndp+q 196 0: a+bc\x0adp+q 197 x\nyp+q 198 0: x\x0ayp+q 199 *** Failers 200 No match 201 a\nbc\ndp+q 202 No match 203 a+bc\ndp\nq 204 No match 205 x\nyp\nq 206 No match 207 208 /a\d\z/ 209 ba0 210 0: a0 211 *** Failers 212 No match 213 ba0\n 214 No match 215 ba0\ncd 216 No match 217 218 /a\d\z/m 219 ba0 220 0: a0 221 *** Failers 222 No match 223 ba0\n 224 No match 225 ba0\ncd 226 No match 227 228 /a\d\Z/ 229 ba0 230 0: a0 231 ba0\n 232 0: a0 233 *** Failers 234 No match 235 ba0\ncd 236 No match 237 238 /a\d\Z/m 239 ba0 240 0: a0 241 ba0\n 242 0: a0 243 *** Failers 244 No match 245 ba0\ncd 246 No match 247 248 /a\d$/ 249 ba0 250 0: a0 251 ba0\n 252 0: a0 253 *** Failers 254 No match 255 ba0\ncd 256 No match 257 258 /a\d$/m 259 ba0 260 0: a0 261 ba0\n 262 0: a0 263 ba0\ncd 264 0: a0 265 *** Failers 266 No match 267 268 /abc/i 269 abc 270 0: abc 271 aBc 272 0: aBc 273 ABC 274 0: ABC 275 276 /[^a]/ 277 abcd 278 0: b 279 280 /ab?\w/ 281 abz 282 0: abz 283 1: ab 284 abbz 285 0: abb 286 1: ab 287 azz 288 0: az 289 290 /x{0,3}yz/ 291 ayzq 292 0: yz 293 axyzq 294 0: xyz 295 axxyz 296 0: xxyz 297 axxxyzq 298 0: xxxyz 299 axxxxyzq 300 0: xxxyz 301 *** Failers 302 No match 303 ax 304 No match 305 axx 306 No match 307 308 /x{3}yz/ 309 axxxyzq 310 0: xxxyz 311 axxxxyzq 312 0: xxxyz 313 *** Failers 314 No match 315 ax 316 No match 317 axx 318 No match 319 ayzq 320 No match 321 axyzq 322 No match 323 axxyz 324 No match 325 326 /x{2,3}yz/ 327 axxyz 328 0: xxyz 329 axxxyzq 330 0: xxxyz 331 axxxxyzq 332 0: xxxyz 333 *** Failers 334 No match 335 ax 336 No match 337 axx 338 No match 339 ayzq 340 No match 341 axyzq 342 No match 343 344 /[^a]+/ 345 bac 346 0: b 347 bcdefax 348 0: bcdef 349 1: bcde 350 2: bcd 351 3: bc 352 4: b 353 *** Failers 354 0: *** F 355 1: *** 356 2: *** 357 3: ** 358 4: * 359 aaaaa 360 No match 361 362 /[^a]*/ 363 bac 364 0: b 365 1: 366 bcdefax 367 0: bcdef 368 1: bcde 369 2: bcd 370 3: bc 371 4: b 372 5: 373 *** Failers 374 0: *** F 375 1: *** 376 2: *** 377 3: ** 378 4: * 379 5: 380 aaaaa 381 0: 382 383 /[^a]{3,5}/ 384 xyz 385 0: xyz 386 awxyza 387 0: wxyz 388 1: wxy 389 abcdefa 390 0: bcdef 391 1: bcde 392 2: bcd 393 abcdefghijk 394 0: bcdef 395 1: bcde 396 2: bcd 397 *** Failers 398 0: *** F 399 1: *** 400 2: *** 401 axya 402 No match 403 axa 404 No match 405 aaaaa 406 No match 407 408 /\d*/ 409 1234b567 410 0: 1234 411 1: 123 412 2: 12 413 3: 1 414 4: 415 xyz 416 0: 417 418 /\D*/ 419 a1234b567 420 0: a 421 1: 422 xyz 423 0: xyz 424 1: xy 425 2: x 426 3: 427 428 /\d+/ 429 ab1234c56 430 0: 1234 431 1: 123 432 2: 12 433 3: 1 434 *** Failers 435 No match 436 xyz 437 No match 438 439 /\D+/ 440 ab123c56 441 0: ab 442 1: a 443 *** Failers 444 0: *** Failers 445 1: *** Failer 446 2: *** Faile 447 3: *** Fail 448 4: *** Fai 449 5: *** Fa 450 6: *** F 451 7: *** 452 8: *** 453 9: ** 454 10: * 455 789 456 No match 457 458 /\d?A/ 459 045ABC 460 0: 5A 461 ABC 462 0: A 463 *** Failers 464 No match 465 XYZ 466 No match 467 468 /\D?A/ 469 ABC 470 0: A 471 BAC 472 0: BA 473 9ABC 474 0: A 475 *** Failers 476 No match 477 478 /a+/ 479 aaaa 480 0: aaaa 481 1: aaa 482 2: aa 483 3: a 484 485 /^.*xyz/ 486 xyz 487 0: xyz 488 ggggggggxyz 489 0: ggggggggxyz 490 491 /^.+xyz/ 492 abcdxyz 493 0: abcdxyz 494 axyz 495 0: axyz 496 *** Failers 497 No match 498 xyz 499 No match 500 501 /^.?xyz/ 502 xyz 503 0: xyz 504 cxyz 505 0: cxyz 506 507 /^\d{2,3}X/ 508 12X 509 0: 12X 510 123X 511 0: 123X 512 *** Failers 513 No match 514 X 515 No match 516 1X 517 No match 518 1234X 519 No match 520 521 /^[abcd]\d/ 522 a45 523 0: a4 524 b93 525 0: b9 526 c99z 527 0: c9 528 d04 529 0: d0 530 *** Failers 531 No match 532 e45 533 No match 534 abcd 535 No match 536 abcd1234 537 No match 538 1234 539 No match 540 541 /^[abcd]*\d/ 542 a45 543 0: a4 544 b93 545 0: b9 546 c99z 547 0: c9 548 d04 549 0: d0 550 abcd1234 551 0: abcd1 552 1234 553 0: 1 554 *** Failers 555 No match 556 e45 557 No match 558 abcd 559 No match 560 561 /^[abcd]+\d/ 562 a45 563 0: a4 564 b93 565 0: b9 566 c99z 567 0: c9 568 d04 569 0: d0 570 abcd1234 571 0: abcd1 572 *** Failers 573 No match 574 1234 575 No match 576 e45 577 No match 578 abcd 579 No match 580 581 /^a+X/ 582 aX 583 0: aX 584 aaX 585 0: aaX 586 587 /^[abcd]?\d/ 588 a45 589 0: a4 590 b93 591 0: b9 592 c99z 593 0: c9 594 d04 595 0: d0 596 1234 597 0: 1 598 *** Failers 599 No match 600 abcd1234 601 No match 602 e45 603 No match 604 605 /^[abcd]{2,3}\d/ 606 ab45 607 0: ab4 608 bcd93 609 0: bcd9 610 *** Failers 611 No match 612 1234 613 No match 614 a36 615 No match 616 abcd1234 617 No match 618 ee45 619 No match 620 621 /^(abc)*\d/ 622 abc45 623 0: abc4 624 abcabcabc45 625 0: abcabcabc4 626 42xyz 627 0: 4 628 *** Failers 629 No match 630 631 /^(abc)+\d/ 632 abc45 633 0: abc4 634 abcabcabc45 635 0: abcabcabc4 636 *** Failers 637 No match 638 42xyz 639 No match 640 641 /^(abc)?\d/ 642 abc45 643 0: abc4 644 42xyz 645 0: 4 646 *** Failers 647 No match 648 abcabcabc45 649 No match 650 651 /^(abc){2,3}\d/ 652 abcabc45 653 0: abcabc4 654 abcabcabc45 655 0: abcabcabc4 656 *** Failers 657 No match 658 abcabcabcabc45 659 No match 660 abc45 661 No match 662 42xyz 663 No match 664 665 /1(abc|xyz)2(?1)3/ 666 1abc2abc3456 667 0: 1abc2abc3 668 1abc2xyz3456 669 0: 1abc2xyz3 670 671 /^(a*\w|ab)=(a*\w|ab)/ 672 ab=ab 673 0: ab=ab 674 1: ab=a 675 676 /^(a*\w|ab)=(?1)/ 677 ab=ab 678 0: ab=ab 679 680 /^([^()]|\((?1)*\))*$/ 681 abc 682 0: abc 683 a(b)c 684 0: a(b)c 685 a(b(c))d 686 0: a(b(c))d 687 *** Failers) 688 No match 689 a(b(c)d 690 No match 691 692 /^>abc>([^()]|\((?1)*\))*<xyz<$/ 693 >abc>123<xyz< 694 0: >abc>123<xyz< 695 >abc>1(2)3<xyz< 696 0: >abc>1(2)3<xyz< 697 >abc>(1(2)3)<xyz< 698 0: >abc>(1(2)3)<xyz< 699 700 /^(?>a*)\d/ 701 aaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaa9876 702 0: aaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaa9 703 *** Failers 704 No match 705 aaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaa 706 No match 707 708 /< (?: (?(R) \d++ | [^<>]*+) | (?R)) * >/x 709 <> 710 0: <> 711 <abcd> 712 0: <abcd> 713 <abc <123> hij> 714 0: <abc <123> hij> 715 <abc <def> hij> 716 0: <def> 717 <abc<>def> 718 0: <abc<>def> 719 <abc<> 720 0: <> 721 *** Failers 722 No match 723 <abc 724 No match 725 726 /^(?(?=abc)\w{3}:|\d\d)$/ 727 abc: 728 0: abc: 729 12 730 0: 12 731 *** Failers 732 No match 733 123 734 No match 735 xyz 736 No match 737 738 /^(?(?!abc)\d\d|\w{3}:)$/ 739 abc: 740 0: abc: 741 12 742 0: 12 743 *** Failers 744 No match 745 123 746 No match 747 xyz 748 No match 749 750 /^(?=abc)\w{5}:$/ 751 abcde: 752 0: abcde: 753 *** Failers 754 No match 755 abc.. 756 No match 757 123 758 No match 759 vwxyz 760 No match 761 762 /^(?!abc)\d\d$/ 763 12 764 0: 12 765 *** Failers 766 No match 767 abcde: 768 No match 769 abc.. 770 No match 771 123 772 No match 773 vwxyz 774 No match 775 776 /(?<=abc|xy)123/ 777 abc12345 778 0: 123 779 wxy123z 780 0: 123 781 *** Failers 782 No match 783 123abc 784 No match 785 786 /(?<!abc|xy)123/ 787 123abc 788 0: 123 789 mno123456 790 0: 123 791 *** Failers 792 No match 793 abc12345 794 No match 795 wxy123z 796 No match 797 798 /abc(?C1)xyz/ 799 abcxyz 800 --->abcxyz 801 1 ^ ^ x 802 0: abcxyz 803 123abcxyz999 804 --->123abcxyz999 805 1 ^ ^ x 806 0: abcxyz 807 808 /(ab|cd){3,4}/C 809 ababab 810 --->ababab 811 +0 ^ (ab|cd){3,4} 812 +1 ^ a 813 +4 ^ c 814 +2 ^^ b 815 +3 ^ ^ | 816 +1 ^ ^ a 817 +4 ^ ^ c 818 +2 ^ ^ b 819 +3 ^ ^ | 820 +1 ^ ^ a 821 +4 ^ ^ c 822 +2 ^ ^ b 823 +3 ^ ^ | 824 +12 ^ ^ 825 +1 ^ ^ a 826 +4 ^ ^ c 827 0: ababab 828 abcdabcd 829 --->abcdabcd 830 +0 ^ (ab|cd){3,4} 831 +1 ^ a 832 +4 ^ c 833 +2 ^^ b 834 +3 ^ ^ | 835 +1 ^ ^ a 836 +4 ^ ^ c 837 +5 ^ ^ d 838 +6 ^ ^ ) 839 +1 ^ ^ a 840 +4 ^ ^ c 841 +2 ^ ^ b 842 +3 ^ ^ | 843 +12 ^ ^ 844 +1 ^ ^ a 845 +4 ^ ^ c 846 +5 ^ ^ d 847 +6 ^ ^ ) 848 +12 ^ ^ 849 0: abcdabcd 850 1: abcdab 851 abcdcdcdcdcd 852 --->abcdcdcdcdcd 853 +0 ^ (ab|cd){3,4} 854 +1 ^ a 855 +4 ^ c 856 +2 ^^ b 857 +3 ^ ^ | 858 +1 ^ ^ a 859 +4 ^ ^ c 860 +5 ^ ^ d 861 +6 ^ ^ ) 862 +1 ^ ^ a 863 +4 ^ ^ c 864 +5 ^ ^ d 865 +6 ^ ^ ) 866 +12 ^ ^ 867 +1 ^ ^ a 868 +4 ^ ^ c 869 +5 ^ ^ d 870 +6 ^ ^ ) 871 +12 ^ ^ 872 0: abcdcdcd 873 1: abcdcd 874 875 /^abc/ 876 abcdef 877 0: abc 878 *** Failers 879 No match 880 abcdef\B 881 No match 882 883 /^(a*|xyz)/ 884 bcd 885 0: 886 aaabcd 887 0: aaa 888 1: aa 889 2: a 890 3: 891 xyz 892 0: xyz 893 1: 894 xyz\N 895 0: xyz 896 *** Failers 897 0: 898 bcd\N 899 No match 900 901 /xyz$/ 902 xyz 903 0: xyz 904 xyz\n 905 0: xyz 906 *** Failers 907 No match 908 xyz\Z 909 No match 910 xyz\n\Z 911 No match 912 913 /xyz$/m 914 xyz 915 0: xyz 916 xyz\n 917 0: xyz 918 abcxyz\npqr 919 0: xyz 920 abcxyz\npqr\Z 921 0: xyz 922 xyz\n\Z 923 0: xyz 924 *** Failers 925 No match 926 xyz\Z 927 No match 928 929 /\Gabc/ 930 abcdef 931 0: abc 932 defabcxyz\>3 933 0: abc 934 *** Failers 935 No match 936 defabcxyz 937 No match 938 939 /^abcdef/ 940 ab\P 941 Partial match: ab 942 abcde\P 943 Partial match: abcde 944 abcdef\P 945 0: abcdef 946 *** Failers 947 No match 948 abx\P 949 No match 950 951 /^a{2,4}\d+z/ 952 a\P 953 Partial match: a 954 aa\P 955 Partial match: aa 956 aa2\P 957 Partial match: aa2 958 aaa\P 959 Partial match: aaa 960 aaa23\P 961 Partial match: aaa23 962 aaaa12345\P 963 Partial match: aaaa12345 964 aa0z\P 965 0: aa0z 966 aaaa4444444444444z\P 967 0: aaaa4444444444444z 968 *** Failers 969 No match 970 az\P 971 No match 972 aaaaa\P 973 No match 974 a56\P 975 No match 976 977 /^abcdef/ 978 abc\P 979 Partial match: abc 980 def\R 981 0: def 982 983 /(?<=foo)bar/ 984 xyzfo\P 985 No match 986 foob\P\>2 987 Partial match: foob 988 foobar...\R\P\>4 989 0: ar 990 xyzfo\P 991 No match 992 foobar\>2 993 0: bar 994 *** Failers 995 No match 996 xyzfo\P 997 No match 998 obar\R 999 No match 1000 1001 /(ab*(cd|ef))+X/ 1002 adfadadaklhlkalkajhlkjahdfasdfasdfladsfjkj\P\Z 1003 No match 1004 lkjhlkjhlkjhlkjhabbbbbbcdaefabbbbbbbefa\P\B\Z 1005 Partial match: abbbbbbcdaefabbbbbbbefa 1006 cdabbbbbbbb\P\R\B\Z 1007 Partial match: cdabbbbbbbb 1008 efabbbbbbbbbbbbbbbb\P\R\B\Z 1009 Partial match: efabbbbbbbbbbbbbbbb 1010 bbbbbbbbbbbbcdXyasdfadf\P\R\B\Z 1011 0: bbbbbbbbbbbbcdX 1012 1013 /(a|b)/SF>testsavedregex 1014 Compiled regex written to testsavedregex 1015 Study data written to testsavedregex 1016 <testsavedregex 1017 Compiled regex (byte-inverted) loaded from testsavedregex 1018 Study data loaded from testsavedregex 1019 abc 1020 0: a 1021 ** Failers 1022 0: a 1023 def 1024 No match 1025 1026 /the quick brown fox/ 1027 the quick brown fox 1028 0: the quick brown fox 1029 The quick brown FOX 1030 No match 1031 What do you know about the quick brown fox? 1032 0: the quick brown fox 1033 What do you know about THE QUICK BROWN FOX? 1034 No match 1035 1036 /The quick brown fox/i 1037 the quick brown fox 1038 0: the quick brown fox 1039 The quick brown FOX 1040 0: The quick brown FOX 1041 What do you know about the quick brown fox? 1042 0: the quick brown fox 1043 What do you know about THE QUICK BROWN FOX? 1044 0: THE QUICK BROWN FOX 1045 1046 /abcd\t\n\r\f\a\e\071\x3b\$\\\?caxyz/ 1047 abcd\t\n\r\f\a\e9;\$\\?caxyz 1048 0: abcd\x09\x0a\x0d\x0c\x07\x1b9;$\?caxyz 1049 1050 /a*abc?xyz+pqr{3}ab{2,}xy{4,5}pq{0,6}AB{0,}zz/ 1051 abxyzpqrrrabbxyyyypqAzz 1052 0: abxyzpqrrrabbxyyyypqAzz 1053 abxyzpqrrrabbxyyyypqAzz 1054 0: abxyzpqrrrabbxyyyypqAzz 1055 aabxyzpqrrrabbxyyyypqAzz 1056 0: aabxyzpqrrrabbxyyyypqAzz 1057 aaabxyzpqrrrabbxyyyypqAzz 1058 0: aaabxyzpqrrrabbxyyyypqAzz 1059 aaaabxyzpqrrrabbxyyyypqAzz 1060 0: aaaabxyzpqrrrabbxyyyypqAzz 1061 abcxyzpqrrrabbxyyyypqAzz 1062 0: abcxyzpqrrrabbxyyyypqAzz 1063 aabcxyzpqrrrabbxyyyypqAzz 1064 0: aabcxyzpqrrrabbxyyyypqAzz 1065 aaabcxyzpqrrrabbxyyyypAzz 1066 0: aaabcxyzpqrrrabbxyyyypAzz 1067 aaabcxyzpqrrrabbxyyyypqAzz 1068 0: aaabcxyzpqrrrabbxyyyypqAzz 1069 aaabcxyzpqrrrabbxyyyypqqAzz 1070 0: aaabcxyzpqrrrabbxyyyypqqAzz 1071 aaabcxyzpqrrrabbxyyyypqqqAzz 1072 0: aaabcxyzpqrrrabbxyyyypqqqAzz 1073 aaabcxyzpqrrrabbxyyyypqqqqAzz 1074 0: aaabcxyzpqrrrabbxyyyypqqqqAzz 1075 aaabcxyzpqrrrabbxyyyypqqqqqAzz 1076 0: aaabcxyzpqrrrabbxyyyypqqqqqAzz 1077 aaabcxyzpqrrrabbxyyyypqqqqqqAzz 1078 0: aaabcxyzpqrrrabbxyyyypqqqqqqAzz 1079 aaaabcxyzpqrrrabbxyyyypqAzz 1080 0: aaaabcxyzpqrrrabbxyyyypqAzz 1081 abxyzzpqrrrabbxyyyypqAzz 1082 0: abxyzzpqrrrabbxyyyypqAzz 1083 aabxyzzzpqrrrabbxyyyypqAzz 1084 0: aabxyzzzpqrrrabbxyyyypqAzz 1085 aaabxyzzzzpqrrrabbxyyyypqAzz 1086 0: aaabxyzzzzpqrrrabbxyyyypqAzz 1087 aaaabxyzzzzpqrrrabbxyyyypqAzz 1088 0: aaaabxyzzzzpqrrrabbxyyyypqAzz 1089 abcxyzzpqrrrabbxyyyypqAzz 1090 0: abcxyzzpqrrrabbxyyyypqAzz 1091 aabcxyzzzpqrrrabbxyyyypqAzz 1092 0: aabcxyzzzpqrrrabbxyyyypqAzz 1093 aaabcxyzzzzpqrrrabbxyyyypqAzz 1094 0: aaabcxyzzzzpqrrrabbxyyyypqAzz 1095 aaaabcxyzzzzpqrrrabbxyyyypqAzz 1096 0: aaaabcxyzzzzpqrrrabbxyyyypqAzz 1097 aaaabcxyzzzzpqrrrabbbxyyyypqAzz 1098 0: aaaabcxyzzzzpqrrrabbbxyyyypqAzz 1099 aaaabcxyzzzzpqrrrabbbxyyyyypqAzz 1100 0: aaaabcxyzzzzpqrrrabbbxyyyyypqAzz 1101 aaabcxyzpqrrrabbxyyyypABzz 1102 0: aaabcxyzpqrrrabbxyyyypABzz 1103 aaabcxyzpqrrrabbxyyyypABBzz 1104 0: aaabcxyzpqrrrabbxyyyypABBzz 1105 >>>aaabxyzpqrrrabbxyyyypqAzz 1106 0: aaabxyzpqrrrabbxyyyypqAzz 1107 >aaaabxyzpqrrrabbxyyyypqAzz 1108 0: aaaabxyzpqrrrabbxyyyypqAzz 1109 >>>>abcxyzpqrrrabbxyyyypqAzz 1110 0: abcxyzpqrrrabbxyyyypqAzz 1111 *** Failers 1112 No match 1113 abxyzpqrrabbxyyyypqAzz 1114 No match 1115 abxyzpqrrrrabbxyyyypqAzz 1116 No match 1117 abxyzpqrrrabxyyyypqAzz 1118 No match 1119 aaaabcxyzzzzpqrrrabbbxyyyyyypqAzz 1120 No match 1121 aaaabcxyzzzzpqrrrabbbxyyypqAzz 1122 No match 1123 aaabcxyzpqrrrabbxyyyypqqqqqqqAzz 1124 No match 1125 1126 /^(abc){1,2}zz/ 1127 abczz 1128 0: abczz 1129 abcabczz 1130 0: abcabczz 1131 *** Failers 1132 No match 1133 zz 1134 No match 1135 abcabcabczz 1136 No match 1137 >>abczz 1138 No match 1139 1140 /^(b+?|a){1,2}?c/ 1141 bc 1142 0: bc 1143 bbc 1144 0: bbc 1145 bbbc 1146 0: bbbc 1147 bac 1148 0: bac 1149 bbac 1150 0: bbac 1151 aac 1152 0: aac 1153 abbbbbbbbbbbc 1154 0: abbbbbbbbbbbc 1155 bbbbbbbbbbbac 1156 0: bbbbbbbbbbbac 1157 *** Failers 1158 No match 1159 aaac 1160 No match 1161 abbbbbbbbbbbac 1162 No match 1163 1164 /^(b+|a){1,2}c/ 1165 bc 1166 0: bc 1167 bbc 1168 0: bbc 1169 bbbc 1170 0: bbbc 1171 bac 1172 0: bac 1173 bbac 1174 0: bbac 1175 aac 1176 0: aac 1177 abbbbbbbbbbbc 1178 0: abbbbbbbbbbbc 1179 bbbbbbbbbbbac 1180 0: bbbbbbbbbbbac 1181 *** Failers 1182 No match 1183 aaac 1184 No match 1185 abbbbbbbbbbbac 1186 No match 1187 1188 /^(b+|a){1,2}?bc/ 1189 bbc 1190 0: bbc 1191 1192 /^(b*|ba){1,2}?bc/ 1193 babc 1194 0: babc 1195 bbabc 1196 0: bbabc 1197 bababc 1198 0: bababc 1199 *** Failers 1200 No match 1201 bababbc 1202 No match 1203 babababc 1204 No match 1205 1206 /^(ba|b*){1,2}?bc/ 1207 babc 1208 0: babc 1209 bbabc 1210 0: bbabc 1211 bababc 1212 0: bababc 1213 *** Failers 1214 No match 1215 bababbc 1216 No match 1217 babababc 1218 No match 1219 1220 /^\ca\cA\c[\c{\c:/ 1221 \x01\x01\e;z 1222 0: \x01\x01\x1b;z 1223 1224 /^[ab\]cde]/ 1225 athing 1226 0: a 1227 bthing 1228 0: b 1229 ]thing 1230 0: ] 1231 cthing 1232 0: c 1233 dthing 1234 0: d 1235 ething 1236 0: e 1237 *** Failers 1238 No match 1239 fthing 1240 No match 1241 [thing 1242 No match 1243 \\thing 1244 No match 1245 1246 /^[]cde]/ 1247 ]thing 1248 0: ] 1249 cthing 1250 0: c 1251 dthing 1252 0: d 1253 ething 1254 0: e 1255 *** Failers 1256 No match 1257 athing 1258 No match 1259 fthing 1260 No match 1261 1262 /^[^ab\]cde]/ 1263 fthing 1264 0: f 1265 [thing 1266 0: [ 1267 \\thing 1268 0: \ 1269 *** Failers 1270 0: * 1271 athing 1272 No match 1273 bthing 1274 No match 1275 ]thing 1276 No match 1277 cthing 1278 No match 1279 dthing 1280 No match 1281 ething 1282 No match 1283 1284 /^[^]cde]/ 1285 athing 1286 0: a 1287 fthing 1288 0: f 1289 *** Failers 1290 0: * 1291 ]thing 1292 No match 1293 cthing 1294 No match 1295 dthing 1296 No match 1297 ething 1298 No match 1299 1300 /^\/ 1301 1302 0: \x81 1303 1304 /^/ 1305 1306 0: \xff 1307 1308 /^[0-9]+$/ 1309 0 1310 0: 0 1311 1 1312 0: 1 1313 2 1314 0: 2 1315 3 1316 0: 3 1317 4 1318 0: 4 1319 5 1320 0: 5 1321 6 1322 0: 6 1323 7 1324 0: 7 1325 8 1326 0: 8 1327 9 1328 0: 9 1329 10 1330 0: 10 1331 100 1332 0: 100 1333 *** Failers 1334 No match 1335 abc 1336 No match 1337 1338 /^.*nter/ 1339 enter 1340 0: enter 1341 inter 1342 0: inter 1343 uponter 1344 0: uponter 1345 1346 /^xxx[0-9]+$/ 1347 xxx0 1348 0: xxx0 1349 xxx1234 1350 0: xxx1234 1351 *** Failers 1352 No match 1353 xxx 1354 No match 1355 1356 /^.+[0-9][0-9][0-9]$/ 1357 x123 1358 0: x123 1359 xx123 1360 0: xx123 1361 123456 1362 0: 123456 1363 *** Failers 1364 No match 1365 123 1366 No match 1367 x1234 1368 0: x1234 1369 1370 /^.+?[0-9][0-9][0-9]$/ 1371 x123 1372 0: x123 1373 xx123 1374 0: xx123 1375 123456 1376 0: 123456 1377 *** Failers 1378 No match 1379 123 1380 No match 1381 x1234 1382 0: x1234 1383 1384 /^([^!]+)!(.+)=apquxz\.ixr\.zzz\.ac\.uk$/ 1385 abc!pqr=apquxz.ixr.zzz.ac.uk 1386 0: abc!pqr=apquxz.ixr.zzz.ac.uk 1387 *** Failers 1388 No match 1389 !pqr=apquxz.ixr.zzz.ac.uk 1390 No match 1391 abc!=apquxz.ixr.zzz.ac.uk 1392 No match 1393 abc!pqr=apquxz:ixr.zzz.ac.uk 1394 No match 1395 abc!pqr=apquxz.ixr.zzz.ac.ukk 1396 No match 1397 1398 /:/ 1399 Well, we need a colon: somewhere 1400 0: : 1401 *** Fail if we don't 1402 No match 1403 1404 /([\da-f:]+)$/i 1405 0abc 1406 0: 0abc 1407 abc 1408 0: abc 1409 fed 1410 0: fed 1411 E 1412 0: E 1413 :: 1414 0: :: 1415 5f03:12C0::932e 1416 0: 5f03:12C0::932e 1417 fed def 1418 0: def 1419 Any old stuff 1420 0: ff 1421 *** Failers 1422 No match 1423 0zzz 1424 No match 1425 gzzz 1426 No match 1427 fed\x20 1428 No match 1429 Any old rubbish 1430 No match 1431 1432 /^.*\.(\d{1,3})\.(\d{1,3})\.(\d{1,3})$/ 1433 .1.2.3 1434 0: .1.2.3 1435 A.12.123.0 1436 0: A.12.123.0 1437 *** Failers 1438 No match 1439 .1.2.3333 1440 No match 1441 1.2.3 1442 No match 1443 1234.2.3 1444 No match 1445 1446 /^(\d+)\s+IN\s+SOA\s+(\S+)\s+(\S+)\s*\(\s*$/ 1447 1 IN SOA non-sp1 non-sp2( 1448 0: 1 IN SOA non-sp1 non-sp2( 1449 1 IN SOA non-sp1 non-sp2 ( 1450 0: 1 IN SOA non-sp1 non-sp2 ( 1451 *** Failers 1452 No match 1453 1IN SOA non-sp1 non-sp2( 1454 No match 1455 1456 /^[a-zA-Z\d][a-zA-Z\d\-]*(\.[a-zA-Z\d][a-zA-z\d\-]*)*\.$/ 1457 a. 1458 0: a. 1459 Z. 1460 0: Z. 1461 2. 1462 0: 2. 1463 ab-c.pq-r. 1464 0: ab-c.pq-r. 1465 sxk.zzz.ac.uk. 1466 0: sxk.zzz.ac.uk. 1467 x-.y-. 1468 0: x-.y-. 1469 *** Failers 1470 No match 1471 -abc.peq. 1472 No match 1473 1474 /^\*\.[a-z]([a-z\-\d]*[a-z\d]+)?(\.[a-z]([a-z\-\d]*[a-z\d]+)?)*$/ 1475 *.a 1476 0: *.a 1477 *.b0-a 1478 0: *.b0-a 1479 *.c3-b.c 1480 0: *.c3-b.c 1481 *.c-a.b-c 1482 0: *.c-a.b-c 1483 *** Failers 1484 No match 1485 *.0 1486 No match 1487 *.a- 1488 No match 1489 *.a-b.c- 1490 No match 1491 *.c-a.0-c 1492 No match 1493 1494 /^(?=ab(de))(abd)(e)/ 1495 abde 1496 0: abde 1497 1498 /^(?!(ab)de|x)(abd)(f)/ 1499 abdf 1500 0: abdf 1501 1502 /^(?=(ab(cd)))(ab)/ 1503 abcd 1504 0: ab 1505 1506 /^[\da-f](\.[\da-f])*$/i 1507 a.b.c.d 1508 0: a.b.c.d 1509 A.B.C.D 1510 0: A.B.C.D 1511 a.b.c.1.2.3.C 1512 0: a.b.c.1.2.3.C 1513 1514 /^\".*\"\s*(;.*)?$/ 1515 \"1234\" 1516 0: "1234" 1517 \"abcd\" ; 1518 0: "abcd" ; 1519 \"\" ; rhubarb 1520 0: "" ; rhubarb 1521 *** Failers 1522 No match 1523 \"1234\" : things 1524 No match 1525 1526 /^$/ 1527 \ 1528 0: 1529 *** Failers 1530 No match 1531 1532 / ^ a (?# begins with a) b\sc (?# then b c) $ (?# then end)/x 1533 ab c 1534 0: ab c 1535 *** Failers 1536 No match 1537 abc 1538 No match 1539 ab cde 1540 No match 1541 1542 /(?x) ^ a (?# begins with a) b\sc (?# then b c) $ (?# then end)/ 1543 ab c 1544 0: ab c 1545 *** Failers 1546 No match 1547 abc 1548 No match 1549 ab cde 1550 No match 1551 1552 /^ a\ b[c ]d $/x 1553 a bcd 1554 0: a bcd 1555 a b d 1556 0: a b d 1557 *** Failers 1558 No match 1559 abcd 1560 No match 1561 ab d 1562 No match 1563 1564 /^(a(b(c)))(d(e(f)))(h(i(j)))(k(l(m)))$/ 1565 abcdefhijklm 1566 0: abcdefhijklm 1567 1568 /^(?:a(b(c)))(?:d(e(f)))(?:h(i(j)))(?:k(l(m)))$/ 1569 abcdefhijklm 1570 0: abcdefhijklm 1571 1572 /^[\w][\W][\s][\S][\d][\D][\b][\n][\c]][\022]/ 1573 a+ Z0+\x08\n\x1d\x12 1574 0: a+ Z0+\x08\x0a\x1d\x12 1575 1576 /^[.^$|()*+?{,}]+/ 1577 .^\$(*+)|{?,?} 1578 0: .^$(*+)|{?,?} 1579 1: .^$(*+)|{?,? 1580 2: .^$(*+)|{?, 1581 3: .^$(*+)|{? 1582 4: .^$(*+)|{ 1583 5: .^$(*+)| 1584 6: .^$(*+) 1585 7: .^$(*+ 1586 8: .^$(* 1587 9: .^$( 1588 10: .^$ 1589 11: .^ 1590 12: . 1591 1592 /^a*\w/ 1593 z 1594 0: z 1595 az 1596 0: az 1597 1: a 1598 aaaz 1599 0: aaaz 1600 1: aaa 1601 2: aa 1602 3: a 1603 a 1604 0: a 1605 aa 1606 0: aa 1607 1: a 1608 aaaa 1609 0: aaaa 1610 1: aaa 1611 2: aa 1612 3: a 1613 a+ 1614 0: a 1615 aa+ 1616 0: aa 1617 1: a 1618 1619 /^a*?\w/ 1620 z 1621 0: z 1622 az 1623 0: az 1624 1: a 1625 aaaz 1626 0: aaaz 1627 1: aaa 1628 2: aa 1629 3: a 1630 a 1631 0: a 1632 aa 1633 0: aa 1634 1: a 1635 aaaa 1636 0: aaaa 1637 1: aaa 1638 2: aa 1639 3: a 1640 a+ 1641 0: a 1642 aa+ 1643 0: aa 1644 1: a 1645 1646 /^a+\w/ 1647 az 1648 0: az 1649 aaaz 1650 0: aaaz 1651 1: aaa 1652 2: aa 1653 aa 1654 0: aa 1655 aaaa 1656 0: aaaa 1657 1: aaa 1658 2: aa 1659 aa+ 1660 0: aa 1661 1662 /^a+?\w/ 1663 az 1664 0: az 1665 aaaz 1666 0: aaaz 1667 1: aaa 1668 2: aa 1669 aa 1670 0: aa 1671 aaaa 1672 0: aaaa 1673 1: aaa 1674 2: aa 1675 aa+ 1676 0: aa 1677 1678 /^\d{8}\w{2,}/ 1679 1234567890 1680 0: 1234567890 1681 12345678ab 1682 0: 12345678ab 1683 12345678__ 1684 0: 12345678__ 1685 *** Failers 1686 No match 1687 1234567 1688 No match 1689 1690 /^[aeiou\d]{4,5}$/ 1691 uoie 1692 0: uoie 1693 1234 1694 0: 1234 1695 12345 1696 0: 12345 1697 aaaaa 1698 0: aaaaa 1699 *** Failers 1700 No match 1701 123456 1702 No match 1703 1704 /^[aeiou\d]{4,5}?/ 1705 uoie 1706 0: uoie 1707 1234 1708 0: 1234 1709 12345 1710 0: 12345 1711 1: 1234 1712 aaaaa 1713 0: aaaaa 1714 1: aaaa 1715 123456 1716 0: 12345 1717 1: 1234 1718 1719 /^From +([^ ]+) +[a-zA-Z][a-zA-Z][a-zA-Z] +[a-zA-Z][a-zA-Z][a-zA-Z] +[0-9]?[0-9] +[0-9][0-9]:[0-9][0-9]/ 1720 From abcd Mon Sep 01 12:33:02 1997 1721 0: From abcd Mon Sep 01 12:33 1722 1723 /^From\s+\S+\s+([a-zA-Z]{3}\s+){2}\d{1,2}\s+\d\d:\d\d/ 1724 From abcd Mon Sep 01 12:33:02 1997 1725 0: From abcd Mon Sep 01 12:33 1726 From abcd Mon Sep 1 12:33:02 1997 1727 0: From abcd Mon Sep 1 12:33 1728 *** Failers 1729 No match 1730 From abcd Sep 01 12:33:02 1997 1731 No match 1732 1733 /^12.34/s 1734 12\n34 1735 0: 12\x0a34 1736 12\r34 1737 0: 12\x0d34 1738 1739 /\w+(?=\t)/ 1740 the quick brown\t fox 1741 0: brown 1742 1743 /foo(?!bar)(.*)/ 1744 foobar is foolish see? 1745 0: foolish see? 1746 1: foolish see 1747 2: foolish se 1748 3: foolish s 1749 4: foolish 1750 5: foolish 1751 6: foolis 1752 7: fooli 1753 8: fool 1754 9: foo 1755 1756 /(?:(?!foo)...|^.{0,2})bar(.*)/ 1757 foobar crowbar etc 1758 0: rowbar etc 1759 1: rowbar et 1760 2: rowbar e 1761 3: rowbar 1762 4: rowbar 1763 barrel 1764 0: barrel 1765 1: barre 1766 2: barr 1767 3: bar 1768 2barrel 1769 0: 2barrel 1770 1: 2barre 1771 2: 2barr 1772 3: 2bar 1773 A barrel 1774 0: A barrel 1775 1: A barre 1776 2: A barr 1777 3: A bar 1778 1779 /^(\D*)(?=\d)(?!123)/ 1780 abc456 1781 0: abc 1782 *** Failers 1783 No match 1784 abc123 1785 No match 1786 1787 /^1234(?# test newlines 1788 inside)/ 1789 1234 1790 0: 1234 1791 1792 /^1234 #comment in extended re 1793 /x 1794 1234 1795 0: 1234 1796 1797 /#rhubarb 1798 abcd/x 1799 abcd 1800 0: abcd 1801 1802 /^abcd#rhubarb/x 1803 abcd 1804 0: abcd 1805 1806 /(?!^)abc/ 1807 the abc 1808 0: abc 1809 *** Failers 1810 No match 1811 abc 1812 No match 1813 1814 /(?=^)abc/ 1815 abc 1816 0: abc 1817 *** Failers 1818 No match 1819 the abc 1820 No match 1821 1822 /^[ab]{1,3}(ab*|b)/ 1823 aabbbbb 1824 0: aabbbbb 1825 1: aabbbb 1826 2: aabbb 1827 3: aabb 1828 4: aab 1829 5: aa 1830 1831 /^[ab]{1,3}?(ab*|b)/ 1832 aabbbbb 1833 0: aabbbbb 1834 1: aabbbb 1835 2: aabbb 1836 3: aabb 1837 4: aab 1838 5: aa 1839 1840 /^[ab]{1,3}?(ab*?|b)/ 1841 aabbbbb 1842 0: aabbbbb 1843 1: aabbbb 1844 2: aabbb 1845 3: aabb 1846 4: aab 1847 5: aa 1848 1849 /^[ab]{1,3}(ab*?|b)/ 1850 aabbbbb 1851 0: aabbbbb 1852 1: aabbbb 1853 2: aabbb 1854 3: aabb 1855 4: aab 1856 5: aa 1857 1858 / (?: [\040\t] | \( 1859 (?: [^\\\x80-\xff\n\015()] | \\ [^\x80-\xff] | \( (?: [^\\\x80-\xff\n\015()] | \\ [^\x80-\xff] )* \) )* 1860 \) )* # optional leading comment 1861 (?: (?: 1862 [^(\040)<>@,;:".\\\[\]\000-\037\x80-\xff]+ # some number of atom characters... 1863 (?![^(\040)<>@,;:".\\\[\]\000-\037\x80-\xff]) # ..not followed by something that could be part of an atom 1864 | 1865 " (?: # opening quote... 1866 [^\\\x80-\xff\n\015"] # Anything except backslash and quote 1867 | # or 1868 \\ [^\x80-\xff] # Escaped something (something != CR) 1869 )* " # closing quote 1870 ) # initial word 1871 (?: (?: [\040\t] | \( 1872 (?: [^\\\x80-\xff\n\015()] | \\ [^\x80-\xff] | \( (?: [^\\\x80-\xff\n\015()] | \\ [^\x80-\xff] )* \) )* 1873 \) )* \. (?: [\040\t] | \( 1874 (?: [^\\\x80-\xff\n\015()] | \\ [^\x80-\xff] | \( (?: [^\\\x80-\xff\n\015()] | \\ [^\x80-\xff] )* \) )* 1875 \) )* (?: 1876 [^(\040)<>@,;:".\\\[\]\000-\037\x80-\xff]+ # some number of atom characters... 1877 (?![^(\040)<>@,;:".\\\[\]\000-\037\x80-\xff]) # ..not followed by something that could be part of an atom 1878 | 1879 " (?: # opening quote... 1880 [^\\\x80-\xff\n\015"] # Anything except backslash and quote 1881 | # or 1882 \\ [^\x80-\xff] # Escaped something (something != CR) 1883 )* " # closing quote 1884 ) )* # further okay, if led by a period 1885 (?: [\040\t] | \( 1886 (?: [^\\\x80-\xff\n\015()] | \\ [^\x80-\xff] | \( (?: [^\\\x80-\xff\n\015()] | \\ [^\x80-\xff] )* \) )* 1887 \) )* @ (?: [\040\t] | \( 1888 (?: [^\\\x80-\xff\n\015()] | \\ [^\x80-\xff] | \( (?: [^\\\x80-\xff\n\015()] | \\ [^\x80-\xff] )* \) )* 1889 \) )* (?: 1890 [^(\040)<>@,;:".\\\[\]\000-\037\x80-\xff]+ # some number of atom characters... 1891 (?![^(\040)<>@,;:".\\\[\]\000-\037\x80-\xff]) # ..not followed by something that could be part of an atom 1892 | \[ # [ 1893 (?: [^\\\x80-\xff\n\015\[\]] | \\ [^\x80-\xff] )* # stuff 1894 \] # ] 1895 ) # initial subdomain 1896 (?: # 1897 (?: [\040\t] | \( 1898 (?: [^\\\x80-\xff\n\015()] | \\ [^\x80-\xff] | \( (?: [^\\\x80-\xff\n\015()] | \\ [^\x80-\xff] )* \) )* 1899 \) )* \. # if led by a period... 1900 (?: [\040\t] | \( 1901 (?: [^\\\x80-\xff\n\015()] | \\ [^\x80-\xff] | \( (?: [^\\\x80-\xff\n\015()] | \\ [^\x80-\xff] )* \) )* 1902 \) )* (?: 1903 [^(\040)<>@,;:".\\\[\]\000-\037\x80-\xff]+ # some number of atom characters... 1904 (?![^(\040)<>@,;:".\\\[\]\000-\037\x80-\xff]) # ..not followed by something that could be part of an atom 1905 | \[ # [ 1906 (?: [^\\\x80-\xff\n\015\[\]] | \\ [^\x80-\xff] )* # stuff 1907 \] # ] 1908 ) # ...further okay 1909 )* 1910 # address 1911 | # or 1912 (?: 1913 [^(\040)<>@,;:".\\\[\]\000-\037\x80-\xff]+ # some number of atom characters... 1914 (?![^(\040)<>@,;:".\\\[\]\000-\037\x80-\xff]) # ..not followed by something that could be part of an atom 1915 | 1916 " (?: # opening quote... 1917 [^\\\x80-\xff\n\015"] # Anything except backslash and quote 1918 | # or 1919 \\ [^\x80-\xff] # Escaped something (something != CR) 1920 )* " # closing quote 1921 ) # one word, optionally followed by.... 1922 (?: 1923 [^()<>@,;:".\\\[\]\x80-\xff\000-\010\012-\037] | # atom and space parts, or... 1924 \( 1925 (?: [^\\\x80-\xff\n\015()] | \\ [^\x80-\xff] | \( (?: [^\\\x80-\xff\n\015()] | \\ [^\x80-\xff] )* \) )* 1926 \) | # comments, or... 1927 1928 " (?: # opening quote... 1929 [^\\\x80-\xff\n\015"] # Anything except backslash and quote 1930 | # or 1931 \\ [^\x80-\xff] # Escaped something (something != CR) 1932 )* " # closing quote 1933 # quoted strings 1934 )* 1935 < (?: [\040\t] | \( 1936 (?: [^\\\x80-\xff\n\015()] | \\ [^\x80-\xff] | \( (?: [^\\\x80-\xff\n\015()] | \\ [^\x80-\xff] )* \) )* 1937 \) )* # leading < 1938 (?: @ (?: [\040\t] | \( 1939 (?: [^\\\x80-\xff\n\015()] | \\ [^\x80-\xff] | \( (?: [^\\\x80-\xff\n\015()] | \\ [^\x80-\xff] )* \) )* 1940 \) )* (?: 1941 [^(\040)<>@,;:".\\\[\]\000-\037\x80-\xff]+ # some number of atom characters... 1942 (?![^(\040)<>@,;:".\\\[\]\000-\037\x80-\xff]) # ..not followed by something that could be part of an atom 1943 | \[ # [ 1944 (?: [^\\\x80-\xff\n\015\[\]] | \\ [^\x80-\xff] )* # stuff 1945 \] # ] 1946 ) # initial subdomain 1947 (?: # 1948 (?: [\040\t] | \( 1949 (?: [^\\\x80-\xff\n\015()] | \\ [^\x80-\xff] | \( (?: [^\\\x80-\xff\n\015()] | \\ [^\x80-\xff] )* \) )* 1950 \) )* \. # if led by a period... 1951 (?: [\040\t] | \( 1952 (?: [^\\\x80-\xff\n\015()] | \\ [^\x80-\xff] | \( (?: [^\\\x80-\xff\n\015()] | \\ [^\x80-\xff] )* \) )* 1953 \) )* (?: 1954 [^(\040)<>@,;:".\\\[\]\000-\037\x80-\xff]+ # some number of atom characters... 1955 (?![^(\040)<>@,;:".\\\[\]\000-\037\x80-\xff]) # ..not followed by something that could be part of an atom 1956 | \[ # [ 1957 (?: [^\\\x80-\xff\n\015\[\]] | \\ [^\x80-\xff] )* # stuff 1958 \] # ] 1959 ) # ...further okay 1960 )* 1961 1962 (?: (?: [\040\t] | \( 1963 (?: [^\\\x80-\xff\n\015()] | \\ [^\x80-\xff] | \( (?: [^\\\x80-\xff\n\015()] | \\ [^\x80-\xff] )* \) )* 1964 \) )* , (?: [\040\t] | \( 1965 (?: [^\\\x80-\xff\n\015()] | \\ [^\x80-\xff] | \( (?: [^\\\x80-\xff\n\015()] | \\ [^\x80-\xff] )* \) )* 1966 \) )* @ (?: [\040\t] | \( 1967 (?: [^\\\x80-\xff\n\015()] | \\ [^\x80-\xff] | \( (?: [^\\\x80-\xff\n\015()] | \\ [^\x80-\xff] )* \) )* 1968 \) )* (?: 1969 [^(\040)<>@,;:".\\\[\]\000-\037\x80-\xff]+ # some number of atom characters... 1970 (?![^(\040)<>@,;:".\\\[\]\000-\037\x80-\xff]) # ..not followed by something that could be part of an atom 1971 | \[ # [ 1972 (?: [^\\\x80-\xff\n\015\[\]] | \\ [^\x80-\xff] )* # stuff 1973 \] # ] 1974 ) # initial subdomain 1975 (?: # 1976 (?: [\040\t] | \( 1977 (?: [^\\\x80-\xff\n\015()] | \\ [^\x80-\xff] | \( (?: [^\\\x80-\xff\n\015()] | \\ [^\x80-\xff] )* \) )* 1978 \) )* \. # if led by a period... 1979 (?: [\040\t] | \( 1980 (?: [^\\\x80-\xff\n\015()] | \\ [^\x80-\xff] | \( (?: [^\\\x80-\xff\n\015()] | \\ [^\x80-\xff] )* \) )* 1981 \) )* (?: 1982 [^(\040)<>@,;:".\\\[\]\000-\037\x80-\xff]+ # some number of atom characters... 1983 (?![^(\040)<>@,;:".\\\[\]\000-\037\x80-\xff]) # ..not followed by something that could be part of an atom 1984 | \[ # [ 1985 (?: [^\\\x80-\xff\n\015\[\]] | \\ [^\x80-\xff] )* # stuff 1986 \] # ] 1987 ) # ...further okay 1988 )* 1989 )* # further okay, if led by comma 1990 : # closing colon 1991 (?: [\040\t] | \( 1992 (?: [^\\\x80-\xff\n\015()] | \\ [^\x80-\xff] | \( (?: [^\\\x80-\xff\n\015()] | \\ [^\x80-\xff] )* \) )* 1993 \) )* )? # optional route 1994 (?: 1995 [^(\040)<>@,;:".\\\[\]\000-\037\x80-\xff]+ # some number of atom characters... 1996 (?![^(\040)<>@,;:".\\\[\]\000-\037\x80-\xff]) # ..not followed by something that could be part of an atom 1997 | 1998 " (?: # opening quote... 1999 [^\\\x80-\xff\n\015"] # Anything except backslash and quote 2000 | # or 2001 \\ [^\x80-\xff] # Escaped something (something != CR) 2002 )* " # closing quote 2003 ) # initial word 2004 (?: (?: [\040\t] | \( 2005 (?: [^\\\x80-\xff\n\015()] | \\ [^\x80-\xff] | \( (?: [^\\\x80-\xff\n\015()] | \\ [^\x80-\xff] )* \) )* 2006 \) )* \. (?: [\040\t] | \( 2007 (?: [^\\\x80-\xff\n\015()] | \\ [^\x80-\xff] | \( (?: [^\\\x80-\xff\n\015()] | \\ [^\x80-\xff] )* \) )* 2008 \) )* (?: 2009 [^(\040)<>@,;:".\\\[\]\000-\037\x80-\xff]+ # some number of atom characters... 2010 (?![^(\040)<>@,;:".\\\[\]\000-\037\x80-\xff]) # ..not followed by something that could be part of an atom 2011 | 2012 " (?: # opening quote... 2013 [^\\\x80-\xff\n\015"] # Anything except backslash and quote 2014 | # or 2015 \\ [^\x80-\xff] # Escaped something (something != CR) 2016 )* " # closing quote 2017 ) )* # further okay, if led by a period 2018 (?: [\040\t] | \( 2019 (?: [^\\\x80-\xff\n\015()] | \\ [^\x80-\xff] | \( (?: [^\\\x80-\xff\n\015()] | \\ [^\x80-\xff] )* \) )* 2020 \) )* @ (?: [\040\t] | \( 2021 (?: [^\\\x80-\xff\n\015()] | \\ [^\x80-\xff] | \( (?: [^\\\x80-\xff\n\015()] | \\ [^\x80-\xff] )* \) )* 2022 \) )* (?: 2023 [^(\040)<>@,;:".\\\[\]\000-\037\x80-\xff]+ # some number of atom characters... 2024 (?![^(\040)<>@,;:".\\\[\]\000-\037\x80-\xff]) # ..not followed by something that could be part of an atom 2025 | \[ # [ 2026 (?: [^\\\x80-\xff\n\015\[\]] | \\ [^\x80-\xff] )* # stuff 2027 \] # ] 2028 ) # initial subdomain 2029 (?: # 2030 (?: [\040\t] | \( 2031 (?: [^\\\x80-\xff\n\015()] | \\ [^\x80-\xff] | \( (?: [^\\\x80-\xff\n\015()] | \\ [^\x80-\xff] )* \) )* 2032 \) )* \. # if led by a period... 2033 (?: [\040\t] | \( 2034 (?: [^\\\x80-\xff\n\015()] | \\ [^\x80-\xff] | \( (?: [^\\\x80-\xff\n\015()] | \\ [^\x80-\xff] )* \) )* 2035 \) )* (?: 2036 [^(\040)<>@,;:".\\\[\]\000-\037\x80-\xff]+ # some number of atom characters... 2037 (?![^(\040)<>@,;:".\\\[\]\000-\037\x80-\xff]) # ..not followed by something that could be part of an atom 2038 | \[ # [ 2039 (?: [^\\\x80-\xff\n\015\[\]] | \\ [^\x80-\xff] )* # stuff 2040 \] # ] 2041 ) # ...further okay 2042 )* 2043 # address spec 2044 (?: [\040\t] | \( 2045 (?: [^\\\x80-\xff\n\015()] | \\ [^\x80-\xff] | \( (?: [^\\\x80-\xff\n\015()] | \\ [^\x80-\xff] )* \) )* 2046 \) )* > # trailing > 2047 # name and address 2048 ) (?: [\040\t] | \( 2049 (?: [^\\\x80-\xff\n\015()] | \\ [^\x80-\xff] | \( (?: [^\\\x80-\xff\n\015()] | \\ [^\x80-\xff] )* \) )* 2050 \) )* # optional trailing comment 2051 /x 2052 Alan Other <user\@dom.ain> 2053 0: Alan Other <user (a] dom.ain> 2054 <user\@dom.ain> 2055 0: user (a] dom.ain 2056 1: user@dom 2057 user\@dom.ain 2058 0: user (a] dom.ain 2059 1: user@dom 2060 \"A. Other\" <user.1234\@dom.ain> (a comment) 2061 0: "A. Other" <user.1234 (a] dom.ain> (a comment) 2062 1: "A. Other" <user.1234 (a] dom.ain> 2063 2: "A. Other" <user.1234 (a] dom.ain> 2064 A. Other <user.1234\@dom.ain> (a comment) 2065 0: Other <user.1234 (a] dom.ain> (a comment) 2066 1: Other <user.1234 (a] dom.ain> 2067 2: Other <user.1234 (a] dom.ain> 2068 \"/s=user/ou=host/o=place/prmd=uu.yy/admd= /c=gb/\"\@x400-re.lay 2069 0: "/s=user/ou=host/o=place/prmd=uu.yy/admd= /c=gb/"@x400-re.lay 2070 1: "/s=user/ou=host/o=place/prmd=uu.yy/admd= /c=gb/"@x400-re 2071 A missing angle <user\@some.where 2072 0: user (a] some.where 2073 1: user@some 2074 *** Failers 2075 No match 2076 The quick brown fox 2077 No match 2078 2079 /[\040\t]* # Nab whitespace. 2080 (?: 2081 \( # ( 2082 [^\\\x80-\xff\n\015()] * # normal* 2083 (?: # ( 2084 (?: \\ [^\x80-\xff] | 2085 \( # ( 2086 [^\\\x80-\xff\n\015()] * # normal* 2087 (?: \\ [^\x80-\xff] [^\\\x80-\xff\n\015()] * )* # (special normal*)* 2088 \) # ) 2089 ) # special 2090 [^\\\x80-\xff\n\015()] * # normal* 2091 )* # )* 2092 \) # ) 2093 [\040\t]* )* # If comment found, allow more spaces. 2094 # optional leading comment 2095 (?: 2096 (?: 2097 [^(\040)<>@,;:".\\\[\]\000-\037\x80-\xff]+ # some number of atom characters... 2098 (?![^(\040)<>@,;:".\\\[\]\000-\037\x80-\xff]) # ..not followed by something that could be part of an atom 2099 # Atom 2100 | # or 2101 " # " 2102 [^\\\x80-\xff\n\015"] * # normal 2103 (?: \\ [^\x80-\xff] [^\\\x80-\xff\n\015"] * )* # ( special normal* )* 2104 " # " 2105 # Quoted string 2106 ) 2107 [\040\t]* # Nab whitespace. 2108 (?: 2109 \( # ( 2110 [^\\\x80-\xff\n\015()] * # normal* 2111 (?: # ( 2112 (?: \\ [^\x80-\xff] | 2113 \( # ( 2114 [^\\\x80-\xff\n\015()] * # normal* 2115 (?: \\ [^\x80-\xff] [^\\\x80-\xff\n\015()] * )* # (special normal*)* 2116 \) # ) 2117 ) # special 2118 [^\\\x80-\xff\n\015()] * # normal* 2119 )* # )* 2120 \) # ) 2121 [\040\t]* )* # If comment found, allow more spaces. 2122 (?: 2123 \. 2124 [\040\t]* # Nab whitespace. 2125 (?: 2126 \( # ( 2127 [^\\\x80-\xff\n\015()] * # normal* 2128 (?: # ( 2129 (?: \\ [^\x80-\xff] | 2130 \( # ( 2131 [^\\\x80-\xff\n\015()] * # normal* 2132 (?: \\ [^\x80-\xff] [^\\\x80-\xff\n\015()] * )* # (special normal*)* 2133 \) # ) 2134 ) # special 2135 [^\\\x80-\xff\n\015()] * # normal* 2136 )* # )* 2137 \) # ) 2138 [\040\t]* )* # If comment found, allow more spaces. 2139 (?: 2140 [^(\040)<>@,;:".\\\[\]\000-\037\x80-\xff]+ # some number of atom characters... 2141 (?![^(\040)<>@,;:".\\\[\]\000-\037\x80-\xff]) # ..not followed by something that could be part of an atom 2142 # Atom 2143 | # or 2144 " # " 2145 [^\\\x80-\xff\n\015"] * # normal 2146 (?: \\ [^\x80-\xff] [^\\\x80-\xff\n\015"] * )* # ( special normal* )* 2147 " # " 2148 # Quoted string 2149 ) 2150 [\040\t]* # Nab whitespace. 2151 (?: 2152 \( # ( 2153 [^\\\x80-\xff\n\015()] * # normal* 2154 (?: # ( 2155 (?: \\ [^\x80-\xff] | 2156 \( # ( 2157 [^\\\x80-\xff\n\015()] * # normal* 2158 (?: \\ [^\x80-\xff] [^\\\x80-\xff\n\015()] * )* # (special normal*)* 2159 \) # ) 2160 ) # special 2161 [^\\\x80-\xff\n\015()] * # normal* 2162 )* # )* 2163 \) # ) 2164 [\040\t]* )* # If comment found, allow more spaces. 2165 # additional words 2166 )* 2167 @ 2168 [\040\t]* # Nab whitespace. 2169 (?: 2170 \( # ( 2171 [^\\\x80-\xff\n\015()] * # normal* 2172 (?: # ( 2173 (?: \\ [^\x80-\xff] | 2174 \( # ( 2175 [^\\\x80-\xff\n\015()] * # normal* 2176 (?: \\ [^\x80-\xff] [^\\\x80-\xff\n\015()] * )* # (special normal*)* 2177 \) # ) 2178 ) # special 2179 [^\\\x80-\xff\n\015()] * # normal* 2180 )* # )* 2181 \) # ) 2182 [\040\t]* )* # If comment found, allow more spaces. 2183 (?: 2184 [^(\040)<>@,;:".\\\[\]\000-\037\x80-\xff]+ # some number of atom characters... 2185 (?![^(\040)<>@,;:".\\\[\]\000-\037\x80-\xff]) # ..not followed by something that could be part of an atom 2186 | 2187 \[ # [ 2188 (?: [^\\\x80-\xff\n\015\[\]] | \\ [^\x80-\xff] )* # stuff 2189 \] # ] 2190 ) 2191 [\040\t]* # Nab whitespace. 2192 (?: 2193 \( # ( 2194 [^\\\x80-\xff\n\015()] * # normal* 2195 (?: # ( 2196 (?: \\ [^\x80-\xff] | 2197 \( # ( 2198 [^\\\x80-\xff\n\015()] * # normal* 2199 (?: \\ [^\x80-\xff] [^\\\x80-\xff\n\015()] * )* # (special normal*)* 2200 \) # ) 2201 ) # special 2202 [^\\\x80-\xff\n\015()] * # normal* 2203 )* # )* 2204 \) # ) 2205 [\040\t]* )* # If comment found, allow more spaces. 2206 # optional trailing comments 2207 (?: 2208 \. 2209 [\040\t]* # Nab whitespace. 2210 (?: 2211 \( # ( 2212 [^\\\x80-\xff\n\015()] * # normal* 2213 (?: # ( 2214 (?: \\ [^\x80-\xff] | 2215 \( # ( 2216 [^\\\x80-\xff\n\015()] * # normal* 2217 (?: \\ [^\x80-\xff] [^\\\x80-\xff\n\015()] * )* # (special normal*)* 2218 \) # ) 2219 ) # special 2220 [^\\\x80-\xff\n\015()] * # normal* 2221 )* # )* 2222 \) # ) 2223 [\040\t]* )* # If comment found, allow more spaces. 2224 (?: 2225 [^(\040)<>@,;:".\\\[\]\000-\037\x80-\xff]+ # some number of atom characters... 2226 (?![^(\040)<>@,;:".\\\[\]\000-\037\x80-\xff]) # ..not followed by something that could be part of an atom 2227 | 2228 \[ # [ 2229 (?: [^\\\x80-\xff\n\015\[\]] | \\ [^\x80-\xff] )* # stuff 2230 \] # ] 2231 ) 2232 [\040\t]* # Nab whitespace. 2233 (?: 2234 \( # ( 2235 [^\\\x80-\xff\n\015()] * # normal* 2236 (?: # ( 2237 (?: \\ [^\x80-\xff] | 2238 \( # ( 2239 [^\\\x80-\xff\n\015()] * # normal* 2240 (?: \\ [^\x80-\xff] [^\\\x80-\xff\n\015()] * )* # (special normal*)* 2241 \) # ) 2242 ) # special 2243 [^\\\x80-\xff\n\015()] * # normal* 2244 )* # )* 2245 \) # ) 2246 [\040\t]* )* # If comment found, allow more spaces. 2247 # optional trailing comments 2248 )* 2249 # address 2250 | # or 2251 (?: 2252 [^(\040)<>@,;:".\\\[\]\000-\037\x80-\xff]+ # some number of atom characters... 2253 (?![^(\040)<>@,;:".\\\[\]\000-\037\x80-\xff]) # ..not followed by something that could be part of an atom 2254 # Atom 2255 | # or 2256 " # " 2257 [^\\\x80-\xff\n\015"] * # normal 2258 (?: \\ [^\x80-\xff] [^\\\x80-\xff\n\015"] * )* # ( special normal* )* 2259 " # " 2260 # Quoted string 2261 ) 2262 # leading word 2263 [^()<>@,;:".\\\[\]\x80-\xff\000-\010\012-\037] * # "normal" atoms and or spaces 2264 (?: 2265 (?: 2266 \( # ( 2267 [^\\\x80-\xff\n\015()] * # normal* 2268 (?: # ( 2269 (?: \\ [^\x80-\xff] | 2270 \( # ( 2271 [^\\\x80-\xff\n\015()] * # normal* 2272 (?: \\ [^\x80-\xff] [^\\\x80-\xff\n\015()] * )* # (special normal*)* 2273 \) # ) 2274 ) # special 2275 [^\\\x80-\xff\n\015()] * # normal* 2276 )* # )* 2277 \) # ) 2278 | 2279 " # " 2280 [^\\\x80-\xff\n\015"] * # normal 2281 (?: \\ [^\x80-\xff] [^\\\x80-\xff\n\015"] * )* # ( special normal* )* 2282 " # " 2283 ) # "special" comment or quoted string 2284 [^()<>@,;:".\\\[\]\x80-\xff\000-\010\012-\037] * # more "normal" 2285 )* 2286 < 2287 [\040\t]* # Nab whitespace. 2288 (?: 2289 \( # ( 2290 [^\\\x80-\xff\n\015()] * # normal* 2291 (?: # ( 2292 (?: \\ [^\x80-\xff] | 2293 \( # ( 2294 [^\\\x80-\xff\n\015()] * # normal* 2295 (?: \\ [^\x80-\xff] [^\\\x80-\xff\n\015()] * )* # (special normal*)* 2296 \) # ) 2297 ) # special 2298 [^\\\x80-\xff\n\015()] * # normal* 2299 )* # )* 2300 \) # ) 2301 [\040\t]* )* # If comment found, allow more spaces. 2302 # < 2303 (?: 2304 @ 2305 [\040\t]* # Nab whitespace. 2306 (?: 2307 \( # ( 2308 [^\\\x80-\xff\n\015()] * # normal* 2309 (?: # ( 2310 (?: \\ [^\x80-\xff] | 2311 \( # ( 2312 [^\\\x80-\xff\n\015()] * # normal* 2313 (?: \\ [^\x80-\xff] [^\\\x80-\xff\n\015()] * )* # (special normal*)* 2314 \) # ) 2315 ) # special 2316 [^\\\x80-\xff\n\015()] * # normal* 2317 )* # )* 2318 \) # ) 2319 [\040\t]* )* # If comment found, allow more spaces. 2320 (?: 2321 [^(\040)<>@,;:".\\\[\]\000-\037\x80-\xff]+ # some number of atom characters... 2322 (?![^(\040)<>@,;:".\\\[\]\000-\037\x80-\xff]) # ..not followed by something that could be part of an atom 2323 | 2324 \[ # [ 2325 (?: [^\\\x80-\xff\n\015\[\]] | \\ [^\x80-\xff] )* # stuff 2326 \] # ] 2327 ) 2328 [\040\t]* # Nab whitespace. 2329 (?: 2330 \( # ( 2331 [^\\\x80-\xff\n\015()] * # normal* 2332 (?: # ( 2333 (?: \\ [^\x80-\xff] | 2334 \( # ( 2335 [^\\\x80-\xff\n\015()] * # normal* 2336 (?: \\ [^\x80-\xff] [^\\\x80-\xff\n\015()] * )* # (special normal*)* 2337 \) # ) 2338 ) # special 2339 [^\\\x80-\xff\n\015()] * # normal* 2340 )* # )* 2341 \) # ) 2342 [\040\t]* )* # If comment found, allow more spaces. 2343 # optional trailing comments 2344 (?: 2345 \. 2346 [\040\t]* # Nab whitespace. 2347 (?: 2348 \( # ( 2349 [^\\\x80-\xff\n\015()] * # normal* 2350 (?: # ( 2351 (?: \\ [^\x80-\xff] | 2352 \( # ( 2353 [^\\\x80-\xff\n\015()] * # normal* 2354 (?: \\ [^\x80-\xff] [^\\\x80-\xff\n\015()] * )* # (special normal*)* 2355 \) # ) 2356 ) # special 2357 [^\\\x80-\xff\n\015()] * # normal* 2358 )* # )* 2359 \) # ) 2360 [\040\t]* )* # If comment found, allow more spaces. 2361 (?: 2362 [^(\040)<>@,;:".\\\[\]\000-\037\x80-\xff]+ # some number of atom characters... 2363 (?![^(\040)<>@,;:".\\\[\]\000-\037\x80-\xff]) # ..not followed by something that could be part of an atom 2364 | 2365 \[ # [ 2366 (?: [^\\\x80-\xff\n\015\[\]] | \\ [^\x80-\xff] )* # stuff 2367 \] # ] 2368 ) 2369 [\040\t]* # Nab whitespace. 2370 (?: 2371 \( # ( 2372 [^\\\x80-\xff\n\015()] * # normal* 2373 (?: # ( 2374 (?: \\ [^\x80-\xff] | 2375 \( # ( 2376 [^\\\x80-\xff\n\015()] * # normal* 2377 (?: \\ [^\x80-\xff] [^\\\x80-\xff\n\015()] * )* # (special normal*)* 2378 \) # ) 2379 ) # special 2380 [^\\\x80-\xff\n\015()] * # normal* 2381 )* # )* 2382 \) # ) 2383 [\040\t]* )* # If comment found, allow more spaces. 2384 # optional trailing comments 2385 )* 2386 (?: , 2387 [\040\t]* # Nab whitespace. 2388 (?: 2389 \( # ( 2390 [^\\\x80-\xff\n\015()] * # normal* 2391 (?: # ( 2392 (?: \\ [^\x80-\xff] | 2393 \( # ( 2394 [^\\\x80-\xff\n\015()] * # normal* 2395 (?: \\ [^\x80-\xff] [^\\\x80-\xff\n\015()] * )* # (special normal*)* 2396 \) # ) 2397 ) # special 2398 [^\\\x80-\xff\n\015()] * # normal* 2399 )* # )* 2400 \) # ) 2401 [\040\t]* )* # If comment found, allow more spaces. 2402 @ 2403 [\040\t]* # Nab whitespace. 2404 (?: 2405 \( # ( 2406 [^\\\x80-\xff\n\015()] * # normal* 2407 (?: # ( 2408 (?: \\ [^\x80-\xff] | 2409 \( # ( 2410 [^\\\x80-\xff\n\015()] * # normal* 2411 (?: \\ [^\x80-\xff] [^\\\x80-\xff\n\015()] * )* # (special normal*)* 2412 \) # ) 2413 ) # special 2414 [^\\\x80-\xff\n\015()] * # normal* 2415 )* # )* 2416 \) # ) 2417 [\040\t]* )* # If comment found, allow more spaces. 2418 (?: 2419 [^(\040)<>@,;:".\\\[\]\000-\037\x80-\xff]+ # some number of atom characters... 2420 (?![^(\040)<>@,;:".\\\[\]\000-\037\x80-\xff]) # ..not followed by something that could be part of an atom 2421 | 2422 \[ # [ 2423 (?: [^\\\x80-\xff\n\015\[\]] | \\ [^\x80-\xff] )* # stuff 2424 \] # ] 2425 ) 2426 [\040\t]* # Nab whitespace. 2427 (?: 2428 \( # ( 2429 [^\\\x80-\xff\n\015()] * # normal* 2430 (?: # ( 2431 (?: \\ [^\x80-\xff] | 2432 \( # ( 2433 [^\\\x80-\xff\n\015()] * # normal* 2434 (?: \\ [^\x80-\xff] [^\\\x80-\xff\n\015()] * )* # (special normal*)* 2435 \) # ) 2436 ) # special 2437 [^\\\x80-\xff\n\015()] * # normal* 2438 )* # )* 2439 \) # ) 2440 [\040\t]* )* # If comment found, allow more spaces. 2441 # optional trailing comments 2442 (?: 2443 \. 2444 [\040\t]* # Nab whitespace. 2445 (?: 2446 \( # ( 2447 [^\\\x80-\xff\n\015()] * # normal* 2448 (?: # ( 2449 (?: \\ [^\x80-\xff] | 2450 \( # ( 2451 [^\\\x80-\xff\n\015()] * # normal* 2452 (?: \\ [^\x80-\xff] [^\\\x80-\xff\n\015()] * )* # (special normal*)* 2453 \) # ) 2454 ) # special 2455 [^\\\x80-\xff\n\015()] * # normal* 2456 )* # )* 2457 \) # ) 2458 [\040\t]* )* # If comment found, allow more spaces. 2459 (?: 2460 [^(\040)<>@,;:".\\\[\]\000-\037\x80-\xff]+ # some number of atom characters... 2461 (?![^(\040)<>@,;:".\\\[\]\000-\037\x80-\xff]) # ..not followed by something that could be part of an atom 2462 | 2463 \[ # [ 2464 (?: [^\\\x80-\xff\n\015\[\]] | \\ [^\x80-\xff] )* # stuff 2465 \] # ] 2466 ) 2467 [\040\t]* # Nab whitespace. 2468 (?: 2469 \( # ( 2470 [^\\\x80-\xff\n\015()] * # normal* 2471 (?: # ( 2472 (?: \\ [^\x80-\xff] | 2473 \( # ( 2474 [^\\\x80-\xff\n\015()] * # normal* 2475 (?: \\ [^\x80-\xff] [^\\\x80-\xff\n\015()] * )* # (special normal*)* 2476 \) # ) 2477 ) # special 2478 [^\\\x80-\xff\n\015()] * # normal* 2479 )* # )* 2480 \) # ) 2481 [\040\t]* )* # If comment found, allow more spaces. 2482 # optional trailing comments 2483 )* 2484 )* # additional domains 2485 : 2486 [\040\t]* # Nab whitespace. 2487 (?: 2488 \( # ( 2489 [^\\\x80-\xff\n\015()] * # normal* 2490 (?: # ( 2491 (?: \\ [^\x80-\xff] | 2492 \( # ( 2493 [^\\\x80-\xff\n\015()] * # normal* 2494 (?: \\ [^\x80-\xff] [^\\\x80-\xff\n\015()] * )* # (special normal*)* 2495 \) # ) 2496 ) # special 2497 [^\\\x80-\xff\n\015()] * # normal* 2498 )* # )* 2499 \) # ) 2500 [\040\t]* )* # If comment found, allow more spaces. 2501 # optional trailing comments 2502 )? # optional route 2503 (?: 2504 [^(\040)<>@,;:".\\\[\]\000-\037\x80-\xff]+ # some number of atom characters... 2505 (?![^(\040)<>@,;:".\\\[\]\000-\037\x80-\xff]) # ..not followed by something that could be part of an atom 2506 # Atom 2507 | # or 2508 " # " 2509 [^\\\x80-\xff\n\015"] * # normal 2510 (?: \\ [^\x80-\xff] [^\\\x80-\xff\n\015"] * )* # ( special normal* )* 2511 " # " 2512 # Quoted string 2513 ) 2514 [\040\t]* # Nab whitespace. 2515 (?: 2516 \( # ( 2517 [^\\\x80-\xff\n\015()] * # normal* 2518 (?: # ( 2519 (?: \\ [^\x80-\xff] | 2520 \( # ( 2521 [^\\\x80-\xff\n\015()] * # normal* 2522 (?: \\ [^\x80-\xff] [^\\\x80-\xff\n\015()] * )* # (special normal*)* 2523 \) # ) 2524 ) # special 2525 [^\\\x80-\xff\n\015()] * # normal* 2526 )* # )* 2527 \) # ) 2528 [\040\t]* )* # If comment found, allow more spaces. 2529 (?: 2530 \. 2531 [\040\t]* # Nab whitespace. 2532 (?: 2533 \( # ( 2534 [^\\\x80-\xff\n\015()] * # normal* 2535 (?: # ( 2536 (?: \\ [^\x80-\xff] | 2537 \( # ( 2538 [^\\\x80-\xff\n\015()] * # normal* 2539 (?: \\ [^\x80-\xff] [^\\\x80-\xff\n\015()] * )* # (special normal*)* 2540 \) # ) 2541 ) # special 2542 [^\\\x80-\xff\n\015()] * # normal* 2543 )* # )* 2544 \) # ) 2545 [\040\t]* )* # If comment found, allow more spaces. 2546 (?: 2547 [^(\040)<>@,;:".\\\[\]\000-\037\x80-\xff]+ # some number of atom characters... 2548 (?![^(\040)<>@,;:".\\\[\]\000-\037\x80-\xff]) # ..not followed by something that could be part of an atom 2549 # Atom 2550 | # or 2551 " # " 2552 [^\\\x80-\xff\n\015"] * # normal 2553 (?: \\ [^\x80-\xff] [^\\\x80-\xff\n\015"] * )* # ( special normal* )* 2554 " # " 2555 # Quoted string 2556 ) 2557 [\040\t]* # Nab whitespace. 2558 (?: 2559 \( # ( 2560 [^\\\x80-\xff\n\015()] * # normal* 2561 (?: # ( 2562 (?: \\ [^\x80-\xff] | 2563 \( # ( 2564 [^\\\x80-\xff\n\015()] * # normal* 2565 (?: \\ [^\x80-\xff] [^\\\x80-\xff\n\015()] * )* # (special normal*)* 2566 \) # ) 2567 ) # special 2568 [^\\\x80-\xff\n\015()] * # normal* 2569 )* # )* 2570 \) # ) 2571 [\040\t]* )* # If comment found, allow more spaces. 2572 # additional words 2573 )* 2574 @ 2575 [\040\t]* # Nab whitespace. 2576 (?: 2577 \( # ( 2578 [^\\\x80-\xff\n\015()] * # normal* 2579 (?: # ( 2580 (?: \\ [^\x80-\xff] | 2581 \( # ( 2582 [^\\\x80-\xff\n\015()] * # normal* 2583 (?: \\ [^\x80-\xff] [^\\\x80-\xff\n\015()] * )* # (special normal*)* 2584 \) # ) 2585 ) # special 2586 [^\\\x80-\xff\n\015()] * # normal* 2587 )* # )* 2588 \) # ) 2589 [\040\t]* )* # If comment found, allow more spaces. 2590 (?: 2591 [^(\040)<>@,;:".\\\[\]\000-\037\x80-\xff]+ # some number of atom characters... 2592 (?![^(\040)<>@,;:".\\\[\]\000-\037\x80-\xff]) # ..not followed by something that could be part of an atom 2593 | 2594 \[ # [ 2595 (?: [^\\\x80-\xff\n\015\[\]] | \\ [^\x80-\xff] )* # stuff 2596 \] # ] 2597 ) 2598 [\040\t]* # Nab whitespace. 2599 (?: 2600 \( # ( 2601 [^\\\x80-\xff\n\015()] * # normal* 2602 (?: # ( 2603 (?: \\ [^\x80-\xff] | 2604 \( # ( 2605 [^\\\x80-\xff\n\015()] * # normal* 2606 (?: \\ [^\x80-\xff] [^\\\x80-\xff\n\015()] * )* # (special normal*)* 2607 \) # ) 2608 ) # special 2609 [^\\\x80-\xff\n\015()] * # normal* 2610 )* # )* 2611 \) # ) 2612 [\040\t]* )* # If comment found, allow more spaces. 2613 # optional trailing comments 2614 (?: 2615 \. 2616 [\040\t]* # Nab whitespace. 2617 (?: 2618 \( # ( 2619 [^\\\x80-\xff\n\015()] * # normal* 2620 (?: # ( 2621 (?: \\ [^\x80-\xff] | 2622 \( # ( 2623 [^\\\x80-\xff\n\015()] * # normal* 2624 (?: \\ [^\x80-\xff] [^\\\x80-\xff\n\015()] * )* # (special normal*)* 2625 \) # ) 2626 ) # special 2627 [^\\\x80-\xff\n\015()] * # normal* 2628 )* # )* 2629 \) # ) 2630 [\040\t]* )* # If comment found, allow more spaces. 2631 (?: 2632 [^(\040)<>@,;:".\\\[\]\000-\037\x80-\xff]+ # some number of atom characters... 2633 (?![^(\040)<>@,;:".\\\[\]\000-\037\x80-\xff]) # ..not followed by something that could be part of an atom 2634 | 2635 \[ # [ 2636 (?: [^\\\x80-\xff\n\015\[\]] | \\ [^\x80-\xff] )* # stuff 2637 \] # ] 2638 ) 2639 [\040\t]* # Nab whitespace. 2640 (?: 2641 \( # ( 2642 [^\\\x80-\xff\n\015()] * # normal* 2643 (?: # ( 2644 (?: \\ [^\x80-\xff] | 2645 \( # ( 2646 [^\\\x80-\xff\n\015()] * # normal* 2647 (?: \\ [^\x80-\xff] [^\\\x80-\xff\n\015()] * )* # (special normal*)* 2648 \) # ) 2649 ) # special 2650 [^\\\x80-\xff\n\015()] * # normal* 2651 )* # )* 2652 \) # ) 2653 [\040\t]* )* # If comment found, allow more spaces. 2654 # optional trailing comments 2655 )* 2656 # address spec 2657 > # > 2658 # name and address 2659 ) 2660 /x 2661 Alan Other <user\@dom.ain> 2662 0: Alan Other <user (a] dom.ain> 2663 <user\@dom.ain> 2664 0: user (a] dom.ain 2665 1: user@dom 2666 user\@dom.ain 2667 0: user (a] dom.ain 2668 1: user@dom 2669 \"A. Other\" <user.1234\@dom.ain> (a comment) 2670 0: "A. Other" <user.1234 (a] dom.ain> 2671 A. Other <user.1234\@dom.ain> (a comment) 2672 0: Other <user.1234 (a] dom.ain> 2673 \"/s=user/ou=host/o=place/prmd=uu.yy/admd= /c=gb/\"\@x400-re.lay 2674 0: "/s=user/ou=host/o=place/prmd=uu.yy/admd= /c=gb/"@x400-re.lay 2675 1: "/s=user/ou=host/o=place/prmd=uu.yy/admd= /c=gb/"@x400-re 2676 A missing angle <user\@some.where 2677 0: user (a] some.where 2678 1: user@some 2679 *** Failers 2680 No match 2681 The quick brown fox 2682 No match 2683 2684 /abc\0def\00pqr\000xyz\0000AB/ 2685 abc\0def\00pqr\000xyz\0000AB 2686 0: abc\x00def\x00pqr\x00xyz\x000AB 2687 abc456 abc\0def\00pqr\000xyz\0000ABCDE 2688 0: abc\x00def\x00pqr\x00xyz\x000AB 2689 2690 /abc\x0def\x00pqr\x000xyz\x0000AB/ 2691 abc\x0def\x00pqr\x000xyz\x0000AB 2692 0: abc\x0def\x00pqr\x000xyz\x0000AB 2693 abc456 abc\x0def\x00pqr\x000xyz\x0000ABCDE 2694 0: abc\x0def\x00pqr\x000xyz\x0000AB 2695 2696 /^[\000-\037]/ 2697 \0A 2698 0: \x00 2699 \01B 2700 0: \x01 2701 \037C 2702 0: \x1f 2703 2704 /\0*/ 2705 \0\0\0\0 2706 0: \x00\x00\x00\x00 2707 1: \x00\x00\x00 2708 2: \x00\x00 2709 3: \x00 2710 4: 2711 2712 /A\x0{2,3}Z/ 2713 The A\x0\x0Z 2714 0: A\x00\x00Z 2715 An A\0\x0\0Z 2716 0: A\x00\x00\x00Z 2717 *** Failers 2718 No match 2719 A\0Z 2720 No match 2721 A\0\x0\0\x0Z 2722 No match 2723 2724 /^\s/ 2725 \040abc 2726 0: 2727 \x0cabc 2728 0: \x0c 2729 \nabc 2730 0: \x0a 2731 \rabc 2732 0: \x0d 2733 \tabc 2734 0: \x09 2735 *** Failers 2736 No match 2737 abc 2738 No match 2739 2740 /^a b 2741 c/x 2743 abc 2744 0: abc 2745 2746 /ab{1,3}bc/ 2747 abbbbc 2748 0: abbbbc 2749 abbbc 2750 0: abbbc 2751 abbc 2752 0: abbc 2753 *** Failers 2754 No match 2755 abc 2756 No match 2757 abbbbbc 2758 No match 2759 2760 /([^.]*)\.([^:]*):[T ]+(.*)/ 2761 track1.title:TBlah blah blah 2762 0: track1.title:TBlah blah blah 2763 1: track1.title:TBlah blah bla 2764 2: track1.title:TBlah blah bl 2765 3: track1.title:TBlah blah b 2766 4: track1.title:TBlah blah 2767 5: track1.title:TBlah blah 2768 6: track1.title:TBlah bla 2769 7: track1.title:TBlah bl 2770 8: track1.title:TBlah b 2771 9: track1.title:TBlah 2772 10: track1.title:TBlah 2773 11: track1.title:TBla 2774 12: track1.title:TBl 2775 13: track1.title:TB 2776 14: track1.title:T 2777 2778 /([^.]*)\.([^:]*):[T ]+(.*)/i 2779 track1.title:TBlah blah blah 2780 0: track1.title:TBlah blah blah 2781 1: track1.title:TBlah blah bla 2782 2: track1.title:TBlah blah bl 2783 3: track1.title:TBlah blah b 2784 4: track1.title:TBlah blah 2785 5: track1.title:TBlah blah 2786 6: track1.title:TBlah bla 2787 7: track1.title:TBlah bl 2788 8: track1.title:TBlah b 2789 9: track1.title:TBlah 2790 10: track1.title:TBlah 2791 11: track1.title:TBla 2792 12: track1.title:TBl 2793 13: track1.title:TB 2794 14: track1.title:T 2795 2796 /([^.]*)\.([^:]*):[t ]+(.*)/i 2797 track1.title:TBlah blah blah 2798 0: track1.title:TBlah blah blah 2799 1: track1.title:TBlah blah bla 2800 2: track1.title:TBlah blah bl 2801 3: track1.title:TBlah blah b 2802 4: track1.title:TBlah blah 2803 5: track1.title:TBlah blah 2804 6: track1.title:TBlah bla 2805 7: track1.title:TBlah bl 2806 8: track1.title:TBlah b 2807 9: track1.title:TBlah 2808 10: track1.title:TBlah 2809 11: track1.title:TBla 2810 12: track1.title:TBl 2811 13: track1.title:TB 2812 14: track1.title:T 2813 2814 /^[W-c]+$/ 2815 WXY_^abc 2816 0: WXY_^abc 2817 *** Failers 2818 No match 2819 wxy 2820 No match 2821 2822 /^[W-c]+$/i 2823 WXY_^abc 2824 0: WXY_^abc 2825 wxy_^ABC 2826 0: wxy_^ABC 2827 2828 /^[\x3f-\x5F]+$/i 2829 WXY_^abc 2830 0: WXY_^abc 2831 wxy_^ABC 2832 0: wxy_^ABC 2833 2834 /^abc$/m 2835 abc 2836 0: abc 2837 qqq\nabc 2838 0: abc 2839 abc\nzzz 2840 0: abc 2841 qqq\nabc\nzzz 2842 0: abc 2843 2844 /^abc$/ 2845 abc 2846 0: abc 2847 *** Failers 2848 No match 2849 qqq\nabc 2850 No match 2851 abc\nzzz 2852 No match 2853 qqq\nabc\nzzz 2854 No match 2855 2856 /\Aabc\Z/m 2857 abc 2858 0: abc 2859 abc\n 2860 0: abc 2861 *** Failers 2862 No match 2863 qqq\nabc 2864 No match 2865 abc\nzzz 2866 No match 2867 qqq\nabc\nzzz 2868 No match 2869 2870 /\A(.)*\Z/s 2871 abc\ndef 2872 0: abc\x0adef 2873 2874 /\A(.)*\Z/m 2875 *** Failers 2876 0: *** Failers 2877 abc\ndef 2878 No match 2879 2880 /(?:b)|(?::+)/ 2881 b::c 2882 0: b 2883 c::b 2884 0: :: 2885 1: : 2886 2887 /[-az]+/ 2888 az- 2889 0: az- 2890 1: az 2891 2: a 2892 *** Failers 2893 0: a 2894 b 2895 No match 2896 2897 /[az-]+/ 2898 za- 2899 0: za- 2900 1: za 2901 2: z 2902 *** Failers 2903 0: a 2904 b 2905 No match 2906 2907 /[a\-z]+/ 2908 a-z 2909 0: a-z 2910 1: a- 2911 2: a 2912 *** Failers 2913 0: a 2914 b 2915 No match 2916 2917 /[a-z]+/ 2918 abcdxyz 2919 0: abcdxyz 2920 1: abcdxy 2921 2: abcdx 2922 3: abcd 2923 4: abc 2924 5: ab 2925 6: a 2926 2927 /[\d-]+/ 2928 12-34 2929 0: 12-34 2930 1: 12-3 2931 2: 12- 2932 3: 12 2933 4: 1 2934 *** Failers 2935 No match 2936 aaa 2937 No match 2938 2939 /[\d-z]+/ 2940 12-34z 2941 0: 12-34z 2942 1: 12-34 2943 2: 12-3 2944 3: 12- 2945 4: 12 2946 5: 1 2947 *** Failers 2948 No match 2949 aaa 2950 No match 2951 2952 /\x5c/ 2953 \\ 2954 0: \ 2955 2956 /\x20Z/ 2957 the Zoo 2958 0: Z 2959 *** Failers 2960 No match 2961 Zulu 2962 No match 2963 2964 /ab{3cd/ 2965 ab{3cd 2966 0: ab{3cd 2967 2968 /ab{3,cd/ 2969 ab{3,cd 2970 0: ab{3,cd 2971 2972 /ab{3,4a}cd/ 2973 ab{3,4a}cd 2974 0: ab{3,4a}cd 2975 2976 /{4,5a}bc/ 2977 {4,5a}bc 2978 0: {4,5a}bc 2979 2980 /^a.b/<lf> 2981 a\rb 2982 0: a\x0db 2983 *** Failers 2984 No match 2985 a\nb 2986 No match 2987 2988 /abc$/ 2989 abc 2990 0: abc 2991 abc\n 2992 0: abc 2993 *** Failers 2994 No match 2995 abc\ndef 2996 No match 2997 2998 /(abc)\123/ 2999 abc\x53 3000 0: abcS 3001 3002 /(abc)\223/ 3003 abc\x93 3004 0: abc\x93 3005 3006 /(abc)\323/ 3007 abc\xd3 3008 0: abc\xd3 3009 3010 /(abc)\100/ 3011 abc\x40 3012 0: abc@ 3013 abc\100 3014 0: abc@ 3015 3016 /(abc)\1000/ 3017 abc\x400 3018 0: abc@0 3019 abc\x40\x30 3020 0: abc@0 3021 abc\1000 3022 0: abc@0 3023 abc\100\x30 3024 0: abc@0 3025 abc\100\060 3026 0: abc@0 3027 abc\100\60 3028 0: abc@0 3029 3030 /abc\81/ 3031 abc\081 3032 0: abc\x0081 3033 abc\0\x38\x31 3034 0: abc\x0081 3035 3036 /abc\91/ 3037 abc\091 3038 0: abc\x0091 3039 abc\0\x39\x31 3040 0: abc\x0091 3041 3042 /(a)(b)(c)(d)(e)(f)(g)(h)(i)(j)(k)\12\123/ 3043 abcdefghijk\12S 3044 0: abcdefghijk\x0aS 3045 3046 /ab\idef/ 3047 abidef 3048 0: abidef 3049 3050 /a{0}bc/ 3051 bc 3052 0: bc 3053 3054 /(a|(bc)){0,0}?xyz/ 3055 xyz 3056 0: xyz 3057 3058 /abc[\10]de/ 3059 abc\010de 3060 0: abc\x08de 3061 3062 /abc[\1]de/ 3063 abc\1de 3064 0: abc\x01de 3065 3066 /(abc)[\1]de/ 3067 abc\1de 3068 0: abc\x01de 3069 3070 /(?s)a.b/ 3071 a\nb 3072 0: a\x0ab 3073 3074 /^([^a])([^\b])([^c]*)([^d]{3,4})/ 3075 baNOTccccd 3076 0: baNOTcccc 3077 1: baNOTccc 3078 2: baNOTcc 3079 3: baNOTc 3080 4: baNOT 3081 baNOTcccd 3082 0: baNOTccc 3083 1: baNOTcc 3084 2: baNOTc 3085 3: baNOT 3086 baNOTccd 3087 0: baNOTcc 3088 1: baNOTc 3089 2: baNOT 3090 bacccd 3091 0: baccc 3092 *** Failers 3093 0: *** Failers 3094 1: *** Failer 3095 2: *** Faile 3096 3: *** Fail 3097 4: *** Fai 3098 5: *** Fa 3099 6: *** F 3100 anything 3101 No match 3102 b\bc 3103 No match 3104 baccd 3105 No match 3106 3107 /[^a]/ 3108 Abc 3109 0: A 3110 3111 /[^a]/i 3112 Abc 3113 0: b 3114 3115 /[^a]+/ 3116 AAAaAbc 3117 0: AAA 3118 1: AA 3119 2: A 3120 3121 /[^a]+/i 3122 AAAaAbc 3123 0: bc 3124 1: b 3125 3126 /[^a]+/ 3127 bbb\nccc 3128 0: bbb\x0accc 3129 1: bbb\x0acc 3130 2: bbb\x0ac 3131 3: bbb\x0a 3132 4: bbb 3133 5: bb 3134 6: b 3135 3136 /[^k]$/ 3137 abc 3138 0: c 3139 *** Failers 3140 0: s 3141 abk 3142 No match 3143 3144 /[^k]{2,3}$/ 3145 abc 3146 0: abc 3147 kbc 3148 0: bc 3149 kabc 3150 0: abc 3151 *** Failers 3152 0: ers 3153 abk 3154 No match 3155 akb 3156 No match 3157 akk 3158 No match 3159 3160 /^\d{8,}\@.+[^k]$/ 3161 12345678\@a.b.c.d 3162 0: 12345678 (a] a.b.c.d 3163 123456789\@x.y.z 3164 0: 123456789 (a] x.y.z 3165 *** Failers 3166 No match 3167 12345678\@x.y.uk 3168 No match 3169 1234567\@a.b.c.d 3170 No match 3171 3172 /[^a]/ 3173 aaaabcd 3174 0: b 3175 aaAabcd 3176 0: A 3177 3178 /[^a]/i 3179 aaaabcd 3180 0: b 3181 aaAabcd 3182 0: b 3183 3184 /[^az]/ 3185 aaaabcd 3186 0: b 3187 aaAabcd 3188 0: A 3189 3190 /[^az]/i 3191 aaaabcd 3192 0: b 3193 aaAabcd 3194 0: b 3195 3196 /\000\001\002\003\004\005\006\007\010\011\012\013\014\015\016\017\020\021\022\023\024\025\026\027\030\031\032\033\034\035\036\037\040\041\042\043\044\045\046\047\050\051\052\053\054\055\056\057\060\061\062\063\064\065\066\067\070\071\072\073\074\075\076\077\100\101\102\103\104\105\106\107\110\111\112\113\114\115\116\117\120\121\122\123\124\125\126\127\130\131\132\133\134\135\136\137\140\141\142\143\144\145\146\147\150\151\152\153\154\155\156\157\160\161\162\163\164\165\166\167\170\171\172\173\174\175\176\177\200\201\202\203\204\205\206\207\210\211\212\213\214\215\216\217\220\221\222\223\224\225\226\227\230\231\232\233\234\235\236\237\240\241\242\243\244\245\246\247\250\251\252\253\254\255\256\257\260\261\262\263\264\265\266\267\270\271\272\273\274\275\276\277\300\301\302\303\304\305\306\307\310\311\312\313\314\315\316\317\320\321\322\323\324\325\326\327\330\331\332\333\334\335\336\337\340\341\342\343\344\345\346\347\350\351\352\353\354\355\356\357\360\361\362\363\364\365\366\367\370\371\372\373\374\375\376\377/ 3197 \000\001\002\003\004\005\006\007\010\011\012\013\014\015\016\017\020\021\022\023\024\025\026\027\030\031\032\033\034\035\036\037\040\041\042\043\044\045\046\047\050\051\052\053\054\055\056\057\060\061\062\063\064\065\066\067\070\071\072\073\074\075\076\077\100\101\102\103\104\105\106\107\110\111\112\113\114\115\116\117\120\121\122\123\124\125\126\127\130\131\132\133\134\135\136\137\140\141\142\143\144\145\146\147\150\151\152\153\154\155\156\157\160\161\162\163\164\165\166\167\170\171\172\173\174\175\176\177\200\201\202\203\204\205\206\207\210\211\212\213\214\215\216\217\220\221\222\223\224\225\226\227\230\231\232\233\234\235\236\237\240\241\242\243\244\245\246\247\250\251\252\253\254\255\256\257\260\261\262\263\264\265\266\267\270\271\272\273\274\275\276\277\300\301\302\303\304\305\306\307\310\311\312\313\314\315\316\317\320\321\322\323\324\325\326\327\330\331\332\333\334\335\336\337\340\341\342\343\344\345\346\347\350\351\352\353\354\355\356\357\360\361\362\363\364\365\366\367\370\371\372\373\374\375\376\377 3198 0: \x00\x01\x02\x03\x04\x05\x06\x07\x08\x09\x0a\x0b\x0c\x0d\x0e\x0f\x10\x11\x12\x13\x14\x15\x16\x17\x18\x19\x1a\x1b\x1c\x1d\x1e\x1f !"#$%&'()*+,-./0123456789:;<=>?@ABCDEFGHIJKLMNOPQRSTUVWXYZ[\]^_`abcdefghijklmnopqrstuvwxyz{|}~\x7f\x80\x81\x82\x83\x84\x85\x86\x87\x88\x89\x8a\x8b\x8c\x8d\x8e\x8f\x90\x91\x92\x93\x94\x95\x96\x97\x98\x99\x9a\x9b\x9c\x9d\x9e\x9f\xa0\xa1\xa2\xa3\xa4\xa5\xa6\xa7\xa8\xa9\xaa\xab\xac\xad\xae\xaf\xb0\xb1\xb2\xb3\xb4\xb5\xb6\xb7\xb8\xb9\xba\xbb\xbc\xbd\xbe\xbf\xc0\xc1\xc2\xc3\xc4\xc5\xc6\xc7\xc8\xc9\xca\xcb\xcc\xcd\xce\xcf\xd0\xd1\xd2\xd3\xd4\xd5\xd6\xd7\xd8\xd9\xda\xdb\xdc\xdd\xde\xdf\xe0\xe1\xe2\xe3\xe4\xe5\xe6\xe7\xe8\xe9\xea\xeb\xec\xed\xee\xef\xf0\xf1\xf2\xf3\xf4\xf5\xf6\xf7\xf8\xf9\xfa\xfb\xfc\xfd\xfe\xff 3199 3200 /P[^*]TAIRE[^*]{1,6}?LL/ 3201 xxxxxxxxxxxPSTAIREISLLxxxxxxxxx 3202 0: PSTAIREISLL 3203 3204 /P[^*]TAIRE[^*]{1,}?LL/ 3205 xxxxxxxxxxxPSTAIREISLLxxxxxxxxx 3206 0: PSTAIREISLL 3207 3208 /(\.\d\d[1-9]?)\d+/ 3209 1.230003938 3210 0: .230003938 3211 1: .23000393 3212 2: .2300039 3213 3: .230003 3214 4: .23000 3215 5: .2300 3216 6: .230 3217 1.875000282 3218 0: .875000282 3219 1: .87500028 3220 2: .8750002 3221 3: .875000 3222 4: .87500 3223 5: .8750 3224 6: .875 3225 1.235 3226 0: .235 3227 3228 /(\.\d\d((?=0)|\d(?=\d)))/ 3229 1.230003938 3230 0: .230 3231 1: .23 3232 1.875000282 3233 0: .875 3234 *** Failers 3235 No match 3236 1.235 3237 No match 3238 3239 /a(?)b/ 3240 ab 3241 0: ab 3242 3243 /\b(foo)\s+(\w+)/i 3244 Food is on the foo table 3245 0: foo table 3246 1: foo tabl 3247 2: foo tab 3248 3: foo ta 3249 4: foo t 3250 3251 /foo(.*)bar/ 3252 The food is under the bar in the barn. 3253 0: food is under the bar in the bar 3254 1: food is under the bar 3255 3256 /foo(.*?)bar/ 3257 The food is under the bar in the barn. 3258 0: food is under the bar in the bar 3259 1: food is under the bar 3260 3261 /(.*)(\d*)/ 3262 I have 2 numbers: 53147 3263 Matched, but too many subsidiary matches 3264 0: I have 2 numbers: 53147 3265 1: I have 2 numbers: 5314 3266 2: I have 2 numbers: 531 3267 3: I have 2 numbers: 53 3268 4: I have 2 numbers: 5 3269 5: I have 2 numbers: 3270 6: I have 2 numbers: 3271 7: I have 2 numbers 3272 8: I have 2 number 3273 9: I have 2 numbe 3274 10: I have 2 numb 3275 11: I have 2 num 3276 12: I have 2 nu 3277 13: I have 2 n 3278 14: I have 2 3279 15: I have 2 3280 16: I have 3281 17: I have 3282 18: I hav 3283 19: I ha 3284 20: I h 3285 21: I 3286 3287 /(.*)(\d+)/ 3288 I have 2 numbers: 53147 3289 0: I have 2 numbers: 53147 3290 1: I have 2 numbers: 5314 3291 2: I have 2 numbers: 531 3292 3: I have 2 numbers: 53 3293 4: I have 2 numbers: 5 3294 5: I have 2 3295 3296 /(.*?)(\d*)/ 3297 I have 2 numbers: 53147 3298 Matched, but too many subsidiary matches 3299 0: I have 2 numbers: 53147 3300 1: I have 2 numbers: 5314 3301 2: I have 2 numbers: 531 3302 3: I have 2 numbers: 53 3303 4: I have 2 numbers: 5 3304 5: I have 2 numbers: 3305 6: I have 2 numbers: 3306 7: I have 2 numbers 3307 8: I have 2 number 3308 9: I have 2 numbe 3309 10: I have 2 numb 3310 11: I have 2 num 3311 12: I have 2 nu 3312 13: I have 2 n 3313 14: I have 2 3314 15: I have 2 3315 16: I have 3316 17: I have 3317 18: I hav 3318 19: I ha 3319 20: I h 3320 21: I 3321 3322 /(.*?)(\d+)/ 3323 I have 2 numbers: 53147 3324 0: I have 2 numbers: 53147 3325 1: I have 2 numbers: 5314 3326 2: I have 2 numbers: 531 3327 3: I have 2 numbers: 53 3328 4: I have 2 numbers: 5 3329 5: I have 2 3330 3331 /(.*)(\d+)$/ 3332 I have 2 numbers: 53147 3333 0: I have 2 numbers: 53147 3334 3335 /(.*?)(\d+)$/ 3336 I have 2 numbers: 53147 3337 0: I have 2 numbers: 53147 3338 3339 /(.*)\b(\d+)$/ 3340 I have 2 numbers: 53147 3341 0: I have 2 numbers: 53147 3342 3343 /(.*\D)(\d+)$/ 3344 I have 2 numbers: 53147 3345 0: I have 2 numbers: 53147 3346 3347 /^\D*(?!123)/ 3348 ABC123 3349 0: AB 3350 1: A 3351 2: 3352 3353 /^(\D*)(?=\d)(?!123)/ 3354 ABC445 3355 0: ABC 3356 *** Failers 3357 No match 3358 ABC123 3359 No match 3360 3361 /^[W-]46]/ 3362 W46]789 3363 0: W46] 3364 -46]789 3365 0: -46] 3366 *** Failers 3367 No match 3368 Wall 3369 No match 3370 Zebra 3371 No match 3372 42 3373 No match 3374 [abcd] 3375 No match 3376 ]abcd[ 3377 No match 3378 3379 /^[W-\]46]/ 3380 W46]789 3381 0: W 3382 Wall 3383 0: W 3384 Zebra 3385 0: Z 3386 Xylophone 3387 0: X 3388 42 3389 0: 4 3390 [abcd] 3391 0: [ 3392 ]abcd[ 3393 0: ] 3394 \\backslash 3395 0: \ 3396 *** Failers 3397 No match 3398 -46]789 3399 No match 3400 well 3401 No match 3402 3403 /\d\d\/\d\d\/\d\d\d\d/ 3404 01/01/2000 3405 0: 01/01/2000 3406 3407 /word (?:[a-zA-Z0-9]+ ){0,10}otherword/ 3408 word cat dog elephant mussel cow horse canary baboon snake shark otherword 3409 0: word cat dog elephant mussel cow horse canary baboon snake shark otherword 3410 word cat dog elephant mussel cow horse canary baboon snake shark 3411 No match 3412 3413 /word (?:[a-zA-Z0-9]+ ){0,300}otherword/ 3414 word cat dog elephant mussel cow horse canary baboon snake shark the quick brown fox and the lazy dog and several other words getting close to thirty by now I hope 3415 No match 3416 3417 /^(a){0,0}/ 3418 bcd 3419 0: 3420 abc 3421 0: 3422 aab 3423 0: 3424 3425 /^(a){0,1}/ 3426 bcd 3427 0: 3428 abc 3429 0: a 3430 1: 3431 aab 3432 0: a 3433 1: 3434 3435 /^(a){0,2}/ 3436 bcd 3437 0: 3438 abc 3439 0: a 3440 1: 3441 aab 3442 0: aa 3443 1: a 3444 2: 3445 3446 /^(a){0,3}/ 3447 bcd 3448 0: 3449 abc 3450 0: a 3451 1: 3452 aab 3453 0: aa 3454 1: a 3455 2: 3456 aaa 3457 0: aaa 3458 1: aa 3459 2: a 3460 3: 3461 3462 /^(a){0,}/ 3463 bcd 3464 0: 3465 abc 3466 0: a 3467 1: 3468 aab 3469 0: aa 3470 1: a 3471 2: 3472 aaa 3473 0: aaa 3474 1: aa 3475 2: a 3476 3: 3477 aaaaaaaa 3478 0: aaaaaaaa 3479 1: aaaaaaa 3480 2: aaaaaa 3481 3: aaaaa 3482 4: aaaa 3483 5: aaa 3484 6: aa 3485 7: a 3486 8: 3487 3488 /^(a){1,1}/ 3489 bcd 3490 No match 3491 abc 3492 0: a 3493 aab 3494 0: a 3495 3496 /^(a){1,2}/ 3497 bcd 3498 No match 3499 abc 3500 0: a 3501 aab 3502 0: aa 3503 1: a 3504 3505 /^(a){1,3}/ 3506 bcd 3507 No match 3508 abc 3509 0: a 3510 aab 3511 0: aa 3512 1: a 3513 aaa 3514 0: aaa 3515 1: aa 3516 2: a 3517 3518 /^(a){1,}/ 3519 bcd 3520 No match 3521 abc 3522 0: a 3523 aab 3524 0: aa 3525 1: a 3526 aaa 3527 0: aaa 3528 1: aa 3529 2: a 3530 aaaaaaaa 3531 0: aaaaaaaa 3532 1: aaaaaaa 3533 2: aaaaaa 3534 3: aaaaa 3535 4: aaaa 3536 5: aaa 3537 6: aa 3538 7: a 3539 3540 /.*\.gif/ 3541 borfle\nbib.gif\nno 3542 0: bib.gif 3543 3544 /.{0,}\.gif/ 3545 borfle\nbib.gif\nno 3546 0: bib.gif 3547 3548 /.*\.gif/m 3549 borfle\nbib.gif\nno 3550 0: bib.gif 3551 3552 /.*\.gif/s 3553 borfle\nbib.gif\nno 3554 0: borfle\x0abib.gif 3555 3556 /.*\.gif/ms 3557 borfle\nbib.gif\nno 3558 0: borfle\x0abib.gif 3559 3560 /.*$/ 3561 borfle\nbib.gif\nno 3562 0: no 3563 3564 /.*$/m 3565 borfle\nbib.gif\nno 3566 0: borfle 3567 3568 /.*$/s 3569 borfle\nbib.gif\nno 3570 0: borfle\x0abib.gif\x0ano 3571 3572 /.*$/ms 3573 borfle\nbib.gif\nno 3574 0: borfle\x0abib.gif\x0ano 3575 1: borfle\x0abib.gif 3576 2: borfle 3577 3578 /.*$/ 3579 borfle\nbib.gif\nno\n 3580 0: no 3581 3582 /.*$/m 3583 borfle\nbib.gif\nno\n 3584 0: borfle 3585 3586 /.*$/s 3587 borfle\nbib.gif\nno\n 3588 0: borfle\x0abib.gif\x0ano\x0a 3589 1: borfle\x0abib.gif\x0ano 3590 3591 /.*$/ms 3592 borfle\nbib.gif\nno\n 3593 0: borfle\x0abib.gif\x0ano\x0a 3594 1: borfle\x0abib.gif\x0ano 3595 2: borfle\x0abib.gif 3596 3: borfle 3597 3598 /(.*X|^B)/ 3599 abcde\n1234Xyz 3600 0: 1234X 3601 BarFoo 3602 0: B 3603 *** Failers 3604 No match 3605 abcde\nBar 3606 No match 3607 3608 /(.*X|^B)/m 3609 abcde\n1234Xyz 3610 0: 1234X 3611 BarFoo 3612 0: B 3613 abcde\nBar 3614 0: B 3615 3616 /(.*X|^B)/s 3617 abcde\n1234Xyz 3618 0: abcde\x0a1234X 3619 BarFoo 3620 0: B 3621 *** Failers 3622 No match 3623 abcde\nBar 3624 No match 3625 3626 /(.*X|^B)/ms 3627 abcde\n1234Xyz 3628 0: abcde\x0a1234X 3629 BarFoo 3630 0: B 3631 abcde\nBar 3632 0: B 3633 3634 /(?s)(.*X|^B)/ 3635 abcde\n1234Xyz 3636 0: abcde\x0a1234X 3637 BarFoo 3638 0: B 3639 *** Failers 3640 No match 3641 abcde\nBar 3642 No match 3643 3644 /(?s:.*X|^B)/ 3645 abcde\n1234Xyz 3646 0: abcde\x0a1234X 3647 BarFoo 3648 0: B 3649 *** Failers 3650 No match 3651 abcde\nBar 3652 No match 3653 3654 /^.*B/ 3655 **** Failers 3656 No match 3657 abc\nB 3658 No match 3659 3660 /(?s)^.*B/ 3661 abc\nB 3662 0: abc\x0aB 3663 3664 /(?m)^.*B/ 3665 abc\nB 3666 0: B 3667 3668 /(?ms)^.*B/ 3669 abc\nB 3670 0: abc\x0aB 3671 3672 /(?ms)^B/ 3673 abc\nB 3674 0: B 3675 3676 /(?s)B$/ 3677 B\n 3678 0: B 3679 3680 /^[0-9][0-9][0-9][0-9][0-9][0-9][0-9][0-9][0-9][0-9][0-9][0-9]/ 3681 123456654321 3682 0: 123456654321 3683 3684 /^\d\d\d\d\d\d\d\d\d\d\d\d/ 3685 123456654321 3686 0: 123456654321 3687 3688 /^[\d][\d][\d][\d][\d][\d][\d][\d][\d][\d][\d][\d]/ 3689 123456654321 3690 0: 123456654321 3691 3692 /^[abc]{12}/ 3693 abcabcabcabc 3694 0: abcabcabcabc 3695 3696 /^[a-c]{12}/ 3697 abcabcabcabc 3698 0: abcabcabcabc 3699 3700 /^(a|b|c){12}/ 3701 abcabcabcabc 3702 0: abcabcabcabc 3703 3704 /^[abcdefghijklmnopqrstuvwxy0123456789]/ 3705 n 3706 0: n 3707 *** Failers 3708 No match 3709 z 3710 No match 3711 3712 /abcde{0,0}/ 3713 abcd 3714 0: abcd 3715 *** Failers 3716 No match 3717 abce 3718 No match 3719 3720 /ab[cd]{0,0}e/ 3721 abe 3722 0: abe 3723 *** Failers 3724 No match 3725 abcde 3726 No match 3727 3728 /ab(c){0,0}d/ 3729 abd 3730 0: abd 3731 *** Failers 3732 No match 3733 abcd 3734 No match 3735 3736 /a(b*)/ 3737 a 3738 0: a 3739 ab 3740 0: ab 3741 1: a 3742 abbbb 3743 0: abbbb 3744 1: abbb 3745 2: abb 3746 3: ab 3747 4: a 3748 *** Failers 3749 0: a 3750 bbbbb 3751 No match 3752 3753 /ab\d{0}e/ 3754 abe 3755 0: abe 3756 *** Failers 3757 No match 3758 ab1e 3759 No match 3760 3761 /"([^\\"]+|\\.)*"/ 3762 the \"quick\" brown fox 3763 0: "quick" 3764 \"the \\\"quick\\\" brown fox\" 3765 0: "the \"quick\" brown fox" 3766 3767 /.*?/g+ 3768 abc 3769 0: abc 3770 0+ 3771 1: ab 3772 2: a 3773 3: 3774 0: 3775 0+ 3776 3777 /\b/g+ 3778 abc 3779 0: 3780 0+ abc 3781 0: 3782 0+ 3783 3784 /\b/+g 3785 abc 3786 0: 3787 0+ abc 3788 0: 3789 0+ 3790 3791 //g 3792 abc 3793 0: 3794 0: 3795 0: 3796 0: 3797 3798 /<tr([\w\W\s\d][^<>]{0,})><TD([\w\W\s\d][^<>]{0,})>([\d]{0,}\.)(.*)((<BR>([\w\W\s\d][^<>]{0,})|[\s]{0,}))<\/a><\/TD><TD([\w\W\s\d][^<>]{0,})>([\w\W\s\d][^<>]{0,})<\/TD><TD([\w\W\s\d][^<>]{0,})>([\w\W\s\d][^<>]{0,})<\/TD><\/TR>/is 3799 <TR BGCOLOR='#DBE9E9'><TD align=left valign=top>43.<a href='joblist.cfm?JobID=94 6735&Keyword='>Word Processor<BR>(N-1286)</a></TD><TD align=left valign=top>Lega lstaff.com</TD><TD align=left valign=top>CA - Statewide</TD></TR> 3800 0: <TR BGCOLOR='#DBE9E9'><TD align=left valign=top>43.<a href='joblist.cfm?JobID=94 6735&Keyword='>Word Processor<BR>(N-1286)</a></TD><TD align=left valign=top>Lega lstaff.com</TD><TD align=left valign=top>CA - Statewide</TD></TR> 3801 3802 /a[^a]b/ 3803 acb 3804 0: acb 3805 a\nb 3806 0: a\x0ab 3807 3808 /a.b/ 3809 acb 3810 0: acb 3811 *** Failers 3812 No match 3813 a\nb 3814 No match 3815 3816 /a[^a]b/s 3817 acb 3818 0: acb 3819 a\nb 3820 0: a\x0ab 3821 3822 /a.b/s 3823 acb 3824 0: acb 3825 a\nb 3826 0: a\x0ab 3827 3828 /^(b+?|a){1,2}?c/ 3829 bac 3830 0: bac 3831 bbac 3832 0: bbac 3833 bbbac 3834 0: bbbac 3835 bbbbac 3836 0: bbbbac 3837 bbbbbac 3838 0: bbbbbac 3839 3840 /^(b+|a){1,2}?c/ 3841 bac 3842 0: bac 3843 bbac 3844 0: bbac 3845 bbbac 3846 0: bbbac 3847 bbbbac 3848 0: bbbbac 3849 bbbbbac 3850 0: bbbbbac 3851 3852 /(?!\A)x/m 3853 x\nb\n 3854 No match 3855 a\bx\n 3856 0: x 3857 3858 /\x0{ab}/ 3859 \0{ab} 3860 0: \x00{ab} 3861 3862 /(A|B)*?CD/ 3863 CD 3864 0: CD 3865 3866 /(A|B)*CD/ 3867 CD 3868 0: CD 3869 3870 /(?<!bar)foo/ 3871 foo 3872 0: foo 3873 catfood 3874 0: foo 3875 arfootle 3876 0: foo 3877 rfoosh 3878 0: foo 3879 *** Failers 3880 No match 3881 barfoo 3882 No match 3883 towbarfoo 3884 No match 3885 3886 /\w{3}(?<!bar)foo/ 3887 catfood 3888 0: catfoo 3889 *** Failers 3890 No match 3891 foo 3892 No match 3893 barfoo 3894 No match 3895 towbarfoo 3896 No match 3897 3898 /(?<=(foo)a)bar/ 3899 fooabar 3900 0: bar 3901 *** Failers 3902 No match 3903 bar 3904 No match 3905 foobbar 3906 No match 3907 3908 /\Aabc\z/m 3909 abc 3910 0: abc 3911 *** Failers 3912 No match 3913 abc\n 3914 No match 3915 qqq\nabc 3916 No match 3917 abc\nzzz 3918 No match 3919 qqq\nabc\nzzz 3920 No match 3921 3922 "(?>.*/)foo" 3923 /this/is/a/very/long/line/in/deed/with/very/many/slashes/in/it/you/see/ 3924 No match 3925 3926 "(?>.*/)foo" 3927 /this/is/a/very/long/line/in/deed/with/very/many/slashes/in/and/foo 3928 0: /this/is/a/very/long/line/in/deed/with/very/many/slashes/in/and/foo 3929 3930 /(?>(\.\d\d[1-9]?))\d+/ 3931 1.230003938 3932 0: .230003938 3933 1: .23000393 3934 2: .2300039 3935 3: .230003 3936 4: .23000 3937 5: .2300 3938 6: .230 3939 1.875000282 3940 0: .875000282 3941 1: .87500028 3942 2: .8750002 3943 3: .875000 3944 4: .87500 3945 5: .8750 3946 *** Failers 3947 No match 3948 1.235 3949 No match 3950 3951 /^((?>\w+)|(?>\s+))*$/ 3952 now is the time for all good men to come to the aid of the party 3953 0: now is the time for all good men to come to the aid of the party 3954 *** Failers 3955 No match 3956 this is not a line with only words and spaces! 3957 No match 3958 3959 /(\d+)(\w)/ 3960 12345a 3961 0: 12345a 3962 1: 12345 3963 2: 1234 3964 3: 123 3965 4: 12 3966 12345+ 3967 0: 12345 3968 1: 1234 3969 2: 123 3970 3: 12 3971 3972 /((?>\d+))(\w)/ 3973 12345a 3974 0: 12345a 3975 *** Failers 3976 No match 3977 12345+ 3978 No match 3979 3980 /(?>a+)b/ 3981 aaab 3982 0: aaab 3983 3984 /((?>a+)b)/ 3985 aaab 3986 0: aaab 3987 3988 /(?>(a+))b/ 3989 aaab 3990 0: aaab 3991 3992 /(?>b)+/ 3993 aaabbbccc 3994 0: bbb 3995 1: bb 3996 2: b 3997 3998 /(?>a+|b+|c+)*c/ 3999 aaabbbbccccd 4000 0: aaabbbbcccc 4001 1: aaabbbbc 4002 4003 /(a+|b+|c+)*c/ 4004 aaabbbbccccd 4005 0: aaabbbbcccc 4006 1: aaabbbbccc 4007 2: aaabbbbcc 4008 3: aaabbbbc 4009 4010 /((?>[^()]+)|\([^()]*\))+/ 4011 ((abc(ade)ufh()()x 4012 0: abc(ade)ufh()()x 4013 1: abc(ade)ufh()() 4014 2: abc(ade)ufh() 4015 3: abc(ade)ufh 4016 4: abc(ade) 4017 5: abc 4018 4019 /\(((?>[^()]+)|\([^()]+\))+\)/ 4020 (abc) 4021 0: (abc) 4022 (abc(def)xyz) 4023 0: (abc(def)xyz) 4024 *** Failers 4025 No match 4026 ((()aaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaa 4027 No match 4028 4029 /a(?-i)b/i 4030 ab 4031 0: ab 4032 Ab 4033 0: Ab 4034 *** Failers 4035 No match 4036 aB 4037 No match 4038 AB 4039 No match 4040 4041 /(a (?x)b c)d e/ 4042 a bcd e 4043 0: a bcd e 4044 *** Failers 4045 No match 4046 a b cd e 4047 No match 4048 abcd e 4049 No match 4050 a bcde 4051 No match 4052 4053 /(a b(?x)c d (?-x)e f)/ 4054 a bcde f 4055 0: a bcde f 4056 *** Failers 4057 No match 4058 abcdef 4059 No match 4060 4061 /(a(?i)b)c/ 4062 abc 4063 0: abc 4064 aBc 4065 0: aBc 4066 *** Failers 4067 No match 4068 abC 4069 No match 4070 aBC 4071 No match 4072 Abc 4073 No match 4074 ABc 4075 No match 4076 ABC 4077 No match 4078 AbC 4079 No match 4080 4081 /a(?i:b)c/ 4082 abc 4083 0: abc 4084 aBc 4085 0: aBc 4086 *** Failers 4087 No match 4088 ABC 4089 No match 4090 abC 4091 No match 4092 aBC 4093 No match 4094 4095 /a(?i:b)*c/ 4096 aBc 4097 0: aBc 4098 aBBc 4099 0: aBBc 4100 *** Failers 4101 No match 4102 aBC 4103 No match 4104 aBBC 4105 No match 4106 4107 /a(?=b(?i)c)\w\wd/ 4108 abcd 4109 0: abcd 4110 abCd 4111 0: abCd 4112 *** Failers 4113 No match 4114 aBCd 4115 No match 4116 abcD 4117 No match 4118 4119 /(?s-i:more.*than).*million/i 4120 more than million 4121 0: more than million 4122 more than MILLION 4123 0: more than MILLION 4124 more \n than Million 4125 0: more \x0a than Million 4126 *** Failers 4127 No match 4128 MORE THAN MILLION 4129 No match 4130 more \n than \n million 4131 No match 4132 4133 /(?:(?s-i)more.*than).*million/i 4134 more than million 4135 0: more than million 4136 more than MILLION 4137 0: more than MILLION 4138 more \n than Million 4139 0: more \x0a than Million 4140 *** Failers 4141 No match 4142 MORE THAN MILLION 4143 No match 4144 more \n than \n million 4145 No match 4146 4147 /(?>a(?i)b+)+c/ 4148 abc 4149 0: abc 4150 aBbc 4151 0: aBbc 4152 aBBc 4153 0: aBBc 4154 *** Failers 4155 No match 4156 Abc 4157 No match 4158 abAb 4159 No match 4160 abbC 4161 No match 4162 4163 /(?=a(?i)b)\w\wc/ 4164 abc 4165 0: abc 4166 aBc 4167 0: aBc 4168 *** Failers 4169 No match 4170 Ab 4171 No match 4172 abC 4173 No match 4174 aBC 4175 No match 4176 4177 /(?<=a(?i)b)(\w\w)c/ 4178 abxxc 4179 0: xxc 4180 aBxxc 4181 0: xxc 4182 *** Failers 4183 No match 4184 Abxxc 4185 No match 4186 ABxxc 4187 No match 4188 abxxC 4189 No match 4190 4191 /^(?(?=abc)\w{3}:|\d\d)$/ 4192 abc: 4193 0: abc: 4194 12 4195 0: 12 4196 *** Failers 4197 No match 4198 123 4199 No match 4200 xyz 4201 No match 4202 4203 /^(?(?!abc)\d\d|\w{3}:)$/ 4204 abc: 4205 0: abc: 4206 12 4207 0: 12 4208 *** Failers 4209 No match 4210 123 4211 No match 4212 xyz 4213 No match 4214 4215 /(?(?<=foo)bar|cat)/ 4216 foobar 4217 0: bar 4218 cat 4219 0: cat 4220 fcat 4221 0: cat 4222 focat 4223 0: cat 4224 *** Failers 4225 No match 4226 foocat 4227 No match 4228 4229 /(?(?<!foo)cat|bar)/ 4230 foobar 4231 0: bar 4232 cat 4233 0: cat 4234 fcat 4235 0: cat 4236 focat 4237 0: cat 4238 *** Failers 4239 No match 4240 foocat 4241 No match 4242 4243 /(?>a*)*/ 4244 a 4245 0: a 4246 1: 4247 aa 4248 0: aa 4249 1: 4250 aaaa 4251 0: aaaa 4252 1: 4253 4254 /(abc|)+/ 4255 abc 4256 0: abc 4257 1: 4258 abcabc 4259 0: abcabc 4260 1: abc 4261 2: 4262 abcabcabc 4263 0: abcabcabc 4264 1: abcabc 4265 2: abc 4266 3: 4267 xyz 4268 0: 4269 4270 /([a]*)*/ 4271 a 4272 0: a 4273 1: 4274 aaaaa 4275 0: aaaaa 4276 1: aaaa 4277 2: aaa 4278 3: aa 4279 4: a 4280 5: 4281 4282 /([ab]*)*/ 4283 a 4284 0: a 4285 1: 4286 b 4287 0: b 4288 1: 4289 ababab 4290 0: ababab 4291 1: ababa 4292 2: abab 4293 3: aba 4294 4: ab 4295 5: a 4296 6: 4297 aaaabcde 4298 0: aaaab 4299 1: aaaa 4300 2: aaa 4301 3: aa 4302 4: a 4303 5: 4304 bbbb 4305 0: bbbb 4306 1: bbb 4307 2: bb 4308 3: b 4309 4: 4310 4311 /([^a]*)*/ 4312 b 4313 0: b 4314 1: 4315 bbbb 4316 0: bbbb 4317 1: bbb 4318 2: bb 4319 3: b 4320 4: 4321 aaa 4322 0: 4323 4324 /([^ab]*)*/ 4325 cccc 4326 0: cccc 4327 1: ccc 4328 2: cc 4329 3: c 4330 4: 4331 abab 4332 0: 4333 4334 /([a]*?)*/ 4335 a 4336 0: a 4337 1: 4338 aaaa 4339 0: aaaa 4340 1: aaa 4341 2: aa 4342 3: a 4343 4: 4344 4345 /([ab]*?)*/ 4346 a 4347 0: a 4348 1: 4349 b 4350 0: b 4351 1: 4352 abab 4353 0: abab 4354 1: aba 4355 2: ab 4356 3: a 4357 4: 4358 baba 4359 0: baba 4360 1: bab 4361 2: ba 4362 3: b 4363 4: 4364 4365 /([^a]*?)*/ 4366 b 4367 0: b 4368 1: 4369 bbbb 4370 0: bbbb 4371 1: bbb 4372 2: bb 4373 3: b 4374 4: 4375 aaa 4376 0: 4377 4378 /([^ab]*?)*/ 4379 c 4380 0: c 4381 1: 4382 cccc 4383 0: cccc 4384 1: ccc 4385 2: cc 4386 3: c 4387 4: 4388 baba 4389 0: 4390 4391 /(?>a*)*/ 4392 a 4393 0: a 4394 1: 4395 aaabcde 4396 0: aaa 4397 1: 4398 4399 /((?>a*))*/ 4400 aaaaa 4401 0: aaaaa 4402 1: 4403 aabbaa 4404 0: aa 4405 1: 4406 4407 /((?>a*?))*/ 4408 aaaaa 4409 0: aaaaa 4410 1: 4411 aabbaa 4412 0: aa 4413 1: 4414 4415 /(?(?=[^a-z]+[a-z]) \d{2}-[a-z]{3}-\d{2} | \d{2}-\d{2}-\d{2} ) /x 4416 12-sep-98 4417 0: 12-sep-98 4418 12-09-98 4419 0: 12-09-98 4420 *** Failers 4421 No match 4422 sep-12-98 4423 No match 4424 4425 /(?i:saturday|sunday)/ 4426 saturday 4427 0: saturday 4428 sunday 4429 0: sunday 4430 Saturday 4431 0: Saturday 4432 Sunday 4433 0: Sunday 4434 SATURDAY 4435 0: SATURDAY 4436 SUNDAY 4437 0: SUNDAY 4438 SunDay 4439 0: SunDay 4440 4441 /(a(?i)bc|BB)x/ 4442 abcx 4443 0: abcx 4444 aBCx 4445 0: aBCx 4446 bbx 4447 0: bbx 4448 BBx 4449 0: BBx 4450 *** Failers 4451 No match 4452 abcX 4453 No match 4454 aBCX 4455 No match 4456 bbX 4457 No match 4458 BBX 4459 No match 4460 4461 /^([ab](?i)[cd]|[ef])/ 4462 ac 4463 0: ac 4464 aC 4465 0: aC 4466 bD 4467 0: bD 4468 elephant 4469 0: e 4470 Europe 4471 0: E 4472 frog 4473 0: f 4474 France 4475 0: F 4476 *** Failers 4477 No match 4478 Africa 4479 No match 4480 4481 /^(ab|a(?i)[b-c](?m-i)d|x(?i)y|z)/ 4482 ab 4483 0: ab 4484 aBd 4485 0: aBd 4486 xy 4487 0: xy 4488 xY 4489 0: xY 4490 zebra 4491 0: z 4492 Zambesi 4493 0: Z 4494 *** Failers 4495 No match 4496 aCD 4497 No match 4498 XY 4499 No match 4500 4501 /(?<=foo\n)^bar/m 4502 foo\nbar 4503 0: bar 4504 *** Failers 4505 No match 4506 bar 4507 No match 4508 baz\nbar 4509 No match 4510 4511 /(?<=(?<!foo)bar)baz/ 4512 barbaz 4513 0: baz 4514 barbarbaz 4515 0: baz 4516 koobarbaz 4517 0: baz 4518 *** Failers 4519 No match 4520 baz 4521 No match 4522 foobarbaz 4523 No match 4524 4525 /The following tests are taken from the Perl 5.005 test suite; some of them/ 4526 /are compatible with 5.004, but I'd rather not have to sort them out./ 4527 No match 4528 4529 /abc/ 4530 abc 4531 0: abc 4532 xabcy 4533 0: abc 4534 ababc 4535 0: abc 4536 *** Failers 4537 No match 4538 xbc 4539 No match 4540 axc 4541 No match 4542 abx 4543 No match 4544 4545 /ab*c/ 4546 abc 4547 0: abc 4548 4549 /ab*bc/ 4550 abc 4551 0: abc 4552 abbc 4553 0: abbc 4554 abbbbc 4555 0: abbbbc 4556 4557 /.{1}/ 4558 abbbbc 4559 0: a 4560 4561 /.{3,4}/ 4562 abbbbc 4563 0: abbb 4564 1: abb 4565 4566 /ab{0,}bc/ 4567 abbbbc 4568 0: abbbbc 4569 4570 /ab+bc/ 4571 abbc 4572 0: abbc 4573 *** Failers 4574 No match 4575 abc 4576 No match 4577 abq 4578 No match 4579 4580 /ab+bc/ 4581 abbbbc 4582 0: abbbbc 4583 4584 /ab{1,}bc/ 4585 abbbbc 4586 0: abbbbc 4587 4588 /ab{1,3}bc/ 4589 abbbbc 4590 0: abbbbc 4591 4592 /ab{3,4}bc/ 4593 abbbbc 4594 0: abbbbc 4595 4596 /ab{4,5}bc/ 4597 *** Failers 4598 No match 4599 abq 4600 No match 4601 abbbbc 4602 No match 4603 4604 /ab?bc/ 4605 abbc 4606 0: abbc 4607 abc 4608 0: abc 4609 4610 /ab{0,1}bc/ 4611 abc 4612 0: abc 4613 4614 /ab?bc/ 4615 4616 /ab?c/ 4617 abc 4618 0: abc 4619 4620 /ab{0,1}c/ 4621 abc 4622 0: abc 4623 4624 /^abc$/ 4625 abc 4626 0: abc 4627 *** Failers 4628 No match 4629 abbbbc 4630 No match 4631 abcc 4632 No match 4633 4634 /^abc/ 4635 abcc 4636 0: abc 4637 4638 /^abc$/ 4639 4640 /abc$/ 4641 aabc 4642 0: abc 4643 *** Failers 4644 No match 4645 aabc 4646 0: abc 4647 aabcd 4648 No match 4649 4650 /^/ 4651 abc 4652 0: 4653 4654 /$/ 4655 abc 4656 0: 4657 4658 /a.c/ 4659 abc 4660 0: abc 4661 axc 4662 0: axc 4663 4664 /a.*c/ 4665 axyzc 4666 0: axyzc 4667 4668 /a[bc]d/ 4669 abd 4670 0: abd 4671 *** Failers 4672 No match 4673 axyzd 4674 No match 4675 abc 4676 No match 4677 4678 /a[b-d]e/ 4679 ace 4680 0: ace 4681 4682 /a[b-d]/ 4683 aac 4684 0: ac 4685 4686 /a[-b]/ 4687 a- 4688 0: a- 4689 4690 /a[b-]/ 4691 a- 4692 0: a- 4693 4694 /a]/ 4695 a] 4696 0: a] 4697 4698 /a[]]b/ 4699 a]b 4700 0: a]b 4701 4702 /a[^bc]d/ 4703 aed 4704 0: aed 4705 *** Failers 4706 No match 4707 abd 4708 No match 4709 abd 4710 No match 4711 4712 /a[^-b]c/ 4713 adc 4714 0: adc 4715 4716 /a[^]b]c/ 4717 adc 4718 0: adc 4719 *** Failers 4720 No match 4721 a-c 4722 0: a-c 4723 a]c 4724 No match 4725 4726 /\ba\b/ 4727 a- 4728 0: a 4729 -a 4730 0: a 4731 -a- 4732 0: a 4733 4734 /\by\b/ 4735 *** Failers 4736 No match 4737 xy 4738 No match 4739 yz 4740 No match 4741 xyz 4742 No match 4743 4744 /\Ba\B/ 4745 *** Failers 4746 0: a 4747 a- 4748 No match 4749 -a 4750 No match 4751 -a- 4752 No match 4753 4754 /\By\b/ 4755 xy 4756 0: y 4757 4758 /\by\B/ 4759 yz 4760 0: y 4761 4762 /\By\B/ 4763 xyz 4764 0: y 4765 4766 /\w/ 4767 a 4768 0: a 4769 4770 /\W/ 4771 - 4772 0: - 4773 *** Failers 4774 0: * 4775 - 4776 0: - 4777 a 4778 No match 4779 4780 /a\sb/ 4781 a b 4782 0: a b 4783 4784 /a\Sb/ 4785 a-b 4786 0: a-b 4787 *** Failers 4788 No match 4789 a-b 4790 0: a-b 4791 a b 4792 No match 4793 4794 /\d/ 4795 1 4796 0: 1 4797 4798 /\D/ 4799 - 4800 0: - 4801 *** Failers 4802 0: * 4803 - 4804 0: - 4805 1 4806 No match 4807 4808 /[\w]/ 4809 a 4810 0: a 4811 4812 /[\W]/ 4813 - 4814 0: - 4815 *** Failers 4816 0: * 4817 - 4818 0: - 4819 a 4820 No match 4821 4822 /a[\s]b/ 4823 a b 4824 0: a b 4825 4826 /a[\S]b/ 4827 a-b 4828 0: a-b 4829 *** Failers 4830 No match 4831 a-b 4832 0: a-b 4833 a b 4834 No match 4835 4836 /[\d]/ 4837 1 4838 0: 1 4839 4840 /[\D]/ 4841 - 4842 0: - 4843 *** Failers 4844 0: * 4845 - 4846 0: - 4847 1 4848 No match 4849 4850 /ab|cd/ 4851 abc 4852 0: ab 4853 abcd 4854 0: ab 4855 4856 /()ef/ 4857 def 4858 0: ef 4859 4860 /$b/ 4861 4862 /a\(b/ 4863 a(b 4864 0: a(b 4865 4866 /a\(*b/ 4867 ab 4868 0: ab 4869 a((b 4870 0: a((b 4871 4872 /a\\b/ 4873 a\b 4874 No match 4875 4876 /((a))/ 4877 abc 4878 0: a 4879 4880 /(a)b(c)/ 4881 abc 4882 0: abc 4883 4884 /a+b+c/ 4885 aabbabc 4886 0: abc 4887 4888 /a{1,}b{1,}c/ 4889 aabbabc 4890 0: abc 4891 4892 /a.+?c/ 4893 abcabc 4894 0: abcabc 4895 1: abc 4896 4897 /(a+|b)*/ 4898 ab 4899 0: ab 4900 1: a 4901 2: 4902 4903 /(a+|b){0,}/ 4904 ab 4905 0: ab 4906 1: a 4907 2: 4908 4909 /(a+|b)+/ 4910 ab 4911 0: ab 4912 1: a 4913 4914 /(a+|b){1,}/ 4915 ab 4916 0: ab 4917 1: a 4918 4919 /(a+|b)?/ 4920 ab 4921 0: a 4922 1: 4923 4924 /(a+|b){0,1}/ 4925 ab 4926 0: a 4927 1: 4928 4929 /[^ab]*/ 4930 cde 4931 0: cde 4932 1: cd 4933 2: c 4934 3: 4935 4936 /abc/ 4937 *** Failers 4938 No match 4939 b 4940 No match 4941 4942 4943 /a*/ 4944 4945 4946 /([abc])*d/ 4947 abbbcd 4948 0: abbbcd 4949 4950 /([abc])*bcd/ 4951 abcd 4952 0: abcd 4953 4954 /a|b|c|d|e/ 4955 e 4956 0: e 4957 4958 /(a|b|c|d|e)f/ 4959 ef 4960 0: ef 4961 4962 /abcd*efg/ 4963 abcdefg 4964 0: abcdefg 4965 4966 /ab*/ 4967 xabyabbbz 4968 0: ab 4969 1: a 4970 xayabbbz 4971 0: a 4972 4973 /(ab|cd)e/ 4974 abcde 4975 0: cde 4976 4977 /[abhgefdc]ij/ 4978 hij 4979 0: hij 4980 4981 /^(ab|cd)e/ 4982 4983 /(abc|)ef/ 4984 abcdef 4985 0: ef 4986 4987 /(a|b)c*d/ 4988 abcd 4989 0: bcd 4990 4991 /(ab|ab*)bc/ 4992 abc 4993 0: abc 4994 4995 /a([bc]*)c*/ 4996 abc 4997 0: abc 4998 1: ab 4999 2: a 5000 5001 /a([bc]*)(c*d)/ 5002 abcd 5003 0: abcd 5004 5005 /a([bc]+)(c*d)/ 5006 abcd 5007 0: abcd 5008 5009 /a([bc]*)(c+d)/ 5010 abcd 5011 0: abcd 5012 5013 /a[bcd]*dcdcde/ 5014 adcdcde 5015 0: adcdcde 5016 5017 /a[bcd]+dcdcde/ 5018 *** Failers 5019 No match 5020 abcde 5021 No match 5022 adcdcde 5023 No match 5024 5025 /(ab|a)b*c/ 5026 abc 5027 0: abc 5028 5029 /((a)(b)c)(d)/ 5030 abcd 5031 0: abcd 5032 5033 /[a-zA-Z_][a-zA-Z0-9_]*/ 5034 alpha 5035 0: alpha 5036 1: alph 5037 2: alp 5038 3: al 5039 4: a 5040 5041 /^a(bc+|b[eh])g|.h$/ 5042 abh 5043 0: bh 5044 5045 /(bc+d$|ef*g.|h?i(j|k))/ 5046 effgz 5047 0: effgz 5048 ij 5049 0: ij 5050 reffgz 5051 0: effgz 5052 *** Failers 5053 No match 5054 effg 5055 No match 5056 bcdd 5057 No match 5058 5059 /((((((((((a))))))))))/ 5060 a 5061 0: a 5062 5063 /(((((((((a)))))))))/ 5064 a 5065 0: a 5066 5067 /multiple words of text/ 5068 *** Failers 5069 No match 5070 aa 5071 No match 5072 uh-uh 5073 No match 5074 5075 /multiple words/ 5076 multiple words, yeah 5077 0: multiple words 5078 5079 /(.*)c(.*)/ 5080 abcde 5081 0: abcde 5082 1: abcd 5083 2: abc 5084 5085 /\((.*), (.*)\)/ 5086 (a, b) 5087 0: (a, b) 5088 5089 /[k]/ 5090 5091 /abcd/ 5092 abcd 5093 0: abcd 5094 5095 /a(bc)d/ 5096 abcd 5097 0: abcd 5098 5099 /a[-]?c/ 5100 ac 5101 0: ac 5102 5103 /abc/i 5104 ABC 5105 0: ABC 5106 XABCY 5107 0: ABC 5108 ABABC 5109 0: ABC 5110 *** Failers 5111 No match 5112 aaxabxbaxbbx 5113 No match 5114 XBC 5115 No match 5116 AXC 5117 No match 5118 ABX 5119 No match 5120 5121 /ab*c/i 5122 ABC 5123 0: ABC 5124 5125 /ab*bc/i 5126 ABC 5127 0: ABC 5128 ABBC 5129 0: ABBC 5130 5131 /ab*?bc/i 5132 ABBBBC 5133 0: ABBBBC 5134 5135 /ab{0,}?bc/i 5136 ABBBBC 5137 0: ABBBBC 5138 5139 /ab+?bc/i 5140 ABBC 5141 0: ABBC 5142 5143 /ab+bc/i 5144 *** Failers 5145 No match 5146 ABC 5147 No match 5148 ABQ 5149 No match 5150 5151 /ab{1,}bc/i 5152 5153 /ab+bc/i 5154 ABBBBC 5155 0: ABBBBC 5156 5157 /ab{1,}?bc/i 5158 ABBBBC 5159 0: ABBBBC 5160 5161 /ab{1,3}?bc/i 5162 ABBBBC 5163 0: ABBBBC 5164 5165 /ab{3,4}?bc/i 5166 ABBBBC 5167 0: ABBBBC 5168 5169 /ab{4,5}?bc/i 5170 *** Failers 5171 No match 5172 ABQ 5173 No match 5174 ABBBBC 5175 No match 5176 5177 /ab??bc/i 5178 ABBC 5179 0: ABBC 5180 ABC 5181 0: ABC 5182 5183 /ab{0,1}?bc/i 5184 ABC 5185 0: ABC 5186 5187 /ab??bc/i 5188 5189 /ab??c/i 5190 ABC 5191 0: ABC 5192 5193 /ab{0,1}?c/i 5194 ABC 5195 0: ABC 5196 5197 /^abc$/i 5198 ABC 5199 0: ABC 5200 *** Failers 5201 No match 5202 ABBBBC 5203 No match 5204 ABCC 5205 No match 5206 5207 /^abc/i 5208 ABCC 5209 0: ABC 5210 5211 /^abc$/i 5212 5213 /abc$/i 5214 AABC 5215 0: ABC 5216 5217 /^/i 5218 ABC 5219 0: 5220 5221 /$/i 5222 ABC 5223 0: 5224 5225 /a.c/i 5226 ABC 5227 0: ABC 5228 AXC 5229 0: AXC 5230 5231 /a.*?c/i 5232 AXYZC 5233 0: AXYZC 5234 5235 /a.*c/i 5236 *** Failers 5237 No match 5238 AABC 5239 0: AABC 5240 AXYZD 5241 No match 5242 5243 /a[bc]d/i 5244 ABD 5245 0: ABD 5246 5247 /a[b-d]e/i 5248 ACE 5249 0: ACE 5250 *** Failers 5251 No match 5252 ABC 5253 No match 5254 ABD 5255 No match 5256 5257 /a[b-d]/i 5258 AAC 5259 0: AC 5260 5261 /a[-b]/i 5262 A- 5263 0: A- 5264 5265 /a[b-]/i 5266 A- 5267 0: A- 5268 5269 /a]/i 5270 A] 5271 0: A] 5272 5273 /a[]]b/i 5274 A]B 5275 0: A]B 5276 5277 /a[^bc]d/i 5278 AED 5279 0: AED 5280 5281 /a[^-b]c/i 5282 ADC 5283 0: ADC 5284 *** Failers 5285 No match 5286 ABD 5287 No match 5288 A-C 5289 No match 5290 5291 /a[^]b]c/i 5292 ADC 5293 0: ADC 5294 5295 /ab|cd/i 5296 ABC 5297 0: AB 5298 ABCD 5299 0: AB 5300 5301 /()ef/i 5302 DEF 5303 0: EF 5304 5305 /$b/i 5306 *** Failers 5307 No match 5308 A]C 5309 No match 5310 B 5311 No match 5312 5313 /a\(b/i 5314 A(B 5315 0: A(B 5316 5317 /a\(*b/i 5318 AB 5319 0: AB 5320 A((B 5321 0: A((B 5322 5323 /a\\b/i 5324 A\B 5325 No match 5326 5327 /((a))/i 5328 ABC 5329 0: A 5330 5331 /(a)b(c)/i 5332 ABC 5333 0: ABC 5334 5335 /a+b+c/i 5336 AABBABC 5337 0: ABC 5338 5339 /a{1,}b{1,}c/i 5340 AABBABC 5341 0: ABC 5342 5343 /a.+?c/i 5344 ABCABC 5345 0: ABCABC 5346 1: ABC 5347 5348 /a.*?c/i 5349 ABCABC 5350 0: ABCABC 5351 1: ABC 5352 5353 /a.{0,5}?c/i 5354 ABCABC 5355 0: ABCABC 5356 1: ABC 5357 5358 /(a+|b)*/i 5359 AB 5360 0: AB 5361 1: A 5362 2: 5363 5364 /(a+|b){0,}/i 5365 AB 5366 0: AB 5367 1: A 5368 2: 5369 5370 /(a+|b)+/i 5371 AB 5372 0: AB 5373 1: A 5374 5375 /(a+|b){1,}/i 5376 AB 5377 0: AB 5378 1: A 5379 5380 /(a+|b)?/i 5381 AB 5382 0: A 5383 1: 5384 5385 /(a+|b){0,1}/i 5386 AB 5387 0: A 5388 1: 5389 5390 /(a+|b){0,1}?/i 5391 AB 5392 0: A 5393 1: 5394 5395 /[^ab]*/i 5396 CDE 5397 0: CDE 5398 1: CD 5399 2: C 5400 3: 5401 5402 /abc/i 5403 5404 /a*/i 5405 5406 5407 /([abc])*d/i 5408 ABBBCD 5409 0: ABBBCD 5410 5411 /([abc])*bcd/i 5412 ABCD 5413 0: ABCD 5414 5415 /a|b|c|d|e/i 5416 E 5417 0: E 5418 5419 /(a|b|c|d|e)f/i 5420 EF 5421 0: EF 5422 5423 /abcd*efg/i 5424 ABCDEFG 5425 0: ABCDEFG 5426 5427 /ab*/i 5428 XABYABBBZ 5429 0: AB 5430 1: A 5431 XAYABBBZ 5432 0: A 5433 5434 /(ab|cd)e/i 5435 ABCDE 5436 0: CDE 5437 5438 /[abhgefdc]ij/i 5439 HIJ 5440 0: HIJ 5441 5442 /^(ab|cd)e/i 5443 ABCDE 5444 No match 5445 5446 /(abc|)ef/i 5447 ABCDEF 5448 0: EF 5449 5450 /(a|b)c*d/i 5451 ABCD 5452 0: BCD 5453 5454 /(ab|ab*)bc/i 5455 ABC 5456 0: ABC 5457 5458 /a([bc]*)c*/i 5459 ABC 5460 0: ABC 5461 1: AB 5462 2: A 5463 5464 /a([bc]*)(c*d)/i 5465 ABCD 5466 0: ABCD 5467 5468 /a([bc]+)(c*d)/i 5469 ABCD 5470 0: ABCD 5471 5472 /a([bc]*)(c+d)/i 5473 ABCD 5474 0: ABCD 5475 5476 /a[bcd]*dcdcde/i 5477 ADCDCDE 5478 0: ADCDCDE 5479 5480 /a[bcd]+dcdcde/i 5481 5482 /(ab|a)b*c/i 5483 ABC 5484 0: ABC 5485 5486 /((a)(b)c)(d)/i 5487 ABCD 5488 0: ABCD 5489 5490 /[a-zA-Z_][a-zA-Z0-9_]*/i 5491 ALPHA 5492 0: ALPHA 5493 1: ALPH 5494 2: ALP 5495 3: AL 5496 4: A 5497 5498 /^a(bc+|b[eh])g|.h$/i 5499 ABH 5500 0: BH 5501 5502 /(bc+d$|ef*g.|h?i(j|k))/i 5503 EFFGZ 5504 0: EFFGZ 5505 IJ 5506 0: IJ 5507 REFFGZ 5508 0: EFFGZ 5509 *** Failers 5510 No match 5511 ADCDCDE 5512 No match 5513 EFFG 5514 No match 5515 BCDD 5516 No match 5517 5518 /((((((((((a))))))))))/i 5519 A 5520 0: A 5521 5522 /(((((((((a)))))))))/i 5523 A 5524 0: A 5525 5526 /(?:(?:(?:(?:(?:(?:(?:(?:(?:(a))))))))))/i 5527 A 5528 0: A 5529 5530 /(?:(?:(?:(?:(?:(?:(?:(?:(?:(a|b|c))))))))))/i 5531 C 5532 0: C 5533 5534 /multiple words of text/i 5535 *** Failers 5536 No match 5537 AA 5538 No match 5539 UH-UH 5540 No match 5541 5542 /multiple words/i 5543 MULTIPLE WORDS, YEAH 5544 0: MULTIPLE WORDS 5545 5546 /(.*)c(.*)/i 5547 ABCDE 5548 0: ABCDE 5549 1: ABCD 5550 2: ABC 5551 5552 /\((.*), (.*)\)/i 5553 (A, B) 5554 0: (A, B) 5555 5556 /[k]/i 5557 5558 /abcd/i 5559 ABCD 5560 0: ABCD 5561 5562 /a(bc)d/i 5563 ABCD 5564 0: ABCD 5565 5566 /a[-]?c/i 5567 AC 5568 0: AC 5569 5570 /a(?!b)./ 5571 abad 5572 0: ad 5573 5574 /a(?=d)./ 5575 abad 5576 0: ad 5577 5578 /a(?=c|d)./ 5579 abad 5580 0: ad 5581 5582 /a(?:b|c|d)(.)/ 5583 ace 5584 0: ace 5585 5586 /a(?:b|c|d)*(.)/ 5587 ace 5588 0: ace 5589 1: ac 5590 5591 /a(?:b|c|d)+?(.)/ 5592 ace 5593 0: ace 5594 acdbcdbe 5595 0: acdbcdbe 5596 1: acdbcdb 5597 2: acdbcd 5598 3: acdbc 5599 4: acdb 5600 5: acd 5601 5602 /a(?:b|c|d)+(.)/ 5603 acdbcdbe 5604 0: acdbcdbe 5605 1: acdbcdb 5606 2: acdbcd 5607 3: acdbc 5608 4: acdb 5609 5: acd 5610 5611 /a(?:b|c|d){2}(.)/ 5612 acdbcdbe 5613 0: acdb 5614 5615 /a(?:b|c|d){4,5}(.)/ 5616 acdbcdbe 5617 0: acdbcdb 5618 1: acdbcd 5619 5620 /a(?:b|c|d){4,5}?(.)/ 5621 acdbcdbe 5622 0: acdbcdb 5623 1: acdbcd 5624 5625 /((foo)|(bar))*/ 5626 foobar 5627 0: foobar 5628 1: foo 5629 2: 5630 5631 /a(?:b|c|d){6,7}(.)/ 5632 acdbcdbe 5633 0: acdbcdbe 5634 5635 /a(?:b|c|d){6,7}?(.)/ 5636 acdbcdbe 5637 0: acdbcdbe 5638 5639 /a(?:b|c|d){5,6}(.)/ 5640 acdbcdbe 5641 0: acdbcdbe 5642 1: acdbcdb 5643 5644 /a(?:b|c|d){5,6}?(.)/ 5645 acdbcdbe 5646 0: acdbcdbe 5647 1: acdbcdb 5648 5649 /a(?:b|c|d){5,7}(.)/ 5650 acdbcdbe 5651 0: acdbcdbe 5652 1: acdbcdb 5653 5654 /a(?:b|c|d){5,7}?(.)/ 5655 acdbcdbe 5656 0: acdbcdbe 5657 1: acdbcdb 5658 5659 /a(?:b|(c|e){1,2}?|d)+?(.)/ 5660 ace 5661 0: ace 5662 5663 /^(.+)?B/ 5664 AB 5665 0: AB 5666 5667 /^([^a-z])|(\^)$/ 5668 . 5669 0: . 5670 5671 /^[<>]&/ 5672 <&OUT 5673 0: <& 5674 5675 /(?:(f)(o)(o)|(b)(a)(r))*/ 5676 foobar 5677 0: foobar 5678 1: foo 5679 2: 5680 5681 /(?<=a)b/ 5682 ab 5683 0: b 5684 *** Failers 5685 No match 5686 cb 5687 No match 5688 b 5689 No match 5690 5691 /(?<!c)b/ 5692 ab 5693 0: b 5694 b 5695 0: b 5696 b 5697 0: b 5698 5699 /(?:..)*a/ 5700 aba 5701 0: aba 5702 1: a 5703 5704 /(?:..)*?a/ 5705 aba 5706 0: aba 5707 1: a 5708 5709 /^(){3,5}/ 5710 abc 5711 0: 5712 5713 /^(a+)*ax/ 5714 aax 5715 0: aax 5716 5717 /^((a|b)+)*ax/ 5718 aax 5719 0: aax 5720 5721 /^((a|bc)+)*ax/ 5722 aax 5723 0: aax 5724 5725 /(a|x)*ab/ 5726 cab 5727 0: ab 5728 5729 /(a)*ab/ 5730 cab 5731 0: ab 5732 5733 /(?:(?i)a)b/ 5734 ab 5735 0: ab 5736 5737 /((?i)a)b/ 5738 ab 5739 0: ab 5740 5741 /(?:(?i)a)b/ 5742 Ab 5743 0: Ab 5744 5745 /((?i)a)b/ 5746 Ab 5747 0: Ab 5748 5749 /(?:(?i)a)b/ 5750 *** Failers 5751 No match 5752 cb 5753 No match 5754 aB 5755 No match 5756 5757 /((?i)a)b/ 5758 5759 /(?i:a)b/ 5760 ab 5761 0: ab 5762 5763 /((?i:a))b/ 5764 ab 5765 0: ab 5766 5767 /(?i:a)b/ 5768 Ab 5769 0: Ab 5770 5771 /((?i:a))b/ 5772 Ab 5773 0: Ab 5774 5775 /(?i:a)b/ 5776 *** Failers 5777 No match 5778 aB 5779 No match 5780 aB 5781 No match 5782 5783 /((?i:a))b/ 5784 5785 /(?:(?-i)a)b/i 5786 ab 5787 0: ab 5788 5789 /((?-i)a)b/i 5790 ab 5791 0: ab 5792 5793 /(?:(?-i)a)b/i 5794 aB 5795 0: aB 5796 5797 /((?-i)a)b/i 5798 aB 5799 0: aB 5800 5801 /(?:(?-i)a)b/i 5802 *** Failers 5803 No match 5804 aB 5805 0: aB 5806 Ab 5807 No match 5808 5809 /((?-i)a)b/i 5810 5811 /(?:(?-i)a)b/i 5812 aB 5813 0: aB 5814 5815 /((?-i)a)b/i 5816 aB 5817 0: aB 5818 5819 /(?:(?-i)a)b/i 5820 *** Failers 5821 No match 5822 Ab 5823 No match 5824 AB 5825 No match 5826 5827 /((?-i)a)b/i 5828 5829 /(?-i:a)b/i 5830 ab 5831 0: ab 5832 5833 /((?-i:a))b/i 5834 ab 5835 0: ab 5836 5837 /(?-i:a)b/i 5838 aB 5839 0: aB 5840 5841 /((?-i:a))b/i 5842 aB 5843 0: aB 5844 5845 /(?-i:a)b/i 5846 *** Failers 5847 No match 5848 AB 5849 No match 5850 Ab 5851 No match 5852 5853 /((?-i:a))b/i 5854 5855 /(?-i:a)b/i 5856 aB 5857 0: aB 5858 5859 /((?-i:a))b/i 5860 aB 5861 0: aB 5862 5863 /(?-i:a)b/i 5864 *** Failers 5865 No match 5866 Ab 5867 No match 5868 AB 5869 No match 5870 5871 /((?-i:a))b/i 5872 5873 /((?-i:a.))b/i 5874 *** Failers 5875 No match 5876 AB 5877 No match 5878 a\nB 5879 No match 5880 5881 /((?s-i:a.))b/i 5882 a\nB 5883 0: a\x0aB 5884 5885 /(?:c|d)(?:)(?:a(?:)(?:b)(?:b(?:))(?:b(?:)(?:b)))/ 5886 cabbbb 5887 0: cabbbb 5888 5889 /(?:c|d)(?:)(?:aaaaaaaa(?:)(?:bbbbbbbb)(?:bbbbbbbb(?:))(?:bbbbbbbb(?:)(?:bbbbbbbb)))/ 5890 caaaaaaaabbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbb 5891 0: caaaaaaaabbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbb 5892 5893 /foo\w*\d{4}baz/ 5894 foobar1234baz 5895 0: foobar1234baz 5896 5897 /x(~~)*(?:(?:F)?)?/ 5898 x~~ 5899 0: x~~ 5900 1: x 5901 5902 /^a(?#xxx){3}c/ 5903 aaac 5904 0: aaac 5905 5906 /^a (?#xxx) (?#yyy) {3}c/x 5907 aaac 5908 0: aaac 5909 5910 /(?<![cd])b/ 5911 *** Failers 5912 No match 5913 B\nB 5914 No match 5915 dbcb 5916 No match 5917 5918 /(?<![cd])[ab]/ 5919 dbaacb 5920 0: a 5921 5922 /(?<!(c|d))b/ 5923 5924 /(?<!(c|d))[ab]/ 5925 dbaacb 5926 0: a 5927 5928 /(?<!cd)[ab]/ 5929 cdaccb 5930 0: b 5931 5932 /^(?:a?b?)*$/ 5933 *** Failers 5934 No match 5935 dbcb 5936 No match 5937 a-- 5938 No match 5939 5940 /((?s)^a(.))((?m)^b$)/ 5941 a\nb\nc\n 5942 0: a\x0ab 5943 5944 /((?m)^b$)/ 5945 a\nb\nc\n 5946 0: b 5947 5948 /(?m)^b/ 5949 a\nb\n 5950 0: b 5951 5952 /(?m)^(b)/ 5953 a\nb\n 5954 0: b 5955 5956 /((?m)^b)/ 5957 a\nb\n 5958 0: b 5959 5960 /\n((?m)^b)/ 5961 a\nb\n 5962 0: \x0ab 5963 5964 /((?s).)c(?!.)/ 5965 a\nb\nc\n 5966 0: \x0ac 5967 a\nb\nc\n 5968 0: \x0ac 5969 5970 /((?s)b.)c(?!.)/ 5971 a\nb\nc\n 5972 0: b\x0ac 5973 a\nb\nc\n 5974 0: b\x0ac 5975 5976 /^b/ 5977 5978 /()^b/ 5979 *** Failers 5980 No match 5981 a\nb\nc\n 5982 No match 5983 a\nb\nc\n 5984 No match 5985 5986 /((?m)^b)/ 5987 a\nb\nc\n 5988 0: b 5989 5990 /(?(?!a)a|b)/ 5991 5992 /(?(?!a)b|a)/ 5993 a 5994 0: a 5995 5996 /(?(?=a)b|a)/ 5997 *** Failers 5998 No match 5999 a 6000 No match 6001 a 6002 No match 6003 6004 /(?(?=a)a|b)/ 6005 a 6006 0: a 6007 6008 /(\w+:)+/ 6009 one: 6010 0: one: 6011 6012 /$(?<=^(a))/ 6013 a 6014 0: 6015 6016 /([\w:]+::)?(\w+)$/ 6017 abcd 6018 0: abcd 6019 xy:z:::abcd 6020 0: xy:z:::abcd 6021 6022 /^[^bcd]*(c+)/ 6023 aexycd 6024 0: aexyc 6025 6026 /(a*)b+/ 6027 caab 6028 0: aab 6029 6030 /([\w:]+::)?(\w+)$/ 6031 abcd 6032 0: abcd 6033 xy:z:::abcd 6034 0: xy:z:::abcd 6035 *** Failers 6036 0: Failers 6037 abcd: 6038 No match 6039 abcd: 6040 No match 6041 6042 /^[^bcd]*(c+)/ 6043 aexycd 6044 0: aexyc 6045 6046 /(>a+)ab/ 6047 6048 /(?>a+)b/ 6049 aaab 6050 0: aaab 6051 6052 /([[:]+)/ 6053 a:[b]: 6054 0: :[ 6055 1: : 6056 6057 /([[=]+)/ 6058 a=[b]= 6059 0: =[ 6060 1: = 6061 6062 /([[.]+)/ 6063 a.[b]. 6064 0: .[ 6065 1: . 6066 6067 /((?>a+)b)/ 6068 aaab 6069 0: aaab 6070 6071 /(?>(a+))b/ 6072 aaab 6073 0: aaab 6074 6075 /((?>[^()]+)|\([^()]*\))+/ 6076 ((abc(ade)ufh()()x 6077 0: abc(ade)ufh()()x 6078 1: abc(ade)ufh()() 6079 2: abc(ade)ufh() 6080 3: abc(ade)ufh 6081 4: abc(ade) 6082 5: abc 6083 6084 /a\Z/ 6085 *** Failers 6086 No match 6087 aaab 6088 No match 6089 a\nb\n 6090 No match 6091 6092 /b\Z/ 6093 a\nb\n 6094 0: b 6095 6096 /b\z/ 6097 6098 /b\Z/ 6099 a\nb 6100 0: b 6101 6102 /b\z/ 6103 a\nb 6104 0: b 6105 *** Failers 6106 No match 6107 6108 /(?>.*)(?<=(abcd|wxyz))/ 6109 alphabetabcd 6110 0: alphabetabcd 6111 endingwxyz 6112 0: endingwxyz 6113 *** Failers 6114 No match 6115 a rather long string that doesn't end with one of them 6116 No match 6117 6118 /word (?>(?:(?!otherword)[a-zA-Z0-9]+ ){0,30})otherword/ 6119 word cat dog elephant mussel cow horse canary baboon snake shark otherword 6120 0: word cat dog elephant mussel cow horse canary baboon snake shark otherword 6121 word cat dog elephant mussel cow horse canary baboon snake shark 6122 No match 6123 6124 /word (?>[a-zA-Z0-9]+ ){0,30}otherword/ 6125 word cat dog elephant mussel cow horse canary baboon snake shark the quick brown fox and the lazy dog and several other words getting close to thirty by now I hope 6126 No match 6127 6128 /(?<=\d{3}(?!999))foo/ 6129 999foo 6130 0: foo 6131 123999foo 6132 0: foo 6133 *** Failers 6134 No match 6135 123abcfoo 6136 No match 6137 6138 /(?<=(?!...999)\d{3})foo/ 6139 999foo 6140 0: foo 6141 123999foo 6142 0: foo 6143 *** Failers 6144 No match 6145 123abcfoo 6146 No match 6147 6148 /(?<=\d{3}(?!999)...)foo/ 6149 123abcfoo 6150 0: foo 6151 123456foo 6152 0: foo 6153 *** Failers 6154 No match 6155 123999foo 6156 No match 6157 6158 /(?<=\d{3}...)(?<!999)foo/ 6159 123abcfoo 6160 0: foo 6161 123456foo 6162 0: foo 6163 *** Failers 6164 No match 6165 123999foo 6166 No match 6167 6168 /((Z)+|A)*/ 6169 ZABCDEFG 6170 0: ZA 6171 1: Z 6172 2: 6173 6174 /(Z()|A)*/ 6175 ZABCDEFG 6176 0: ZA 6177 1: Z 6178 2: 6179 6180 /(Z(())|A)*/ 6181 ZABCDEFG 6182 0: ZA 6183 1: Z 6184 2: 6185 6186 /((?>Z)+|A)*/ 6187 ZABCDEFG 6188 0: ZA 6189 1: Z 6190 2: 6191 6192 /((?>)+|A)*/ 6193 ZABCDEFG 6194 0: 6195 6196 /a*/g 6197 abbab 6198 0: a 6199 1: 6200 0: 6201 0: 6202 0: a 6203 1: 6204 0: 6205 0: 6206 6207 /^[a-\d]/ 6208 abcde 6209 0: a 6210 -things 6211 0: - 6212 0digit 6213 0: 0 6214 *** Failers 6215 No match 6216 bcdef 6217 No match 6218 6219 /^[\d-a]/ 6220 abcde 6221 0: a 6222 -things 6223 0: - 6224 0digit 6225 0: 0 6226 *** Failers 6227 No match 6228 bcdef 6229 No match 6230 6231 /[[:space:]]+/ 6232 > \x09\x0a\x0c\x0d\x0b< 6233 0: \x09\x0a\x0c\x0d\x0b 6234 1: \x09\x0a\x0c\x0d 6235 2: \x09\x0a\x0c 6236 3: \x09\x0a 6237 4: \x09 6238 5: 6239 6240 /[[:blank:]]+/ 6241 > \x09\x0a\x0c\x0d\x0b< 6242 0: \x09 6243 1: 6244 6245 /[\s]+/ 6246 > \x09\x0a\x0c\x0d\x0b< 6247 0: \x09\x0a\x0c\x0d 6248 1: \x09\x0a\x0c 6249 2: \x09\x0a 6250 3: \x09 6251 4: 6252 6253 /\s+/ 6254 > \x09\x0a\x0c\x0d\x0b< 6255 0: \x09\x0a\x0c\x0d 6256 1: \x09\x0a\x0c 6257 2: \x09\x0a 6258 3: \x09 6259 4: 6260 6261 /ab/x 6263 ab 6264 No match 6265 6266 /(?!\A)x/m 6267 a\nxb\n 6268 0: x 6269 6270 /(?!^)x/m 6271 a\nxb\n 6272 No match 6273 6274 /abc\Qabc\Eabc/ 6275 abcabcabc 6276 0: abcabcabc 6277 6278 /abc\Q(*+|\Eabc/ 6279 abc(*+|abc 6280 0: abc(*+|abc 6281 6282 / abc\Q abc\Eabc/x 6283 abc abcabc 6284 0: abc abcabc 6285 *** Failers 6286 No match 6287 abcabcabc 6288 No match 6289 6290 /abc#comment 6291 \Q#not comment 6292 literal\E/x 6293 abc#not comment\n literal 6294 0: abc#not comment\x0a literal 6295 6296 /abc#comment 6297 \Q#not comment 6298 literal/x 6299 abc#not comment\n literal 6300 0: abc#not comment\x0a literal 6301 6302 /abc#comment 6303 \Q#not comment 6304 literal\E #more comment 6305 /x 6306 abc#not comment\n literal 6307 0: abc#not comment\x0a literal 6308 6309 /abc#comment 6310 \Q#not comment 6311 literal\E #more comment/x 6312 abc#not comment\n literal 6313 0: abc#not comment\x0a literal 6314 6315 /\Qabc\$xyz\E/ 6316 abc\\\$xyz 6317 0: abc\$xyz 6318 6319 /\Qabc\E\$\Qxyz\E/ 6320 abc\$xyz 6321 0: abc$xyz 6322 6323 /\Gabc/ 6324 abc 6325 0: abc 6326 *** Failers 6327 No match 6328 xyzabc 6329 No match 6330 6331 /\Gabc./g 6332 abc1abc2xyzabc3 6333 0: abc1 6334 0: abc2 6335 6336 /abc./g 6337 abc1abc2xyzabc3 6338 0: abc1 6339 0: abc2 6340 0: abc3 6341 6342 /a(?x: b c )d/ 6343 XabcdY 6344 0: abcd 6345 *** Failers 6346 No match 6347 Xa b c d Y 6348 No match 6349 6350 /((?x)x y z | a b c)/ 6351 XabcY 6352 0: abc 6353 AxyzB 6354 0: xyz 6355 6356 /(?i)AB(?-i)C/ 6357 XabCY 6358 0: abC 6359 *** Failers 6360 No match 6361 XabcY 6362 No match 6363 6364 /((?i)AB(?-i)C|D)E/ 6365 abCE 6366 0: abCE 6367 DE 6368 0: DE 6369 *** Failers 6370 No match 6371 abcE 6372 No match 6373 abCe 6374 No match 6375 dE 6376 No match 6377 De 6378 No match 6379 6380 /[z\Qa-d]\E]/ 6381 z 6382 0: z 6383 a 6384 0: a 6385 - 6386 0: - 6387 d 6388 0: d 6389 ] 6390 0: ] 6391 *** Failers 6392 0: a 6393 b 6394 No match 6395 6396 /[\z\C]/ 6397 z 6398 0: z 6399 C 6400 0: C 6401 6402 /\M/ 6403 M 6404 0: M 6405 6406 /(a+)*b/ 6407 aaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaa 6408 No match 6409 6410 /(?i)reg(?:ul(?:[a]|ae)r|ex)/ 6411 REGular 6412 0: REGular 6413 regulaer 6414 0: regulaer 6415 Regex 6416 0: Regex 6417 regulr 6418 0: regul\xe4r 6419 6420 /[--]+/ 6421 6422 0: \xc5\xe6\xe5\xe4\xe0 6423 6424 0: \xc5\xe6\xe5\xe4\xff 6425 6426 0: \xc5\xe6\xe5\xe4\xc0 6427 6428 0: \xc5\xe6\xe5\xe4\xdf 6429 6430 /(?<=Z)X./ 6431 \x84XAZXB 6432 0: XB 6433 6434 /^(?(2)a|(1)(2))+$/ 6435 123a 6436 Error -17 6437 6438 /(?<=a|bbbb)c/ 6439 ac 6440 0: c 6441 bbbbc 6442 0: c 6443 6444 /abc/>testsavedregex 6445 Compiled regex written to testsavedregex 6446 <testsavedregex 6447 Compiled regex loaded from testsavedregex 6448 No study data 6449 abc 6450 0: abc 6451 *** Failers 6452 No match 6453 bca 6454 No match 6455 6456 /abc/F>testsavedregex 6457 Compiled regex written to testsavedregex 6458 <testsavedregex 6459 Compiled regex (byte-inverted) loaded from testsavedregex 6460 No study data 6461 abc 6462 0: abc 6463 *** Failers 6464 No match 6465 bca 6466 No match 6467 6468 /(a|b)/S>testsavedregex 6469 Compiled regex written to testsavedregex 6470 Study data written to testsavedregex 6471 <testsavedregex 6472 Compiled regex loaded from testsavedregex 6473 Study data loaded from testsavedregex 6474 abc 6475 0: a 6476 *** Failers 6477 0: a 6478 def 6479 No match 6480 6481 /(a|b)/SF>testsavedregex 6482 Compiled regex written to testsavedregex 6483 Study data written to testsavedregex 6484 <testsavedregex 6485 Compiled regex (byte-inverted) loaded from testsavedregex 6486 Study data loaded from testsavedregex 6487 abc 6488 0: a 6489 *** Failers 6490 0: a 6491 def 6492 No match 6493 6494 /line\nbreak/ 6495 this is a line\nbreak 6496 0: line\x0abreak 6497 line one\nthis is a line\nbreak in the second line 6498 0: line\x0abreak 6499 6500 /line\nbreak/f 6501 this is a line\nbreak 6502 0: line\x0abreak 6503 ** Failers 6504 No match 6505 line one\nthis is a line\nbreak in the second line 6506 No match 6507 6508 /line\nbreak/mf 6509 this is a line\nbreak 6510 0: line\x0abreak 6511 ** Failers 6512 No match 6513 line one\nthis is a line\nbreak in the second line 6514 No match 6515 6516 /1234/ 6517 123\P 6518 Partial match: 123 6519 a4\P\R 6520 No match 6521 6522 /1234/ 6523 123\P 6524 Partial match: 123 6525 4\P\R 6526 0: 4 6527 6528 /^/mg 6529 a\nb\nc\n 6530 0: 6531 0: 6532 0: 6533 \ 6534 0: 6535 6536 /(?<=C\n)^/mg 6537 A\nC\nC\n 6538 0: 6539 6540 /(?s)A?B/ 6541 AB 6542 0: AB 6543 aB 6544 0: B 6545 6546 /(?s)A*B/ 6547 AB 6548 0: AB 6549 aB 6550 0: B 6551 6552 /(?m)A?B/ 6553 AB 6554 0: AB 6555 aB 6556 0: B 6557 6558 /(?m)A*B/ 6559 AB 6560 0: AB 6561 aB 6562 0: B 6563 6564 /Content-Type\x3A[^\r\n]{6,}/ 6565 Content-Type:xxxxxyyy 6566 0: Content-Type:xxxxxyyy 6567 1: Content-Type:xxxxxyy 6568 2: Content-Type:xxxxxy 6569 6570 /Content-Type\x3A[^\r\n]{6,}z/ 6571 Content-Type:xxxxxyyyz 6572 0: Content-Type:xxxxxyyyz 6573 6574 /Content-Type\x3A[^a]{6,}/ 6575 Content-Type:xxxyyy 6576 0: Content-Type:xxxyyy 6577 6578 /Content-Type\x3A[^a]{6,}z/ 6579 Content-Type:xxxyyyz 6580 0: Content-Type:xxxyyyz 6581 6582 /^abc/m 6583 xyz\nabc 6584 0: abc 6585 xyz\nabc\<lf> 6586 0: abc 6587 xyz\r\nabc\<lf> 6588 0: abc 6589 xyz\rabc\<cr> 6590 0: abc 6591 xyz\r\nabc\<crlf> 6592 0: abc 6593 ** Failers 6594 No match 6595 xyz\nabc\<cr> 6596 No match 6597 xyz\r\nabc\<cr> 6598 No match 6599 xyz\nabc\<crlf> 6600 No match 6601 xyz\rabc\<crlf> 6602 No match 6603 xyz\rabc\<lf> 6604 No match 6605 6606 /abc$/m<lf> 6607 xyzabc 6608 0: abc 6609 xyzabc\n 6610 0: abc 6611 xyzabc\npqr 6612 0: abc 6613 xyzabc\r\<cr> 6614 0: abc 6615 xyzabc\rpqr\<cr> 6616 0: abc 6617 xyzabc\r\n\<crlf> 6618 0: abc 6619 xyzabc\r\npqr\<crlf> 6620 0: abc 6621 ** Failers 6622 No match 6623 xyzabc\r 6624 No match 6625 xyzabc\rpqr 6626 No match 6627 xyzabc\r\n 6628 No match 6629 xyzabc\r\npqr 6630 No match 6631 6632 /^abc/m<cr> 6633 xyz\rabcdef 6634 0: abc 6635 xyz\nabcdef\<lf> 6636 0: abc 6637 ** Failers 6638 No match 6639 xyz\nabcdef 6640 No match 6641 6642 /^abc/m<lf> 6643 xyz\nabcdef 6644 0: abc 6645 xyz\rabcdef\<cr> 6646 0: abc 6647 ** Failers 6648 No match 6649 xyz\rabcdef 6650 No match 6651 6652 /^abc/m<crlf> 6653 xyz\r\nabcdef 6654 0: abc 6655 xyz\rabcdef\<cr> 6656 0: abc 6657 ** Failers 6658 No match 6659 xyz\rabcdef 6660 No match 6661 6662 /.*/<lf> 6663 abc\ndef 6664 0: abc 6665 1: ab 6666 2: a 6667 3: 6668 abc\rdef 6669 0: abc\x0ddef 6670 1: abc\x0dde 6671 2: abc\x0dd 6672 3: abc\x0d 6673 4: abc 6674 5: ab 6675 6: a 6676 7: 6677 abc\r\ndef 6678 0: abc\x0d 6679 1: abc 6680 2: ab 6681 3: a 6682 4: 6683 \<cr>abc\ndef 6684 0: abc\x0adef 6685 1: abc\x0ade 6686 2: abc\x0ad 6687 3: abc\x0a 6688 4: abc 6689 5: ab 6690 6: a 6691 7: 6692 \<cr>abc\rdef 6693 0: abc 6694 1: ab 6695 2: a 6696 3: 6697 \<cr>abc\r\ndef 6698 0: abc 6699 1: ab 6700 2: a 6701 3: 6702 \<crlf>abc\ndef 6703 0: abc\x0adef 6704 1: abc\x0ade 6705 2: abc\x0ad 6706 3: abc\x0a 6707 4: abc 6708 5: ab 6709 6: a 6710 7: 6711 \<crlf>abc\rdef 6712 0: abc\x0ddef 6713 1: abc\x0dde 6714 2: abc\x0dd 6715 3: abc\x0d 6716 4: abc 6717 5: ab 6718 6: a 6719 7: 6720 \<crlf>abc\r\ndef 6721 0: abc 6722 1: ab 6723 2: a 6724 3: 6725 6726 /\w+(.)(.)?def/s 6727 abc\ndef 6728 0: abc\x0adef 6729 abc\rdef 6730 0: abc\x0ddef 6731 abc\r\ndef 6732 0: abc\x0d\x0adef 6733 6734 /^\w+=.*(\\\n.*)*/ 6735 abc=xyz\\\npqr 6736 0: abc=xyz\\x0apqr 6737 1: abc=xyz\\x0apq 6738 2: abc=xyz\\x0ap 6739 3: abc=xyz\\x0a 6740 4: abc=xyz\ 6741 5: abc=xyz 6742 6: abc=xy 6743 7: abc=x 6744 8: abc= 6745 6746 /^(a()*)*/ 6747 aaaa 6748 0: aaaa 6749 1: aaa 6750 2: aa 6751 3: a 6752 4: 6753 6754 /^(?:a(?:(?:))*)*/ 6755 aaaa 6756 0: aaaa 6757 1: aaa 6758 2: aa 6759 3: a 6760 4: 6761 6762 /^(a()+)+/ 6763 aaaa 6764 0: aaaa 6765 1: aaa 6766 2: aa 6767 3: a 6768 6769 /^(?:a(?:(?:))+)+/ 6770 aaaa 6771 0: aaaa 6772 1: aaa 6773 2: aa 6774 3: a 6775 6776 /(a|)*\d/ 6777 aaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaa 6778 No match 6779 aaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaa4 6780 0: aaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaa4 6781 6782 /(?>a|)*\d/ 6783 aaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaa 6784 No match 6785 aaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaa4 6786 0: aaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaa4 6787 6788 /(?:a|)*\d/ 6789 aaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaa 6790 No match 6791 aaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaa4 6792 0: aaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaa4 6793 6794 /^a.b/<lf> 6795 a\rb 6796 0: a\x0db 6797 a\nb\<cr> 6798 0: a\x0ab 6799 ** Failers 6800 No match 6801 a\nb 6802 No match 6803 a\nb\<any> 6804 No match 6805 a\rb\<cr> 6806 No match 6807 a\rb\<any> 6808 No match 6809 6810 /^abc./mgx<any> 6811 abc1 \x0aabc2 \x0babc3xx \x0cabc4 \x0dabc5xx \x0d\x0aabc6 \x85abc7 JUNK 6812 0: abc1 6813 0: abc2 6814 0: abc3 6815 0: abc4 6816 0: abc5 6817 0: abc6 6818 0: abc7 6819 6820 /abc.$/mgx<any> 6821 abc1\x0a abc2\x0b abc3\x0c abc4\x0d abc5\x0d\x0a abc6\x85 abc9 6822 0: abc1 6823 0: abc2 6824 0: abc3 6825 0: abc4 6826 0: abc5 6827 0: abc6 6828 0: abc9 6829 6830 /^a\Rb/<bsr_unicode> 6831 a\nb 6832 0: a\x0ab 6833 a\rb 6834 0: a\x0db 6835 a\r\nb 6836 0: a\x0d\x0ab 6837 a\x0bb 6838 0: a\x0bb 6839 a\x0cb 6840 0: a\x0cb 6841 a\x85b 6842 0: a\x85b 6843 ** Failers 6844 No match 6845 a\n\rb 6846 No match 6847 6848 /^a\R*b/<bsr_unicode> 6849 ab 6850 0: ab 6851 a\nb 6852 0: a\x0ab 6853 a\rb 6854 0: a\x0db 6855 a\r\nb 6856 0: a\x0d\x0ab 6857 a\x0bb 6858 0: a\x0bb 6859 a\x0cb 6860 0: a\x0cb 6861 a\x85b 6862 0: a\x85b 6863 a\n\rb 6864 0: a\x0a\x0db 6865 a\n\r\x85\x0cb 6866 0: a\x0a\x0d\x85\x0cb 6867 6868 /^a\R+b/<bsr_unicode> 6869 a\nb 6870 0: a\x0ab 6871 a\rb 6872 0: a\x0db 6873 a\r\nb 6874 0: a\x0d\x0ab 6875 a\x0bb 6876 0: a\x0bb 6877 a\x0cb 6878 0: a\x0cb 6879 a\x85b 6880 0: a\x85b 6881 a\n\rb 6882 0: a\x0a\x0db 6883 a\n\r\x85\x0cb 6884 0: a\x0a\x0d\x85\x0cb 6885 ** Failers 6886 No match 6887 ab 6888 No match 6889 6890 /^a\R{1,3}b/<bsr_unicode> 6891 a\nb 6892 0: a\x0ab 6893 a\n\rb 6894 0: a\x0a\x0db 6895 a\n\r\x85b 6896 0: a\x0a\x0d\x85b 6897 a\r\n\r\nb 6898 0: a\x0d\x0a\x0d\x0ab 6899 a\r\n\r\n\r\nb 6900 0: a\x0d\x0a\x0d\x0a\x0d\x0ab 6901 a\n\r\n\rb 6902 0: a\x0a\x0d\x0a\x0db 6903 a\n\n\r\nb 6904 0: a\x0a\x0a\x0d\x0ab 6905 ** Failers 6906 No match 6907 a\n\n\n\rb 6908 No match 6909 a\r 6910 No match 6911 6912 /^a[\R]b/<bsr_unicode> 6913 aRb 6914 0: aRb 6915 ** Failers 6916 No match 6917 a\nb 6918 No match 6919 6920 /.+foo/ 6921 afoo 6922 0: afoo 6923 ** Failers 6924 No match 6925 \r\nfoo 6926 No match 6927 \nfoo 6928 No match 6929 6930 /.+foo/<crlf> 6931 afoo 6932 0: afoo 6933 \nfoo 6934 0: \x0afoo 6935 ** Failers 6936 No match 6937 \r\nfoo 6938 No match 6939 6940 /.+foo/<any> 6941 afoo 6942 0: afoo 6943 ** Failers 6944 No match 6945 \nfoo 6946 No match 6947 \r\nfoo 6948 No match 6949 6950 /.+foo/s 6951 afoo 6952 0: afoo 6953 \r\nfoo 6954 0: \x0d\x0afoo 6955 \nfoo 6956 0: \x0afoo 6957 6958 /^$/mg<any> 6959 abc\r\rxyz 6960 0: 6961 abc\n\rxyz 6962 0: 6963 ** Failers 6964 No match 6965 abc\r\nxyz 6966 No match 6967 6968 /^X/m 6969 XABC 6970 0: X 6971 ** Failers 6972 No match 6973 XABC\B 6974 No match 6975 6976 /(?m)^$/<any>g+ 6977 abc\r\n\r\n 6978 0: 6979 0+ \x0d\x0a 6980 6981 /(?m)^$|^\r\n/<any>g+ 6982 abc\r\n\r\n 6983 0: \x0d\x0a 6984 0+ 6985 1: 6986 6987 /(?m)$/<any>g+ 6988 abc\r\n\r\n 6989 0: 6990 0+ \x0d\x0a\x0d\x0a 6991 0: 6992 0+ \x0d\x0a 6993 0: 6994 0+ 6995 6996 /(?|(abc)|(xyz))/ 6997 >abc< 6998 0: abc 6999 >xyz< 7000 0: xyz 7001 7002 /(x)(?|(abc)|(xyz))(x)/ 7003 xabcx 7004 0: xabcx 7005 xxyzx 7006 0: xxyzx 7007 7008 /(x)(?|(abc)(pqr)|(xyz))(x)/ 7009 xabcpqrx 7010 0: xabcpqrx 7011 xxyzx 7012 0: xxyzx 7013 7014 /(?|(abc)|(xyz))(?1)/ 7015 abcabc 7016 0: abcabc 7017 xyzabc 7018 0: xyzabc 7019 ** Failers 7020 No match 7021 xyzxyz 7022 No match 7023 7024 /\H\h\V\v/ 7025 X X\x0a 7026 0: X X\x0a 7027 X\x09X\x0b 7028 0: X\x09X\x0b 7029 ** Failers 7030 No match 7031 \xa0 X\x0a 7032 No match 7033 7034 /\H*\h+\V?\v{3,4}/ 7035 \x09\x20\xa0X\x0a\x0b\x0c\x0d\x0a 7036 0: \x09 \xa0X\x0a\x0b\x0c\x0d 7037 1: \x09 \xa0X\x0a\x0b\x0c 7038 \x09\x20\xa0\x0a\x0b\x0c\x0d\x0a 7039 0: \x09 \xa0\x0a\x0b\x0c\x0d 7040 1: \x09 \xa0\x0a\x0b\x0c 7041 \x09\x20\xa0\x0a\x0b\x0c 7042 0: \x09 \xa0\x0a\x0b\x0c 7043 ** Failers 7044 No match 7045 \x09\x20\xa0\x0a\x0b 7046 No match 7047 7048 /\H{3,4}/ 7049 XY ABCDE 7050 0: ABCD 7051 1: ABC 7052 XY PQR ST 7053 0: PQR 7054 7055 /.\h{3,4}./ 7056 XY AB PQRS 7057 0: B P 7058 1: B 7059 7060 /\h*X\h?\H+Y\H?Z/ 7061 >XNNNYZ 7062 0: XNNNYZ 7063 > X NYQZ 7064 0: X NYQZ 7065 ** Failers 7066 No match 7067 >XYZ 7068 No match 7069 > X NY Z 7070 No match 7071 7072 /\v*X\v?Y\v+Z\V*\x0a\V+\x0b\V{2,3}\x0c/ 7073 >XY\x0aZ\x0aA\x0bNN\x0c 7074 0: XY\x0aZ\x0aA\x0bNN\x0c 7075 >\x0a\x0dX\x0aY\x0a\x0bZZZ\x0aAAA\x0bNNN\x0c 7076 0: \x0a\x0dX\x0aY\x0a\x0bZZZ\x0aAAA\x0bNNN\x0c 7077 7078 /.+A/<crlf> 7079 \r\nA 7080 No match 7081 7082 /\nA/<crlf> 7083 \r\nA 7084 0: \x0aA 7085 7086 /[\r\n]A/<crlf> 7087 \r\nA 7088 0: \x0aA 7089 7090 /(\r|\n)A/<crlf> 7091 \r\nA 7092 0: \x0aA 7093 7094 /a\Rb/I<bsr_anycrlf> 7095 Capturing subpattern count = 0 7096 Options: bsr_anycrlf 7097 First char = 'a' 7098 Need char = 'b' 7099 a\rb 7100 0: a\x0db 7101 a\nb 7102 0: a\x0ab 7103 a\r\nb 7104 0: a\x0d\x0ab 7105 ** Failers 7106 No match 7107 a\x85b 7108 No match 7109 a\x0bb 7110 No match 7111 7112 /a\Rb/I<bsr_unicode> 7113 Capturing subpattern count = 0 7114 Options: bsr_unicode 7115 First char = 'a' 7116 Need char = 'b' 7117 a\rb 7118 0: a\x0db 7119 a\nb 7120 0: a\x0ab 7121 a\r\nb 7122 0: a\x0d\x0ab 7123 a\x85b 7124 0: a\x85b 7125 a\x0bb 7126 0: a\x0bb 7127 ** Failers 7128 No match 7129 a\x85b\<bsr_anycrlf> 7130 No match 7131 a\x0bb\<bsr_anycrlf> 7132 No match 7133 7134 /a\R?b/I<bsr_anycrlf> 7135 Capturing subpattern count = 0 7136 Options: bsr_anycrlf 7137 First char = 'a' 7138 Need char = 'b' 7139 a\rb 7140 0: a\x0db 7141 a\nb 7142 0: a\x0ab 7143 a\r\nb 7144 0: a\x0d\x0ab 7145 ** Failers 7146 No match 7147 a\x85b 7148 No match 7149 a\x0bb 7150 No match 7151 7152 /a\R?b/I<bsr_unicode> 7153 Capturing subpattern count = 0 7154 Options: bsr_unicode 7155 First char = 'a' 7156 Need char = 'b' 7157 a\rb 7158 0: a\x0db 7159 a\nb 7160 0: a\x0ab 7161 a\r\nb 7162 0: a\x0d\x0ab 7163 a\x85b 7164 0: a\x85b 7165 a\x0bb 7166 0: a\x0bb 7167 ** Failers 7168 No match 7169 a\x85b\<bsr_anycrlf> 7170 No match 7171 a\x0bb\<bsr_anycrlf> 7172 No match 7173 7174 /a\R{2,4}b/I<bsr_anycrlf> 7175 Capturing subpattern count = 0 7176 Options: bsr_anycrlf 7177 First char = 'a' 7178 Need char = 'b' 7179 a\r\n\nb 7180 0: a\x0d\x0a\x0ab 7181 a\n\r\rb 7182 0: a\x0a\x0d\x0db 7183 a\r\n\r\n\r\n\r\nb 7184 0: a\x0d\x0a\x0d\x0a\x0d\x0a\x0d\x0ab 7185 ** Failers 7186 No match 7187 a\x85\85b 7188 No match 7189 a\x0b\0bb 7190 No match 7191 7192 /a\R{2,4}b/I<bsr_unicode> 7193 Capturing subpattern count = 0 7194 Options: bsr_unicode 7195 First char = 'a' 7196 Need char = 'b' 7197 a\r\rb 7198 0: a\x0d\x0db 7199 a\n\n\nb 7200 0: a\x0a\x0a\x0ab 7201 a\r\n\n\r\rb 7202 0: a\x0d\x0a\x0a\x0d\x0db 7203 a\x85\85b 7204 No match 7205 a\x0b\0bb 7206 No match 7207 ** Failers 7208 No match 7209 a\r\r\r\r\rb 7210 No match 7211 a\x85\85b\<bsr_anycrlf> 7212 No match 7213 a\x0b\0bb\<bsr_anycrlf> 7214 No match 7215 7216 /a(?!)|\wbc/ 7217 abc 7218 0: abc 7219 7220 /a[]b/<JS> 7221 ** Failers 7222 No match 7223 ab 7224 No match 7225 7226 /a[]+b/<JS> 7227 ** Failers 7228 No match 7229 ab 7230 No match 7231 7232 /a[]*+b/<JS> 7233 ** Failers 7234 No match 7235 ab 7236 No match 7237 7238 /a[^]b/<JS> 7239 aXb 7240 0: aXb 7241 a\nb 7242 0: a\x0ab 7243 ** Failers 7244 No match 7245 ab 7246 No match 7247 7248 /a[^]+b/<JS> 7249 aXb 7250 0: aXb 7251 a\nX\nXb 7252 0: a\x0aX\x0aXb 7253 ** Failers 7254 No match 7255 ab 7256 No match 7257 7258 /X$/E 7259 X 7260 0: X 7261 ** Failers 7262 No match 7263 X\n 7264 No match 7265 7266 /X$/ 7267 X 7268 0: X 7269 X\n 7270 0: X 7271 7272 /xyz/C 7273 xyz 7274 --->xyz 7275 +0 ^ x 7276 +1 ^^ y 7277 +2 ^ ^ z 7278 +3 ^ ^ 7279 0: xyz 7280 abcxyz 7281 --->abcxyz 7282 +0 ^ x 7283 +1 ^^ y 7284 +2 ^ ^ z 7285 +3 ^ ^ 7286 0: xyz 7287 abcxyz\Y 7288 --->abcxyz 7289 +0 ^ x 7290 +0 ^ x 7291 +0 ^ x 7292 +0 ^ x 7293 +1 ^^ y 7294 +2 ^ ^ z 7295 +3 ^ ^ 7296 0: xyz 7297 ** Failers 7298 No match 7299 abc 7300 No match 7301 abc\Y 7302 --->abc 7303 +0 ^ x 7304 +0 ^ x 7305 +0 ^ x 7306 +0 ^ x 7307 No match 7308 abcxypqr 7309 No match 7310 abcxypqr\Y 7311 --->abcxypqr 7312 +0 ^ x 7313 +0 ^ x 7314 +0 ^ x 7315 +0 ^ x 7316 +1 ^^ y 7317 +2 ^ ^ z 7318 +0 ^ x 7319 +0 ^ x 7320 +0 ^ x 7321 +0 ^ x 7322 +0 ^ x 7323 No match 7324 7325 /(*NO_START_OPT)xyz/C 7326 abcxyz 7327 --->abcxyz 7328 +15 ^ x 7329 +15 ^ x 7330 +15 ^ x 7331 +15 ^ x 7332 +16 ^^ y 7333 +17 ^ ^ z 7334 +18 ^ ^ 7335 0: xyz 7336 7337 /(?C)ab/ 7338 ab 7339 --->ab 7340 0 ^ a 7341 0: ab 7342 \C-ab 7343 0: ab 7344 7345 /ab/C 7346 ab 7347 --->ab 7348 +0 ^ a 7349 +1 ^^ b 7350 +2 ^ ^ 7351 0: ab 7352 \C-ab 7353 0: ab 7354 7355 /^"((?(?=[a])[^"])|b)*"$/C 7356 "ab" 7357 --->"ab" 7358 +0 ^ ^ 7359 +1 ^ " 7360 +2 ^^ ((?(?=[a])[^"])|b)* 7361 +21 ^^ " 7362 +3 ^^ (?(?=[a])[^"]) 7363 +18 ^^ b 7364 +5 ^^ (?=[a]) 7365 +8 ^ [a] 7366 +11 ^^ ) 7367 +12 ^^ [^"] 7368 +16 ^ ^ ) 7369 +17 ^ ^ | 7370 +21 ^ ^ " 7371 +3 ^ ^ (?(?=[a])[^"]) 7372 +18 ^ ^ b 7373 +5 ^ ^ (?=[a]) 7374 +8 ^ [a] 7375 +19 ^ ^ ) 7376 +21 ^ ^ " 7377 +3 ^ ^ (?(?=[a])[^"]) 7378 +18 ^ ^ b 7379 +5 ^ ^ (?=[a]) 7380 +8 ^ [a] 7381 +17 ^ ^ | 7382 +22 ^ ^ $ 7383 +23 ^ ^ 7384 0: "ab" 7385 \C-"ab" 7386 0: "ab" 7387 7388 /\d+X|9+Y/ 7389 ++++123999\P 7390 Partial match: 123999 7391 ++++123999Y\P 7392 0: 999Y 7393 7394 /Z(*F)/ 7395 Z\P 7396 No match 7397 ZA\P 7398 No match 7399 7400 /Z(?!)/ 7401 Z\P 7402 No match 7403 ZA\P 7404 No match 7405 7406 /dog(sbody)?/ 7407 dogs\P 7408 0: dog 7409 dogs\P\P 7410 Partial match: dogs 7411 7412 /dog(sbody)??/ 7413 dogs\P 7414 0: dog 7415 dogs\P\P 7416 Partial match: dogs 7417 7418 /dog|dogsbody/ 7419 dogs\P 7420 0: dog 7421 dogs\P\P 7422 Partial match: dogs 7423 7424 /dogsbody|dog/ 7425 dogs\P 7426 0: dog 7427 dogs\P\P 7428 Partial match: dogs 7429 7430 /Z(*F)Q|ZXY/ 7431 Z\P 7432 Partial match: Z 7433 ZA\P 7434 No match 7435 X\P 7436 No match 7437 7438 /\bthe cat\b/ 7439 the cat\P 7440 0: the cat 7441 the cat\P\P 7442 Partial match: the cat 7443 7444 /dog(sbody)?/ 7445 dogs\D\P 7446 0: dog 7447 body\D\R 7448 0: body 7449 7450 /dog(sbody)?/ 7451 dogs\D\P\P 7452 Partial match: dogs 7453 body\D\R 7454 0: body 7455 7456 /abc/ 7457 abc\P 7458 0: abc 7459 abc\P\P 7460 0: abc 7461 7462 /abc\K123/ 7463 xyzabc123pqr 7464 Error -16 7465 7466 /(?<=abc)123/ 7467 xyzabc123pqr 7468 0: 123 7469 xyzabc12\P 7470 Partial match: abc12 7471 xyzabc12\P\P 7472 Partial match: abc12 7473 7474 /\babc\b/ 7475 +++abc+++ 7476 0: abc 7477 +++ab\P 7478 Partial match: +ab 7479 +++ab\P\P 7480 Partial match: +ab 7481 7482 /(?=C)/g+ 7483 ABCDECBA 7484 0: 7485 0+ CDECBA 7486 0: 7487 0+ CBA 7488 7489 /(abc|def|xyz)/I 7490 Capturing subpattern count = 1 7491 No options 7492 No first char 7493 No need char 7494 terhjk;abcdaadsfe 7495 0: abc 7496 the quick xyz brown fox 7497 0: xyz 7498 \Yterhjk;abcdaadsfe 7499 0: abc 7500 \Ythe quick xyz brown fox 7501 0: xyz 7502 ** Failers 7503 No match 7504 thejk;adlfj aenjl;fda asdfasd ehj;kjxyasiupd 7505 No match 7506 \Ythejk;adlfj aenjl;fda asdfasd ehj;kjxyasiupd 7507 No match 7508 7509 /(abc|def|xyz)/SI 7510 Capturing subpattern count = 1 7511 No options 7512 No first char 7513 No need char 7514 Subject length lower bound = 3 7515 Starting byte set: a d x 7516 terhjk;abcdaadsfe 7517 0: abc 7518 the quick xyz brown fox 7519 0: xyz 7520 \Yterhjk;abcdaadsfe 7521 0: abc 7522 \Ythe quick xyz brown fox 7523 0: xyz 7524 ** Failers 7525 No match 7526 thejk;adlfj aenjl;fda asdfasd ehj;kjxyasiupd 7527 No match 7528 \Ythejk;adlfj aenjl;fda asdfasd ehj;kjxyasiupd 7529 No match 7530 7531 /abcd*/+ 7532 xxxxabcd\P 7533 0: abcd 7534 0+ 7535 1: abc 7536 xxxxabcd\P\P 7537 Partial match: abcd 7538 dddxxx\R 7539 0: ddd 7540 0+ xxx 7541 1: dd 7542 2: d 7543 3: 7544 xxxxabcd\P\P 7545 Partial match: abcd 7546 xxx\R 7547 0: 7548 0+ xxx 7549 7550 /abcd*/i 7551 xxxxabcd\P 7552 0: abcd 7553 1: abc 7554 xxxxabcd\P\P 7555 Partial match: abcd 7556 XXXXABCD\P 7557 0: ABCD 7558 1: ABC 7559 XXXXABCD\P\P 7560 Partial match: ABCD 7561 7562 /abc\d*/ 7563 xxxxabc1\P 7564 0: abc1 7565 1: abc 7566 xxxxabc1\P\P 7567 Partial match: abc1 7568 7569 /abc[de]*/ 7570 xxxxabcde\P 7571 0: abcde 7572 1: abcd 7573 2: abc 7574 xxxxabcde\P\P 7575 Partial match: abcde 7576 7577 /(?:(?1)|B)(A(*F)|C)/ 7578 ABCD 7579 0: BC 7580 CCD 7581 0: CC 7582 ** Failers 7583 No match 7584 CAD 7585 No match 7586 7587 /^(?:(?1)|B)(A(*F)|C)/ 7588 CCD 7589 0: CC 7590 BCD 7591 0: BC 7592 ** Failers 7593 No match 7594 ABCD 7595 No match 7596 CAD 7597 No match 7598 BAD 7599 No match 7600 7601 /^(?!a(*SKIP)b)/ 7602 ac 7603 Error -16 7604 7605 /^(?=a(*SKIP)b|ac)/ 7606 ** Failers 7607 No match 7608 ac 7609 Error -16 7610 7611 /^(?=a(*THEN)b|ac)/ 7612 ac 7613 Error -16 7614 7615 /^(?=a(*PRUNE)b)/ 7616 ab 7617 Error -16 7618 ** Failers 7619 No match 7620 ac 7621 Error -16 7622 7623 /^(?(?!a(*SKIP)b))/ 7624 ac 7625 Error -16 7626 7627 /(?<=abc)def/ 7628 abc\P\P 7629 Partial match: abc 7630 7631 /abc$/ 7632 abc 7633 0: abc 7634 abc\P 7635 0: abc 7636 abc\P\P 7637 Partial match: abc 7638 7639 /abc$/m 7640 abc 7641 0: abc 7642 abc\n 7643 0: abc 7644 abc\P\P 7645 Partial match: abc 7646 abc\n\P\P 7647 0: abc 7648 abc\P 7649 0: abc 7650 abc\n\P 7651 0: abc 7652 7653 /abc\z/ 7654 abc 7655 0: abc 7656 abc\P 7657 0: abc 7658 abc\P\P 7659 Partial match: abc 7660 7661 /abc\Z/ 7662 abc 7663 0: abc 7664 abc\P 7665 0: abc 7666 abc\P\P 7667 Partial match: abc 7668 7669 /abc\b/ 7670 abc 7671 0: abc 7672 abc\P 7673 0: abc 7674 abc\P\P 7675 Partial match: abc 7676 7677 /abc\B/ 7678 abc 7679 No match 7680 abc\P 7681 Partial match: abc 7682 abc\P\P 7683 Partial match: abc 7684 7685 /.+/ 7686 abc\>0 7687 0: abc 7688 1: ab 7689 2: a 7690 abc\>1 7691 0: bc 7692 1: b 7693 abc\>2 7694 0: c 7695 abc\>3 7696 No match 7697 abc\>4 7698 Error -24 7699 abc\>-4 7700 Error -24 7701 7702 /-- End of testinput7 --/ 7703