diff options
Diffstat (limited to 'pcre/testdata')
61 files changed, 3980 insertions, 1197 deletions
diff --git a/pcre/testdata/grepoutput b/pcre/testdata/grepoutput index cf04091f4a2..9bf9d9d62e9 100644 --- a/pcre/testdata/grepoutput +++ b/pcre/testdata/grepoutput @@ -740,3 +740,6 @@ RC=0 [1;31m[00m [1;31m[00mtriple: t7_txt s1_tag s_txt p_tag p_txt o_tag o_txt RC=0 +---------------------------- Test 106 ----------------------------- +a +RC=0 diff --git a/pcre/testdata/saved16 b/pcre/testdata/saved16 Binary files differindex 583c4342862..f86326c9f87 100644 --- a/pcre/testdata/saved16 +++ b/pcre/testdata/saved16 diff --git a/pcre/testdata/saved16BE-1 b/pcre/testdata/saved16BE-1 Binary files differindex e2e807d4fde..e6edddc6e0b 100644 --- a/pcre/testdata/saved16BE-1 +++ b/pcre/testdata/saved16BE-1 diff --git a/pcre/testdata/saved16BE-2 b/pcre/testdata/saved16BE-2 Binary files differindex cc2718aa1ea..c91ce37bd4f 100644 --- a/pcre/testdata/saved16BE-2 +++ b/pcre/testdata/saved16BE-2 diff --git a/pcre/testdata/saved16LE-1 b/pcre/testdata/saved16LE-1 Binary files differindex b037d4903e1..5035ec07215 100644 --- a/pcre/testdata/saved16LE-1 +++ b/pcre/testdata/saved16LE-1 diff --git a/pcre/testdata/saved16LE-2 b/pcre/testdata/saved16LE-2 Binary files differindex d7034f757fe..656c058d260 100644 --- a/pcre/testdata/saved16LE-2 +++ b/pcre/testdata/saved16LE-2 diff --git a/pcre/testdata/saved32 b/pcre/testdata/saved32 Binary files differindex 5b6fe34c948..a4e27041ce1 100644 --- a/pcre/testdata/saved32 +++ b/pcre/testdata/saved32 diff --git a/pcre/testdata/saved32BE-1 b/pcre/testdata/saved32BE-1 Binary files differindex ebe62ca7c66..b4c2ffe42cc 100644 --- a/pcre/testdata/saved32BE-1 +++ b/pcre/testdata/saved32BE-1 diff --git a/pcre/testdata/saved32BE-2 b/pcre/testdata/saved32BE-2 Binary files differindex 8168343931c..79bb5e88055 100644 --- a/pcre/testdata/saved32BE-2 +++ b/pcre/testdata/saved32BE-2 diff --git a/pcre/testdata/saved32LE-1 b/pcre/testdata/saved32LE-1 Binary files differindex e008f3a5a7c..49392b89a10 100644 --- a/pcre/testdata/saved32LE-1 +++ b/pcre/testdata/saved32LE-1 diff --git a/pcre/testdata/saved32LE-2 b/pcre/testdata/saved32LE-2 Binary files differindex cf3bd731928..5f64af9b9d5 100644 --- a/pcre/testdata/saved32LE-2 +++ b/pcre/testdata/saved32LE-2 diff --git a/pcre/testdata/saved8 b/pcre/testdata/saved8 Binary files differindex 37d733eedf3..8cf0c1312de 100644 --- a/pcre/testdata/saved8 +++ b/pcre/testdata/saved8 diff --git a/pcre/testdata/testinput1 b/pcre/testdata/testinput1 index e3050ef0a99..7b36360d044 100644 --- a/pcre/testdata/testinput1 +++ b/pcre/testdata/testinput1 @@ -1,6 +1,8 @@ /-- This set of tests is for features that are compatible with all versions of - Perl >= 5.10, in non-UTF-8 mode. It should run clean for both the 8-bit and - 16-bit PCRE libraries. --/ + Perl >= 5.10, in non-UTF-8 mode. It should run clean for the 8-bit, 16-bit, + and 32-bit PCRE libraries. --/ + +< forbid 89?=ABCDEFfGILMNPTUWXZ< /the quick brown fox/ the quick brown fox @@ -1483,14 +1485,19 @@ abc\100\x30 abc\100\060 abc\100\60 + +/^A\8B\9C$/ + A8B9C + *** Failers + A\08B\09C + +/^(A)(B)(C)(D)(E)(F)(G)(H)(I)\8\9$/ + ABCDEFGHIHI -/abc\81/ - abc\081 - abc\0\x38\x31 - -/abc\91/ - abc\091 - abc\0\x39\x31 +/^[A\8B\9C]+$/ + A8B9C + *** Failers + A8B9C\x00 /(a)(b)(c)(d)(e)(f)(g)(h)(i)(j)(k)(l)\12\123/ abcdefghijkllS @@ -3654,13 +3661,6 @@ /a*/g abbab -/^[a-\d]/ - abcde - -things - 0digit - *** Failers - bcdef - /^[\d-a]/ abcde -things @@ -4221,9 +4221,6 @@ ab bc -/^(?=(a)){0}b(?1)/ - backgammon - /^(?=(?1))?[az]([abc])d/ abd zcdxx @@ -5608,4 +5605,65 @@ AbcdCBefgBhiBqz aaaa aaa +/(?(?=ab)ab)/+ + ca + cd + +/(?:(?<n>foo)|(?<n>bar))\k<n>/J + foofoo + barbar + +/(?<n>A)(?:(?<n>foo)|(?<n>bar))\k<n>/J + AfooA + AbarA + ** Failers + Afoofoo + Abarbar + +/^(\d+)\s+IN\s+SOA\s+(\S+)\s+(\S+)\s*\(\s*$/ + 1 IN SOA non-sp1 non-sp2( + +/^ (?:(?<A>A)|(?'B'B)(?<A>A)) (?('A')x) (?(<B>)y)$/xJ + Ax + BAxy + +/^A\xZ/ + A\0Z + +/^A\o{123}B/ + A\123B + +/ ^ a + + b $ /x + aaaab + +/ ^ a + #comment + + b $ /x + aaaab + +/ ^ a + #comment + #comment + + b $ /x + aaaab + +/ ^ (?> a + ) b $ /x + aaaab + +/ ^ ( a + ) + + \w $ /x + aaaab + +/(?:a\Kb)*+/+ + ababc + +/(?>a\Kb)*/+ + ababc + +/(?:a\Kb)*/+ + ababc + +/(a\Kb)*+/+ + ababc + +/(a\Kb)*/+ + ababc + /-- End of testinput1 --/ diff --git a/pcre/testdata/testinput10 b/pcre/testdata/testinput10 index 7f522e6af8f..93ddb3a75b7 100644 --- a/pcre/testdata/testinput10 +++ b/pcre/testdata/testinput10 @@ -139,6 +139,12 @@ /^\p{Cf}/8 \x{601} + \x{180e} + \x{061c} + \x{2066} + \x{2067} + \x{2068} + \x{2069} ** Failers \x{09f} @@ -199,11 +205,12 @@ /^\p{Mn}/8 \x{300} + \x{1a1b} ** Failers X \x{903} -/^\p{Nd}+/8 +/^\p{Nd}+/8O 0123456789\x{660}\x{661}\x{662}\x{663}\x{664}\x{665}\x{666}\x{667}\x{668}\x{669}\x{66a} \x{6f0}\x{6f1}\x{6f2}\x{6f3}\x{6f4}\x{6f5}\x{6f6}\x{6f7}\x{6f8}\x{6f9}\x{6fa} \x{966}\x{967}\x{968}\x{969}\x{96a}\x{96b}\x{96c}\x{96d}\x{96e}\x{96f}\x{970} @@ -243,6 +250,8 @@ ] } \x{f3b} + \x{2309} + \x{230b} ** Failers X \x{203f} @@ -250,7 +259,7 @@ [ { \x{f3c} - + /^\p{Pf}/8 \x{bb} \x{2019} @@ -277,6 +286,8 @@ [ { \x{f3c} + \x{2308} + \x{230a} ** Failers X ) @@ -326,7 +337,6 @@ \ \ \x{a0} \x{1680} - \x{180e} \x{2000} \x{2001} ** Failers @@ -423,23 +433,23 @@ ** Failers 1234 -/\D+/8 +/\D+/8O 11111111111111111111111111111111111111111111111111111111111111111111111 aaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaa -/\P{Nd}+/8 +/\P{Nd}+/8O 11111111111111111111111111111111111111111111111111111111111111111111111 aaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaa -/[\D]+/8 +/[\D]+/8O 11111111111111111111111111111111111111111111111111111111111111111111111 aaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaa -/[\P{Nd}]+/8 +/[\P{Nd}]+/8O 11111111111111111111111111111111111111111111111111111111111111111111111 aaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaa -/[\D\P{Nd}]+/8 +/[\D\P{Nd}]+/8O 11111111111111111111111111111111111111111111111111111111111111111111111 aaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaa @@ -886,19 +896,19 @@ ** Failers \x{0b} -/^>\p{Xsp}+/8 +/^>\p{Xsp}+/8O > \x{09}\x{0a}\x{0c}\x{0d}\x{a0}\x{1680}\x{2028}\x{0b} -/^>\p{Xsp}*/8 +/^>\p{Xsp}*/8O > \x{09}\x{0a}\x{0c}\x{0d}\x{a0}\x{1680}\x{2028}\x{0b} -/^>\p{Xsp}{2,9}/8 +/^>\p{Xsp}{2,9}/8O > \x{09}\x{0a}\x{0c}\x{0d}\x{a0}\x{1680}\x{2028}\x{0b} -/^>[\p{Xsp}]/8 +/^>[\p{Xsp}]/8O >\x{2028}\x{0b} -/^>[\p{Xsp}]+/8 +/^>[\p{Xsp}]+/8O > \x{09}\x{0a}\x{0c}\x{0d}\x{a0}\x{1680}\x{2028}\x{0b} /^>\p{Xps}/8 @@ -1398,4 +1408,12 @@ `abc \x{1234}abc +/^A\s+Z/8W + A\x{2005}Z + A\x{85}\x{180e}\x{2005}Z + +/^A[\s]+Z/8W + A\x{2005}Z + A\x{85}\x{180e}\x{2005}Z + /-- End of testinput10 --/ diff --git a/pcre/testdata/testinput14 b/pcre/testdata/testinput14 index e5e85207cce..325ed9e361f 100644 --- a/pcre/testdata/testinput14 +++ b/pcre/testdata/testinput14 @@ -1,6 +1,9 @@ -/-- This set of tests is run only with the 8-bit library. It starts with all - the tests of the POSIX interface, because that is supported only with the - 8-bit library. --/ +/-- This set of tests is run only with the 8-bit library. They do not require + UTF-8 or Unicode property support. The file starts with all the tests of + the POSIX interface, because that is supported only with the 8-bit library. + --/ + +< forbid 8W /abc/P abc @@ -85,9 +88,12 @@ a\nb ** Failers (too big char) A\x{123}B + A\o{443}B /\x{100}/I +/\o{400}/I + / (?: [\040\t] | \( (?: [^\\\x80-\xff\n\015()] | \\ [^\x80-\xff] | \( (?: [^\\\x80-\xff\n\015()] | \\ [^\x80-\xff] )* \) )* \) )* # optional leading comment @@ -294,8 +300,12 @@ not matter. --/ /\h/SI +/\H/SI + /\v/SI +/\V/SI + /\R/SI /[\h]/BZ @@ -326,4 +336,8 @@ not matter. --/ /[\u0100-\u0200]/<JS> +/[^\x00-a]{12,}[^b-\xff]*/BZ + +/[^\s]*\s* [^\W]+\W+ [^\d]*?\d0 [^\d\w]{4,6}?\w*A/BZ + /-- End of testinput14 --/ diff --git a/pcre/testdata/testinput15 b/pcre/testdata/testinput15 index 9aa8f6836a7..83e26773471 100644 --- a/pcre/testdata/testinput15 +++ b/pcre/testdata/testinput15 @@ -1,5 +1,7 @@ -/-- This set of tests is for UTF-8 support, and is relevant only to the 8-bit - library. --/ +/-- This set of tests is for UTF-8 support but not Unicode property support, + and is relevant only to the 8-bit library. --/ + +< forbid W /X(\C{3})/8 X\x{1234} @@ -47,7 +49,7 @@ /ÃÃÃxxx/8 -/ÃÃÃxxx/8?DZSS +/ÃÃÃxxx/8?DZSSO /badutf/8 \xdf diff --git a/pcre/testdata/testinput17 b/pcre/testdata/testinput17 index ba80318857b..1d933c7942c 100644 --- a/pcre/testdata/testinput17 +++ b/pcre/testdata/testinput17 @@ -1,6 +1,8 @@ /-- This set of tests is for the 16- and 32-bit library's basic (non-UTF-16 or -32) features that are not compatible with the 8-bit library, or which give different output in 16- or 32-bit mode. --/ + +< forbid 8W /a\Cb/ aXb @@ -293,4 +295,13 @@ /^\x{ffff}{0,3}/i \x{ffff} +/[^\x00-a]{12,}[^b-\xff]*/BZ + +/[^\s]*\s* [^\W]+\W+ [^\d]*?\d0 [^\d\w]{4,6}?\w*A/BZ + +/a*[b-\x{200}]?a#a*[b-\x{200}]?b#[a-f]*[g-\x{200}]*#[g-\x{200}]*[a-c]*#[g-\x{200}]*[a-h]*/BZ + +/^[\x{1234}\x{4321}]{2,4}?/ + \x{1234}\x{1234}\x{1234} + /-- End of testinput17 --/ diff --git a/pcre/testdata/testinput18 b/pcre/testdata/testinput18 index 42bad1fa418..abff34e73a5 100644 --- a/pcre/testdata/testinput18 +++ b/pcre/testdata/testinput18 @@ -1,5 +1,7 @@ -/-- This set of tests is for UTF-16 and UTF-32 support, and is relevant only to the - 16- and 32-bit library. --/ +/-- This set of tests is for UTF-16 and UTF-32 support, and is relevant only to + the 16- and 32-bit libraries. --/ + +< forbid W /ÃÃÃxxx/8?DZSS diff --git a/pcre/testdata/testinput2 b/pcre/testdata/testinput2 index 6c82fb56df6..00924ee98fa 100644 --- a/pcre/testdata/testinput2 +++ b/pcre/testdata/testinput2 @@ -7,6 +7,8 @@ NOTE: This is a non-UTF set of tests. When UTF support is needed, use test 5, and if Unicode Property Support is needed, use test 7. --/ + +< forbid 8W /(a)b|/I @@ -829,7 +831,13 @@ /x++/DZ -/x{1,3}+/DZ +/x{1,3}+/BZO + +/x{1,3}+/BZOi + +/[^x]{1,3}+/BZO + +/[^x]{1,3}+/BZOi /(x)*+/DZ @@ -1495,6 +1503,8 @@ a2b\CA ** Failers a1b\CZ\CA + +/(?|(?<a>)(?<b>)(?<a>)|(?<a>)(?<b>)(?<a>))/IJ /^(?P<A>a)(?P<A>b)/IJ ab\CA @@ -1935,10 +1945,7 @@ a random value. /Ix /(?<A> (?'B' abc (?(R) (?(R&A)1) (?(R&B)2) X | (?1) (?2) (?R) ))) /x abcabc1Xabc2XabcXabcabc -/(?<A> (?'B' abc (?(R) (?(R&1)1) (?(R&B)2) X | (?1) (?2) (?R) ))) /x - -/(?<1> (?'B' abc (?(R) (?(R&1)1) (?(R&B)2) X | (?1) (?2) (?R) ))) /x - abcabc1Xabc2XabcXabcabc +/(?<A> (?'B' abc (?(R) (?(R&C)1) (?(R&B)2) X | (?1) (?2) (?R) ))) /x /^(?(DEFINE) abc | xyz ) /x @@ -2055,7 +2062,7 @@ a random value. /Ix /^(a)\g{3/ -/^(a)\g{4a}/ +/^(a)\g{aa}/ /^a.b/<lf> a\rb @@ -2510,7 +2517,10 @@ a random value. /Ix ** Failers ab -/a(?!)+b/ +/a(?!)b/BZ + +/(?!)?a/BZ + ab /a(*FAIL)+b/ @@ -2535,7 +2545,9 @@ a random value. /Ix abcxypqr\Y /(*NO_START_OPT)xyz/C - abcxyz + abcxyz + +/(*NO_AUTO_POSSESS)a+b/BZ /xyz/CY abcxyz @@ -3482,6 +3494,8 @@ with \Y. ---/ /a[B-\Nc]/ +/a[B\Nc]/ + /(a)(?2){0,1999}?(b)/ /(a)(?(DEFINE)(b))(?2){0,1999}?(?2)/ @@ -3837,4 +3851,198 @@ backtracking verbs. --/ aaaaaaaaaaaaaz aaaaaaaaaaaaaz\Q10 +/-- This test causes a segfault with Perl 5.18.0 --/ + +/^(?=(a)){0}b(?1)/ + backgammon + +/(?|(?<n>f)|(?<n>b))/JI + +/(?<a>abc)(?<a>z)\k<a>()/JDZS + +/a*[bcd]/BZ + +/[bcd]*a/BZ + +/-- A complete set of tests for auto-possessification of character types --/ + +/\D+\D \D+\d \D+\S \D+\s \D+\W \D+\w \D+. \D+\C \D+\R \D+\H \D+\h \D+\V \D+\v \D+\Z \D+\z \D+$/BZx + +/\d+\D \d+\d \d+\S \d+\s \d+\W \d+\w \d+. \d+\C \d+\R \d+\H \d+\h \d+\V \d+\v \d+\Z \d+\z \d+$/BZx + +/\S+\D \S+\d \S+\S \S+\s \S+\W \S+\w \S+. \S+\C \S+\R \S+\H \S+\h \S+\V \S+\v \S+\Z \S+\z \S+$/BZx + +/\s+\D \s+\d \s+\S \s+\s \s+\W \s+\w \s+. \s+\C \s+\R \s+\H \s+\h \s+\V \s+\v \s+\Z \s+\z \s+$/BZx + +/\W+\D \W+\d \W+\S \W+\s \W+\W \W+\w \W+. \W+\C \W+\R \W+\H \W+\h \W+\V \W+\v \W+\Z \W+\z \W+$/BZx + +/\w+\D \w+\d \w+\S \w+\s \w+\W \w+\w \w+. \w+\C \w+\R \w+\H \w+\h \w+\V \w+\v \w+\Z \w+\z \w+$/BZx + +/\C+\D \C+\d \C+\S \C+\s \C+\W \C+\w \C+. \C+\C \C+\R \C+\H \C+\h \C+\V \C+\v \C+\Z \C+\z \C+$/BZx + +/\R+\D \R+\d \R+\S \R+\s \R+\W \R+\w \R+. \R+\C \R+\R \R+\H \R+\h \R+\V \R+\v \R+\Z \R+\z \R+$/BZx + +/\H+\D \H+\d \H+\S \H+\s \H+\W \H+\w \H+. \H+\C \H+\R \H+\H \H+\h \H+\V \H+\v \H+\Z \H+\z \H+$/BZx + +/\h+\D \h+\d \h+\S \h+\s \h+\W \h+\w \h+. \h+\C \h+\R \h+\H \h+\h \h+\V \h+\v \h+\Z \h+\z \h+$/BZx + +/\V+\D \V+\d \V+\S \V+\s \V+\W \V+\w \V+. \V+\C \V+\R \V+\H \V+\h \V+\V \V+\v \V+\Z \V+\z \V+$/BZx + +/\v+\D \v+\d \v+\S \v+\s \v+\W \v+\w \v+. \v+\C \v+\R \v+\H \v+\h \v+\V \v+\v \v+\Z \v+\z \v+$/BZx + +/ a+\D a+\d a+\S a+\s a+\W a+\w a+. a+\C a+\R a+\H a+\h a+\V a+\v a+\Z a+\z a+$/BZx + +/\n+\D \n+\d \n+\S \n+\s \n+\W \n+\w \n+. \n+\C \n+\R \n+\H \n+\h \n+\V \n+\v \n+\Z \n+\z \n+$/BZx + +/ .+\D .+\d .+\S .+\s .+\W .+\w .+. .+\C .+\R .+\H .+\h .+\V .+\v .+\Z .+\z .+$/BZx + +/ .+\D .+\d .+\S .+\s .+\W .+\w .+. .+\C .+\R .+\H .+\h .+\V .+\v .+\Z .+\z .+$/BZxs + +/\D+$ \d+$ \S+$ \s+$ \W+$ \w+$ \C+$ \R+$ \H+$ \h+$ \V+$ \v+$ a+$ \n+$ .+$ .+$/BZxm + +/(?=a+)a(a+)++a/BZ + +/a+(bb|cc)a+(?:bb|cc)a+(?>bb|cc)a+(?:bb|cc)+a+(aa)a+(?:bb|aa)/BZ + +/a+(bb|cc)?#a+(?:bb|cc)??#a+(?:bb|cc)?+#a+(?:bb|cc)*#a+(bb|cc)?a#a+(?:aa)?/BZ + +/a+(?:bb)?a#a+(?:|||)#a+(?:|b)a#a+(?:|||)?a/BZ + +/[ab]*/BZ + aaaa + +/[ab]*?/BZ + aaaa + +/[ab]?/BZ + aaaa + +/[ab]??/BZ + aaaa + +/[ab]+/BZ + aaaa + +/[ab]+?/BZ + aaaa + +/[ab]{2,3}/BZ + aaaa + +/[ab]{2,3}?/BZ + aaaa + +/[ab]{2,}/BZ + aaaa + +/[ab]{2,}?/BZ + aaaa + +/\d+\s{0,5}=\s*\S?=\w{0,4}\W*/BZ + +/[a-d]{5,12}[e-z0-9]*#[^a-z]+[b-y]*a[2-7]?[^0-9a-z]+/BZ + +/[a-z]*\s#[ \t]?\S#[a-c]*\S#[C-G]+?\d#[4-8]*\D#[4-9,]*\D#[!$]{0,5}\w#[M-Xf-l]+\W#[a-c,]?\W/BZ + +/a+(aa|bb)*c#a*(bb|cc)*a#a?(bb|cc)*d#[a-f]*(g|hh)*f/BZ + +/[a-f]*(g|hh|i)*i#[a-x]{4,}(y{0,6})*y#[a-k]+(ll|mm)+n/BZ + +/[a-f]*(?>gg|hh)+#[a-f]*(?>gg|hh)?#[a-f]*(?>gg|hh)*a#[a-f]*(?>gg|hh)*h/BZ + +/[a-c]*d/DZS + +/[a-c]+d/DZS + +/[a-c]?d/DZS + +/[a-c]{4,6}d/DZS + +/[a-c]{0,6}d/DZS + +/-- End of special auto-possessive tests --/ + +/^A\o{1239}B/ + A\123B + +/^A\oB/ + +/^A\x{zz}B/ + +/^A\x{12Z/ + +/^A\x{/ + +/[ab]++/BZO + +/[^ab]*+/BZO + +/a{4}+/BZO + +/a{4}+/BZOi + +/[a-[:digit:]]+/ + +/[A-[:digit:]]+/ + +/[a-[.xxx.]]+/ + +/[a-[=xxx=]]+/ + +/[a-[!xxx!]]+/ + +/[A-[!xxx!]]+/ + A]]] + +/[a-\d]+/ + +/(?<0abc>xx)/ + +/(?&1abc)xx(?<1abc>y)/ + +/(?<ab-cd>xx)/ + +/(?'0abc'xx)/ + +/(?P<0abc>xx)/ + +/\k<5ghj>/ + +/\k'5ghj'/ + +/\k{2fgh}/ + +/(?P=8yuki)/ + +/\g{4df}/ + +/(?&1abc)xx(?<1abc>y)/ + +/(?P>1abc)xx(?<1abc>y)/ + +/\g'3gh'/ + +/\g<5fg>/ + +/(?(<4gh>)abc)/ + +/(?('4gh')abc)/ + +/(?(4gh)abc)/ + +/(?(R&6yh)abc)/ + +/-- Test the ugly "start or end of word" compatibility syntax --/ + +/[[:<:]]red[[:>:]]/BZ + little red riding hood + a /red/ thing + red is a colour + put it all on red + ** Failers + no reduction + Alfred Winifred + +/[a[:<:]] should give error/ + /-- End of testinput2 --/ diff --git a/pcre/testdata/testinput21 b/pcre/testdata/testinput21 index b285d637526..30895eef2d0 100644 --- a/pcre/testdata/testinput21 +++ b/pcre/testdata/testinput21 @@ -4,7 +4,11 @@ typical). The others require the link size to be 2. */x <!testsaved8 -%-- Generated from: ^[aL](?P<name>(?:[AaLl]+)[^xX-]*?)(?P<other>[\x{150}-\x{250}\x{300}]|[^\x{800}aAs-uS-U\x{d800}-\x{dfff}])++[^#\b\x{500}\x{1000}]{3,5}$ +%-- Generated from: + /^[aL](?P<name>(?:[AaLl]+)[^xX-]*?)(?P<other>[\x{150}-\x{250}\x{300}]| + [^\x{800}aAs-uS-U\x{d800}-\x{dfff}])++[^#\b\x{500}\x{1000}]{3,5}$ + /x + In 16-bit mode with options: S>testdata/saved16LE-1 FS>testdata/saved16BE-1 In 32-bit mode with options: S>testdata/saved32LE-1 diff --git a/pcre/testdata/testinput22 b/pcre/testdata/testinput22 index 58239f1f79c..ca408dbee97 100644 --- a/pcre/testdata/testinput22 +++ b/pcre/testdata/testinput22 @@ -1,10 +1,15 @@ /-- Tests for reloading pre-compile patterns with UTF-16 or UTF-32 support. */ -%-- Generated from: (?P<cbra1>[aZ\x{400}-\x{10ffff}]{4,}[\x{f123}\x{10039}\x{20000}-\x{21234}]?|[A-Cx-z\x{100000}-\x{1000a7}\x{101234}])(?<cb2>[^az]) - In 16-bit mode with options: S8>testdata/saved16LE-1 - FS8>testdata/saved16BE-1 - In 32-bit mode with options: S8>testdata/saved32LE-1 - FS8testdata/saved32BE-1 +%-- Generated from: + /(?P<cbra1>[aZ\x{400}-\x{10ffff}]{4,} + [\x{f123}\x{10039}\x{20000}-\x{21234}]?| + [A-Cx-z\x{100000}-\x{1000a7}\x{101234}]) + (?<cb2>[^az])/x + + In 16-bit mode with options: S8>testdata/saved16LE-2 + FS8>testdata/saved16BE-2 + In 32-bit mode with options: S8>testdata/saved32LE-2 + FS8>testdata/saved32BE-2 --%8x <!testsaved16LE-2 diff --git a/pcre/testdata/testinput23 b/pcre/testdata/testinput23 index 961ae35d445..0fdbae7c577 100644 --- a/pcre/testdata/testinput23 +++ b/pcre/testdata/testinput23 @@ -1,5 +1,7 @@ /-- Tests for the 16-bit library only */ +< forbid 8W + /-- Check maximum non-UTF character size --/ /\x{ffff}/ @@ -7,6 +9,8 @@ /\x{10000}/ +/\o{20000}/ + /-- Check character ranges --/ /[\H]/BZSI diff --git a/pcre/testdata/testinput24 b/pcre/testdata/testinput24 index 71a400ed138..23eb84e55d1 100644 --- a/pcre/testdata/testinput24 +++ b/pcre/testdata/testinput24 @@ -1,5 +1,7 @@ /-- Tests for the 16-bit library with UTF-16 support only */ +< forbid W + /bad/8 \x{d800} diff --git a/pcre/testdata/testinput25 b/pcre/testdata/testinput25 index 2d65fd7b03e..ce9d9e19a40 100644 --- a/pcre/testdata/testinput25 +++ b/pcre/testdata/testinput25 @@ -1,5 +1,7 @@ /-- Tests for the 32-bit library only */ +< forbid 8w + /-- Check maximum character size --/ /\x{110000}/ @@ -10,6 +12,16 @@ /\x{ffffffff}/ +/\x{100000000}/ + +/\o{17777777777}/ + +/\o{20000000000}/ + +/\o{37777777777}/ + +/\o{40000000000}/ + /\x{7fffffff}\x{7fffffff}/I /\x{80000000}\x{80000000}/I diff --git a/pcre/testdata/testinput26 b/pcre/testdata/testinput26 index 643a1d1cdbf..6b56ac1cc56 100644 --- a/pcre/testdata/testinput26 +++ b/pcre/testdata/testinput26 @@ -1,9 +1,13 @@ /-- Tests for the 32-bit library with UTF-32 support only */ +< forbid W + /-- Non-UTF characters --/ /\x{110000}/8 +/\o{4200000}/8 + /\C/8 \x{110000} diff --git a/pcre/testdata/testinput3 b/pcre/testdata/testinput3 index 6fea2f5b3bd..1d2e855386a 100644 --- a/pcre/testdata/testinput3 +++ b/pcre/testdata/testinput3 @@ -1,6 +1,8 @@ /-- This set of tests checks local-specific features, using the fr_FR locale. It is not Perl-compatible. There is different version called wintestinput3 f or use on Windows, where the locale is called "french". --/ + +< forbid 8W /^[\w]+/ *** Failers diff --git a/pcre/testdata/testinput4 b/pcre/testdata/testinput4 index b9f1a72e4f2..983f7a119b5 100644 --- a/pcre/testdata/testinput4 +++ b/pcre/testdata/testinput4 @@ -1,6 +1,8 @@ /-- This set of tests is for UTF support, excluding Unicode properties. It is compatible with all versions of Perl >= 5.10 and both the 8-bit and 16-bit PCRE libraries. --/ + +< forbid 9?=ABCDEFfGILMNPTUWXZ< /a.b/8 acb @@ -711,4 +713,7 @@ \x{100}\x{100}\x{100}\x{100} \x{100}\x{100}\x{100} +/^a+[a\x{200}]/8 + aa + /-- End of testinput4 --/ diff --git a/pcre/testdata/testinput5 b/pcre/testdata/testinput5 index 642749c315c..9e9a22a1a1f 100644 --- a/pcre/testdata/testinput5 +++ b/pcre/testdata/testinput5 @@ -1,21 +1,37 @@ /-- This set of tests checks the API, internals, and non-Perl stuff for UTF support, excluding Unicode properties. However, tests that give different results in 8-bit and 16-bit modes are excluded (see tests 16 and 17). --/ + +< forbid W /\x{110000}/8DZ +/\o{4200000}/8DZ + /\x{ffffffff}/8 +/\o{37777777777}/8 + /\x{100000000}/8 +/\o{77777777777}/8 + /\x{d800}/8 +/\o{154000}/8 + /\x{dfff}/8 +/\o{157777}/8 + /\x{d7ff}/8 +/\o{153777}/8 + /\x{e000}/8 +/\o{170000}/8 + /^\x{100}a\x{1234}/8 \x{100}a\x{1234}bcd @@ -769,4 +785,7 @@ /\ud800/<JS>8 +/^a+[a\x{200}]/8BZ + aa + /-- End of testinput5 --/ diff --git a/pcre/testdata/testinput6 b/pcre/testdata/testinput6 index adbf621a98e..1e450be04d3 100644 --- a/pcre/testdata/testinput6 +++ b/pcre/testdata/testinput6 @@ -1,5 +1,7 @@ /-- This set of tests is for Unicode property support. It is compatible with Perl >= 5.15. --/ + +< forbid 9?=ABCDEFfGILMNPTUXZ< /^\pC\pL\pM\pN\pP\pS\pZ</8 \x7f\x{c0}\x{30f}\x{660}\x{66c}\x{f01}\x{1680}< @@ -325,12 +327,6 @@ ** Failers abc -/\p{Lu}/8i - A - aZ - ** Failers - abc - /\p{Ll}/8 a Az @@ -425,6 +421,7 @@ /^[\p{Arabic}]/8 \x{06e9} \x{060b} + \x{061c} ** Failers X\x{06e9} @@ -882,6 +879,15 @@ \x{1111}\x{ae4c}\x{1111}\x{ae4c}\x{1111}\x{ae4c}X \x{1111}\x{ae4c}\x{1111}\x{ae4c}\x{1111}\x{ae4c}\x{1111}\x{ae4c}X +/\X*Z/8Y + A\x{300} + +/\X*(.)/8Y + A\x{1111}\x{ae4c}\x{1169} + +/\X?abc/8Y +\xff\x7f\x00\x00\x03\x00\x41\xcc\x80\x41\x{300}\x61\x62\x63\x00\>06\? + /-- --/ /\x{1e9e}+/8i @@ -1319,9 +1325,163 @@ /^\p{Any}*\d{4}/8 1234 123 - + /^\X*\w{4}/8 1234 123 - + +/^A\s+Z/8W + A\x{2005}Z + A\x{85}\x{180e}\x{2005}Z + +/^A[\s]+Z/8W + A\x{2005}Z + A\x{85}\x{180e}\x{2005}Z + +/^[[:graph:]]+$/8W + Letter:ABC + Mark:\x{300}\x{1d172}\x{1d17b} + Number:9\x{660} + Punctuation:\x{66a},; + Symbol:\x{6de}<>\x{fffc} + Cf-property:\x{ad}\x{600}\x{601}\x{602}\x{603}\x{604}\x{6dd}\x{70f} + \x{200b}\x{200c}\x{200d}\x{200e}\x{200f} + \x{202a}\x{202b}\x{202c}\x{202d}\x{202e} + \x{2060}\x{2061}\x{2062}\x{2063}\x{2064} + \x{206a}\x{206b}\x{206c}\x{206d}\x{206e}\x{206f} + \x{feff} + \x{fff9}\x{fffa}\x{fffb} + \x{110bd} + \x{1d173}\x{1d174}\x{1d175}\x{1d176}\x{1d177}\x{1d178}\x{1d179}\x{1d17a} + \x{e0001} + \x{e0020}\x{e0030}\x{e0040}\x{e0050}\x{e0060}\x{e0070}\x{e007f} + ** Failers + \x{09} + \x{0a} + \x{1D} + \x{20} + \x{85} + \x{a0} + \x{61c} + \x{1680} + \x{180e} + \x{2028} + \x{2029} + \x{202f} + \x{2065} + \x{2066} + \x{2067} + \x{2068} + \x{2069} + \x{3000} + \x{e0002} + \x{e001f} + \x{e0080} + +/^[[:print:]]+$/8W + Space: \x{a0} + \x{1680}\x{2000}\x{2001}\x{2002}\x{2003}\x{2004}\x{2005} + \x{2006}\x{2007}\x{2008}\x{2009}\x{200a} + \x{202f}\x{205f} + \x{3000} + Letter:ABC + Mark:\x{300}\x{1d172}\x{1d17b} + Number:9\x{660} + Punctuation:\x{66a},; + Symbol:\x{6de}<>\x{fffc} + Cf-property:\x{ad}\x{600}\x{601}\x{602}\x{603}\x{604}\x{6dd}\x{70f} + \x{180e} + \x{200b}\x{200c}\x{200d}\x{200e}\x{200f} + \x{202a}\x{202b}\x{202c}\x{202d}\x{202e} + \x{202f} + \x{2060}\x{2061}\x{2062}\x{2063}\x{2064} + \x{206a}\x{206b}\x{206c}\x{206d}\x{206e}\x{206f} + \x{feff} + \x{fff9}\x{fffa}\x{fffb} + \x{110bd} + \x{1d173}\x{1d174}\x{1d175}\x{1d176}\x{1d177}\x{1d178}\x{1d179}\x{1d17a} + \x{e0001} + \x{e0020}\x{e0030}\x{e0040}\x{e0050}\x{e0060}\x{e0070}\x{e007f} + ** Failers + \x{09} + \x{1D} + \x{85} + \x{61c} + \x{2028} + \x{2029} + \x{2065} + \x{2066} + \x{2067} + \x{2068} + \x{2069} + \x{e0002} + \x{e001f} + \x{e0080} + +/^[[:punct:]]+$/8W + \$+<=>^`|~ + !\"#%&'()*,-./:;?@[\\]_{} + \x{a1}\x{a7} + \x{37e} + ** Failers + abcde + +/^[[:^graph:]]+$/8W + \x{09}\x{0a}\x{1D}\x{20}\x{85}\x{a0}\x{61c}\x{1680}\x{180e} + \x{2028}\x{2029}\x{202f}\x{2065}\x{2066}\x{2067}\x{2068}\x{2069} + \x{3000}\x{e0002}\x{e001f}\x{e0080} + ** Failers + Letter:ABC + Mark:\x{300}\x{1d172}\x{1d17b} + Number:9\x{660} + Punctuation:\x{66a},; + Symbol:\x{6de}<>\x{fffc} + Cf-property:\x{ad}\x{600}\x{601}\x{602}\x{603}\x{604}\x{6dd}\x{70f} + \x{200b}\x{200c}\x{200d}\x{200e}\x{200f} + \x{202a}\x{202b}\x{202c}\x{202d}\x{202e} + \x{2060}\x{2061}\x{2062}\x{2063}\x{2064} + \x{206a}\x{206b}\x{206c}\x{206d}\x{206e}\x{206f} + \x{feff} + \x{fff9}\x{fffa}\x{fffb} + \x{110bd} + \x{1d173}\x{1d174}\x{1d175}\x{1d176}\x{1d177}\x{1d178}\x{1d179}\x{1d17a} + \x{e0001} + \x{e0020}\x{e0030}\x{e0040}\x{e0050}\x{e0060}\x{e0070}\x{e007f} + +/^[[:^print:]]+$/8W + \x{09}\x{1D}\x{85}\x{61c}\x{2028}\x{2029}\x{2065}\x{2066}\x{2067} + \x{2068}\x{2069}\x{e0002}\x{e001f}\x{e0080} + ** Failers + Space: \x{a0} + \x{1680}\x{2000}\x{2001}\x{2002}\x{2003}\x{2004}\x{2005} + \x{2006}\x{2007}\x{2008}\x{2009}\x{200a} + \x{202f}\x{205f} + \x{3000} + Letter:ABC + Mark:\x{300}\x{1d172}\x{1d17b} + Number:9\x{660} + Punctuation:\x{66a},; + Symbol:\x{6de}<>\x{fffc} + Cf-property:\x{ad}\x{600}\x{601}\x{602}\x{603}\x{604}\x{6dd}\x{70f} + \x{180e} + \x{200b}\x{200c}\x{200d}\x{200e}\x{200f} + \x{202a}\x{202b}\x{202c}\x{202d}\x{202e} + \x{202f} + \x{2060}\x{2061}\x{2062}\x{2063}\x{2064} + \x{206a}\x{206b}\x{206c}\x{206d}\x{206e}\x{206f} + \x{feff} + \x{fff9}\x{fffa}\x{fffb} + \x{110bd} + \x{1d173}\x{1d174}\x{1d175}\x{1d176}\x{1d177}\x{1d178}\x{1d179}\x{1d17a} + \x{e0001} + \x{e0020}\x{e0030}\x{e0040}\x{e0050}\x{e0060}\x{e0070}\x{e007f} + +/^[[:^punct:]]+$/8W + abcde + ** Failers + \$+<=>^`|~ + !\"#%&'()*,-./:;?@[\\]_{} + \x{a1}\x{a7} + \x{37e} + /-- End of testinput6 --/ diff --git a/pcre/testdata/testinput7 b/pcre/testdata/testinput7 index 24c00d278b4..9d145436350 100644 --- a/pcre/testdata/testinput7 +++ b/pcre/testdata/testinput7 @@ -100,11 +100,30 @@ /\p{Cc}{2}+/8BZ +/^\p{Cf}/8 + \x{180e} + \x{061c} + \x{2066} + \x{2067} + \x{2068} + \x{2069} + /^\p{Cs}/8 \?\x{dfff} ** Failers \x{09f} +/^\p{Mn}/8 + \x{1a1b} + +/^\p{Pe}/8 + \x{2309} + \x{230b} + +/^\p{Ps}/8 + \x{2308} + \x{230a} + /^\p{Sc}+/8 $\x{a2}\x{a3}\x{a4}\x{a5}\x{a6} \x{9f2} @@ -116,15 +135,15 @@ \ \ \x{a0} \x{1680} - \x{180e} \x{2000} \x{2001} ** Failers \x{2028} \x{200d} -/-- These four are here rather than in test 6 because Perl has problems with - the negative versions of the properties. --/ +/-- These are here rather than in test 6 because Perl has problems with + the negative versions of the properties and behaves has changed how + it behaves for caseless matching. --/ /\p{^Lu}/8i 1234 @@ -149,6 +168,12 @@ a \x{1d00} +/\p{Lu}/8i + A + aZ + ** Failers + abc + /[\x{c0}\x{391}]/8i \x{c0} \x{e0} @@ -734,5 +759,74 @@ of case for anything other than the ASCII letters. --/ @abc `abc \x{1234}abc + +/-- Some auto-possessification tests --/ + +/\pN+\z/BZ + +/\PN+\z/BZ + +/\pN+/BZ + +/\PN+/BZ + +/\p{Any}+\p{Any} \p{Any}+\P{Any} \p{Any}+\p{L&} \p{Any}+\p{L} \p{Any}+\p{Lu} \p{Any}+\p{Han} \p{Any}+\p{Xan} \p{Any}+\p{Xsp} \p{Any}+\p{Xps} \p{Xwd}+\p{Any} \p{Any}+\p{Xuc}/BWZx + +/\p{L&}+\p{Any} \p{L&}+\p{L&} \P{L&}+\p{L&} \p{L&}+\p{L} \p{L&}+\p{Lu} \p{L&}+\p{Han} \p{L&}+\p{Xan} \p{L&}+\P{Xan} \p{L&}+\p{Xsp} \p{L&}+\p{Xps} \p{Xwd}+\p{L&} \p{L&}+\p{Xuc}/BWZx + +/\p{N}+\p{Any} \p{N}+\p{L&} \p{N}+\p{L} \p{N}+\P{L} \p{N}+\P{N} \p{N}+\p{Lu} \p{N}+\p{Han} \p{N}+\p{Xan} \p{N}+\p{Xsp} \p{N}+\p{Xps} \p{Xwd}+\p{N} \p{N}+\p{Xuc}/BWZx + +/\p{Lu}+\p{Any} \p{Lu}+\p{L&} \p{Lu}+\p{L} \p{Lu}+\p{Lu} \P{Lu}+\p{Lu} \p{Lu}+\p{Nd} \p{Lu}+\P{Nd} \p{Lu}+\p{Han} \p{Lu}+\p{Xan} \p{Lu}+\p{Xsp} \p{Lu}+\p{Xps} \p{Xwd}+\p{Lu} \p{Lu}+\p{Xuc}/BWZx + +/\p{Han}+\p{Lu} \p{Han}+\p{L&} \p{Han}+\p{L} \p{Han}+\p{Lu} \p{Han}+\p{Arabic} \p{Arabic}+\p{Arabic} \p{Han}+\p{Xan} \p{Han}+\p{Xsp} \p{Han}+\p{Xps} \p{Xwd}+\p{Han} \p{Han}+\p{Xuc}/BWZx + +/\p{Xan}+\p{Any} \p{Xan}+\p{L&} \P{Xan}+\p{L&} \p{Xan}+\p{L} \p{Xan}+\p{Lu} \p{Xan}+\p{Han} \p{Xan}+\p{Xan} \p{Xan}+\P{Xan} \p{Xan}+\p{Xsp} \p{Xan}+\p{Xps} \p{Xwd}+\p{Xan} \p{Xan}+\p{Xuc}/BWZx + +/\p{Xsp}+\p{Any} \p{Xsp}+\p{L&} \p{Xsp}+\p{L} \p{Xsp}+\p{Lu} \p{Xsp}+\p{Han} \p{Xsp}+\p{Xan} \p{Xsp}+\p{Xsp} \P{Xsp}+\p{Xsp} \p{Xsp}+\p{Xps} \p{Xwd}+\p{Xsp} \p{Xsp}+\p{Xuc}/BWZx + +/\p{Xwd}+\p{Any} \p{Xwd}+\p{L&} \p{Xwd}+\p{L} \p{Xwd}+\p{Lu} \p{Xwd}+\p{Han} \p{Xwd}+\p{Xan} \p{Xwd}+\p{Xsp} \p{Xwd}+\p{Xps} \p{Xwd}+\p{Xwd} \p{Xwd}+\P{Xwd} \p{Xwd}+\p{Xuc}/BWZx + +/\p{Xuc}+\p{Any} \p{Xuc}+\p{L&} \p{Xuc}+\p{L} \p{Xuc}+\p{Lu} \p{Xuc}+\p{Han} \p{Xuc}+\p{Xan} \p{Xuc}+\p{Xsp} \p{Xuc}+\p{Xps} \p{Xwd}+\p{Xuc} \p{Xuc}+\p{Xuc} \p{Xuc}+\P{Xuc}/BWZx + +/\p{N}+\p{Ll} \p{N}+\p{Nd} \p{N}+\P{Nd}/BWZx + +/\p{Xan}+\p{L} \p{Xan}+\p{N} \p{Xan}+\p{C} \p{Xan}+\P{L} \P{Xan}+\p{N} \p{Xan}+\P{C}/BWZx + +/\p{L}+\p{Xan} \p{N}+\p{Xan} \p{C}+\p{Xan} \P{L}+\p{Xan} \p{N}+\p{Xan} \P{C}+\p{Xan} \p{L}+\P{Xan}/BWZx + +/\p{Xan}+\p{Lu} \p{Xan}+\p{Nd} \p{Xan}+\p{Cc} \p{Xan}+\P{Ll} \P{Xan}+\p{No} \p{Xan}+\P{Cf}/BWZx + +/\p{Lu}+\p{Xan} \p{Nd}+\p{Xan} \p{Cs}+\p{Xan} \P{Lt}+\p{Xan} \p{Nl}+\p{Xan} \P{Cc}+\p{Xan} \p{Lt}+\P{Xan}/BWZx + +/\w+\p{P} \w+\p{Po} \w+\s \p{Xan}+\s \s+\p{Xan} \s+\w/BWZx + +/\w+\P{P} \W+\p{Po} \w+\S \P{Xan}+\s \s+\P{Xan} \s+\W/BWZx + +/\w+\p{Po} \w+\p{Pc} \W+\p{Po} \W+\p{Pc} \w+\P{Po} \w+\P{Pc}/BWZx + +/\p{Nl}+\p{Xan} \P{Nl}+\p{Xan} \p{Nl}+\P{Xan} \P{Nl}+\P{Xan}/BWZx + +/\p{Xan}+\p{Nl} \P{Xan}+\p{Nl} \p{Xan}+\P{Nl} \P{Xan}+\P{Nl}/BWZx + +/\p{Xan}+\p{Nd} \P{Xan}+\p{Nd} \p{Xan}+\P{Nd} \P{Xan}+\P{Nd}/BWZx + +/-- End auto-possessification tests --/ + +/\w+/8CWBZ + abcd + +/[\p{N}]?+/BZO + +/[\p{L}ab]{2,3}+/BZO + +/\D+\X \d+\X \S+\X \s+\X \W+\X \w+\X \C+\X \R+\X \H+\X \h+\X \V+\X \v+\X a+\X \n+\X .+\X/BZx + +/.+\X/BZxs + +/\X+$/BZxm + +/\X+\D \X+\d \X+\S \X+\s \X+\W \X+\w \X+. \X+\C \X+\R \X+\H \X+\h \X+\V \X+\v \X+\X \X+\Z \X+\z \X+$/BZx + +/\d+\s{0,5}=\s*\S?=\w{0,4}\W*/8WBZ /-- End of testinput7 --/ diff --git a/pcre/testdata/testinput8 b/pcre/testdata/testinput8 index d91013bb2be..bb2747b120d 100644 --- a/pcre/testdata/testinput8 +++ b/pcre/testdata/testinput8 @@ -1,5 +1,8 @@ -/-- This set of tests check the DFA matching functionality of pcre_dfa_exec(). - The -dfa flag must be used with pcretest when running it. --/ +/-- This set of tests check the DFA matching functionality of pcre_dfa_exec(), + excluding UTF and Unicode property support. The -dfa flag must be used with + pcretest when running it. --/ + +< forbid 8W /abc/ abc @@ -16,7 +19,7 @@ ac ab -/a*/ +/a*/O a aaaaaaaaaaaaaaaaa aaaaaaaaaaaaaaaaaaaaaaaaaaaaaa @@ -177,19 +180,19 @@ ayzq axyzq -/[^a]+/ +/[^a]+/O bac bcdefax *** Failers aaaaa -/[^a]*/ +/[^a]*/O bac bcdefax *** Failers aaaaa -/[^a]{3,5}/ +/[^a]{3,5}/O xyz awxyza abcdefa @@ -937,16 +940,16 @@ *** Failers the abc -/^[ab]{1,3}(ab*|b)/ +/^[ab]{1,3}(ab*|b)/O aabbbbb -/^[ab]{1,3}?(ab*|b)/ +/^[ab]{1,3}?(ab*|b)/O aabbbbb -/^[ab]{1,3}?(ab*?|b)/ +/^[ab]{1,3}?(ab*?|b)/O aabbbbb -/^[ab]{1,3}(ab*?|b)/ +/^[ab]{1,3}(ab*?|b)/O aabbbbb / (?: [\040\t] | \( @@ -1923,14 +1926,16 @@ abc\100\060 abc\100\60 -/abc\81/ - abc\081 - abc\0\x38\x31 - -/abc\91/ - abc\091 - abc\0\x39\x31 - +/^A\8B\9C$/ + A8B9C + *** Failers + A\08B\09C + +/^[A\8B\9C]+$/ + A8B9C + *** Failers + A8B9C\x00 + /(a)(b)(c)(d)(e)(f)(g)(h)(i)(j)(k)\12\123/ abcdefghijk\12S @@ -2049,13 +2054,13 @@ /foo(.*?)bar/ The food is under the bar in the barn. -/(.*)(\d*)/ +/(.*)(\d*)/O I have 2 numbers: 53147 /(.*)(\d+)/ I have 2 numbers: 53147 -/(.*?)(\d*)/ +/(.*?)(\d*)/O I have 2 numbers: 53147 /(.*?)(\d+)/ @@ -3825,13 +3830,6 @@ /a*/g abbab -/^[a-\d]/ - abcde - -things - 0digit - *** Failers - bcdef - /^[\d-a]/ abcde -things @@ -4699,7 +4697,7 @@ /(?(R)a*(?1)|((?R))b)/ aaaabcde -/(a+)/ +/(a+)/O \O6aaaa \O8aaaa @@ -4801,4 +4799,36 @@ /abcd/ abcd\O0 +/-- These tests show up auto-possessification --/ + +/[ab]*/ + aaaa + +/[ab]*?/ + aaaa + +/[ab]?/ + aaaa + +/[ab]??/ + aaaa + +/[ab]+/ + aaaa + +/[ab]+?/ + aaaa + +/[ab]{2,3}/ + aaaa + +/[ab]{2,3}?/ + aaaa + +/[ab]{2,}/ + aaaa + +/[ab]{2,}?/ + aaaa + /-- End of testinput8 --/ diff --git a/pcre/testdata/testinput9 b/pcre/testdata/testinput9 index 766c9c0fb6f..4575ffe3198 100644 --- a/pcre/testdata/testinput9 +++ b/pcre/testdata/testinput9 @@ -1,6 +1,8 @@ /-- This set of tests checks UTF-8 support with the DFA matching functionality - of pcre_dfa_exec(). The -dfa flag must be used with pcretest when running - it. --/ + of pcre_dfa_exec(), excluding Unicode property support. The -dfa flag must + be used with pcretest when running it. --/ + +< forbid W /\x{100}ab/8 \x{100}ab @@ -239,16 +241,16 @@ /\x{100}{3,5}/8 abcd\x{100}\x{100}\x{100}\x{100}\x{100}\x{100}\x{100}XX -/\x{100}{3,}/8 +/\x{100}{3,}/8O abcd\x{100}\x{100}\x{100}\x{100}\x{100}\x{100}\x{100}XX /(?<=a\x{100}{2}b)X/8 Xyyya\x{100}\x{100}bXzzz -/\D*/8 +/\D*/8O aaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaa -/\D*/8 +/\D*/8O \x{100}\x{100}\x{100}\x{100}\x{100}\x{100}\x{100}\x{100}\x{100}\x{100}\x{100}\x{100}\x{100}\x{100}\x{100}\x{100}\x{100}\x{100}\x{100}\x{100}\x{100}\x{100}\x{100}\x{100}\x{100}\x{100}\x{100}\x{100}\x{100}\x{100}\x{100}\x{100}\x{100}\x{100}\x{100}\x{100}\x{100}\x{100}\x{100}\x{100}\x{100}\x{100}\x{100}\x{100}\x{100}\x{100}\x{100}\x{100}\x{100}\x{100}\x{100}\x{100}\x{100}\x{100}\x{100}\x{100}\x{100}\x{100}\x{100}\x{100}\x{100}\x{100}\x{100}\x{100}\x{100}\x{100}\x{100}\x{100}\x{100}\x{100}\x{100}\x{100}\x{100}\x{100}\x{100}\x{100}\x{100}\x{100}\x{100}\x{100}\x{100}\x{100}\x{100}\x{100}\x{100}\x{100}\x{100}\x{100}\x{100}\x{100}\x{100}\x{100}\x{100}\x{100}\x{100}\x{100}\x{100}\x{100}\x{100}\x{100}\x{100}\x{100}\x{100}\x{100}\x{100}\x{100}\x{100}\x{100}\x{100}\x{100}\x{100}\x{100}\x{100}\x{100}\x{100}\x{100}\x{100}\x{100}\x{100}\x{100}\x{100}\x{100}\x{100}\x{100}\x{100}\x{100}\x{100}\x{100}\x{100}\x{100}\x{100}\x{100}\x{100}\x{100}\x{100}\x{100}\x{100}\x{100}\x{100}\x{100}\x{100}\x{100}\x{100}\x{100}\x{100}\x{100}\x{100}\x{100}\x{100}\x{100}\x{100}\x{100}\x{100}\x{100}\x{100}\x{100}\x{100}\x{100}\x{100}\x{100}\x{100}\x{100}\x{100}\x{100}\x{100}\x{100}\x{100}\x{100}\x{100}\x{100}\x{100}\x{100}\x{100}\x{100}\x{100}\x{100}\x{100}\x{100}\x{100}\x{100}\x{100}\x{100}\x{100}\x{100}\x{100}\x{100}\x{100}\x{100}\x{100}\x{100}\x{100}\x{100}\x{100}\x{100}\x{100}\x{100}\x{100}\x{100}\x{100}\x{100}\x{100}\x{100}\x{100}\x{100}\x{100}\x{100}\x{100}\x{100}\x{100}\x{100}\x{100}\x{100}\x{100}\x{100}\x{100}\x{100}\x{100}\x{100}\x{100}\x{100}\x{100}\x{100} /\D/8 @@ -584,16 +586,16 @@ a\n\n\n\rb a\r -/\h+\V?\v{3,4}/8 +/\h+\V?\v{3,4}/8O \x09\x20\x{a0}X\x0a\x0b\x0c\x0d\x0a -/\V?\v{3,4}/8 +/\V?\v{3,4}/8O \x20\x{a0}X\x0a\x0b\x0c\x0d\x0a -/\h+\V?\v{3,4}/8 +/\h+\V?\v{3,4}/8O >\x09\x20\x{a0}X\x0a\x0a\x0a< -/\V?\v{3,4}/8 +/\V?\v{3,4}/8O >\x09\x20\x{a0}X\x0a\x0a\x0a< /\H\h\V\v/8 @@ -602,7 +604,7 @@ ** Failers \x{a0} X\x0a -/\H*\h+\V?\v{3,4}/8 +/\H*\h+\V?\v{3,4}/8O \x09\x20\x{a0}X\x0a\x0b\x0c\x0d\x0a \x09\x20\x{a0}\x0a\x0b\x0c\x0d\x0a \x09\x20\x{a0}\x0a\x0b\x0c @@ -615,7 +617,7 @@ ** Failers \x{2009} X\x0a -/\H*\h+\V?\v{3,4}/8 +/\H*\h+\V?\v{3,4}/8O \x{1680}\x{180e}\x{2007}X\x{2028}\x{2029}\x0c\x0d\x0a \x09\x{205f}\x{a0}\x0a\x{2029}\x0c\x{2028}\x0a \x09\x20\x{202f}\x0a\x0b\x0c diff --git a/pcre/testdata/testoutput1 b/pcre/testdata/testoutput1 index 3ed635146a4..4dafc0496ab 100644 --- a/pcre/testdata/testoutput1 +++ b/pcre/testdata/testoutput1 @@ -1,6 +1,8 @@ /-- This set of tests is for features that are compatible with all versions of - Perl >= 5.10, in non-UTF-8 mode. It should run clean for both the 8-bit and - 16-bit PCRE libraries. --/ + Perl >= 5.10, in non-UTF-8 mode. It should run clean for the 8-bit, 16-bit, + and 32-bit PCRE libraries. --/ + +< forbid 89?=ABCDEFfGILMNPTUWXZ< /the quick brown fox/ the quick brown fox @@ -2149,18 +2151,35 @@ No match abc\100\60 0: abc@0 1: abc - -/abc\81/ - abc\081 - 0: abc\x0081 - abc\0\x38\x31 - 0: abc\x0081 - -/abc\91/ - abc\091 - 0: abc\x0091 - abc\0\x39\x31 - 0: abc\x0091 + +/^A\8B\9C$/ + A8B9C + 0: A8B9C + *** Failers +No match + A\08B\09C +No match + +/^(A)(B)(C)(D)(E)(F)(G)(H)(I)\8\9$/ + ABCDEFGHIHI + 0: ABCDEFGHIHI + 1: A + 2: B + 3: C + 4: D + 5: E + 6: F + 7: G + 8: H + 9: I + +/^[A\8B\9C]+$/ + A8B9C + 0: A8B9C + *** Failers +No match + A8B9C\x00 +No match /(a)(b)(c)(d)(e)(f)(g)(h)(i)(j)(k)(l)\12\123/ abcdefghijkllS @@ -5972,18 +5991,6 @@ No match 0: 0: -/^[a-\d]/ - abcde - 0: a - -things - 0: - - 0digit - 0: 0 - *** Failers -No match - bcdef -No match - /^[\d-a]/ abcde 0: a @@ -6006,15 +6013,15 @@ No match /[\s]+/ > \x09\x0a\x0c\x0d\x0b< - 0: \x09\x0a\x0c\x0d + 0: \x09\x0a\x0c\x0d\x0b /\s+/ > \x09\x0a\x0c\x0d\x0b< - 0: \x09\x0a\x0c\x0d + 0: \x09\x0a\x0c\x0d\x0b /ab/x ab -No match + 0: ab /(?!\A)x/m a\nxb\n @@ -6904,10 +6911,6 @@ No match bc 0: b -/^(?=(a)){0}b(?1)/ - backgammon - 0: ba - /^(?=(?1))?[az]([abc])d/ abd 0: abd @@ -9200,4 +9203,114 @@ No match aaa No match +/(?(?=ab)ab)/+ + ca + 0: + 0+ ca + cd + 0: + 0+ cd + +/(?:(?<n>foo)|(?<n>bar))\k<n>/J + foofoo + 0: foofoo + 1: foo + barbar + 0: barbar + 1: <unset> + 2: bar + +/(?<n>A)(?:(?<n>foo)|(?<n>bar))\k<n>/J + AfooA + 0: AfooA + 1: A + 2: foo + AbarA + 0: AbarA + 1: A + 2: <unset> + 3: bar + ** Failers +No match + Afoofoo +No match + Abarbar +No match + +/^(\d+)\s+IN\s+SOA\s+(\S+)\s+(\S+)\s*\(\s*$/ + 1 IN SOA non-sp1 non-sp2( + 0: 1 IN SOA non-sp1 non-sp2( + 1: 1 + 2: non-sp1 + 3: non-sp2 + +/^ (?:(?<A>A)|(?'B'B)(?<A>A)) (?('A')x) (?(<B>)y)$/xJ + Ax + 0: Ax + 1: A + BAxy + 0: BAxy + 1: <unset> + 2: B + 3: A + +/^A\xZ/ + A\0Z + 0: A\x00Z + +/^A\o{123}B/ + A\123B + 0: ASB + +/ ^ a + + b $ /x + aaaab + 0: aaaab + +/ ^ a + #comment + + b $ /x + aaaab + 0: aaaab + +/ ^ a + #comment + #comment + + b $ /x + aaaab + 0: aaaab + +/ ^ (?> a + ) b $ /x + aaaab + 0: aaaab + +/ ^ ( a + ) + + \w $ /x + aaaab + 0: aaaab + 1: aaaa + +/(?:a\Kb)*+/+ + ababc + 0: b + 0+ c + +/(?>a\Kb)*/+ + ababc + 0: b + 0+ c + +/(?:a\Kb)*/+ + ababc + 0: b + 0+ c + +/(a\Kb)*+/+ + ababc + 0: b + 0+ c + 1: ab + +/(a\Kb)*/+ + ababc + 0: b + 0+ c + 1: ab + /-- End of testinput1 --/ diff --git a/pcre/testdata/testoutput10 b/pcre/testdata/testoutput10 index 0e04205bb88..b89169cdd3c 100644 --- a/pcre/testdata/testoutput10 +++ b/pcre/testdata/testoutput10 @@ -39,9 +39,6 @@ No match /^\pL+/8 abcd 0: abcd - 1: abc - 2: ab - 3: a a 0: a *** Failers @@ -50,45 +47,24 @@ No match /^\PL+/8 1234 0: 1234 - 1: 123 - 2: 12 - 3: 1 = 0: = *** Failers 0: *** - 1: *** - 2: ** - 3: * abcd No match /^\X+/8 abcdA\x{300}\x{301}\x{302} 0: abcdA\x{300}\x{301}\x{302} - 1: abcd - 2: abc - 3: ab - 4: a A\x{300}\x{301}\x{302} 0: A\x{300}\x{301}\x{302} A\x{300}\x{301}\x{302}A\x{300}\x{301}\x{302} 0: A\x{300}\x{301}\x{302}A\x{300}\x{301}\x{302} - 1: A\x{300}\x{301}\x{302} a 0: a *** Failers 0: *** Failers - 1: *** Failer - 2: *** Faile - 3: *** Fail - 4: *** Fai - 5: *** Fa - 6: *** F - 7: *** - 8: *** - 9: ** -10: * \x{300}\x{301}\x{302} 0: \x{300}\x{301}\x{302} @@ -255,6 +231,18 @@ No match /^\p{Cf}/8 \x{601} 0: \x{601} + \x{180e} + 0: \x{180e} + \x{061c} + 0: \x{61c} + \x{2066} + 0: \x{2066} + \x{2067} + 0: \x{2067} + \x{2068} + 0: \x{2068} + \x{2069} + 0: \x{2069} ** Failers No match \x{09f} @@ -353,6 +341,8 @@ No match /^\p{Mn}/8 \x{300} 0: \x{300} + \x{1a1b} + 0: \x{1a1b} ** Failers No match X @@ -360,7 +350,7 @@ No match \x{903} No match -/^\p{Nd}+/8 +/^\p{Nd}+/8O 0123456789\x{660}\x{661}\x{662}\x{663}\x{664}\x{665}\x{666}\x{667}\x{668}\x{669}\x{66a} 0: 0123456789\x{660}\x{661}\x{662}\x{663}\x{664}\x{665}\x{666}\x{667}\x{668}\x{669} 1: 0123456789\x{660}\x{661}\x{662}\x{663}\x{664}\x{665}\x{666}\x{667}\x{668} @@ -466,6 +456,10 @@ No match 0: } \x{f3b} 0: \x{f3b} + \x{2309} + 0: \x{2309} + \x{230b} + 0: \x{230b} ** Failers No match X @@ -480,7 +474,7 @@ No match No match \x{f3c} No match - + /^\p{Pf}/8 \x{bb} 0: \x{bb} @@ -526,6 +520,10 @@ No match 0: { \x{f3c} 0: \x{f3c} + \x{2308} + 0: \x{2308} + \x{230a} + 0: \x{230a} ** Failers No match X @@ -542,10 +540,6 @@ No match /^\p{Sc}+/8 $\x{a2}\x{a3}\x{a4}\x{a5}\x{a6} 0: $\x{a2}\x{a3}\x{a4}\x{a5} - 1: $\x{a2}\x{a3}\x{a4} - 2: $\x{a2}\x{a3} - 3: $\x{a2} - 4: $ \x{9f2} 0: \x{9f2} ** Failers @@ -568,11 +562,6 @@ No match /^\p{Sm}+/8 +<|~\x{ac}\x{2044} 0: +<|~\x{ac}\x{2044} - 1: +<|~\x{ac} - 2: +<|~ - 3: +<| - 4: +< - 5: + ** Failers No match X @@ -619,8 +608,6 @@ No match 0: \x{a0} \x{1680} 0: \x{1680} - \x{180e} - 0: \x{180e} \x{2000} 0: \x{2000} \x{2001} @@ -767,23 +754,10 @@ No match /[\p{Nd}+-]+/8 1234 0: 1234 - 1: 123 - 2: 12 - 3: 1 12-34 0: 12-34 - 1: 12-3 - 2: 12- - 3: 12 - 4: 1 12+\x{661}-34 0: 12+\x{661}-34 - 1: 12+\x{661}-3 - 2: 12+\x{661}- - 3: 12+\x{661} - 4: 12+ - 5: 12 - 6: 1 ** Failers No match abcd @@ -792,24 +766,12 @@ No match /[\P{Nd}]+/8 abcd 0: abcd - 1: abc - 2: ab - 3: a ** Failers 0: ** Failers - 1: ** Failer - 2: ** Faile - 3: ** Fail - 4: ** Fai - 5: ** Fa - 6: ** F - 7: ** - 8: ** - 9: * 1234 No match -/\D+/8 +/\D+/8O 11111111111111111111111111111111111111111111111111111111111111111111111 No match aaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaa @@ -837,7 +799,7 @@ Matched, but offsets vector is too small to show all matches 20: aaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaa 21: aaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaa -/\P{Nd}+/8 +/\P{Nd}+/8O 11111111111111111111111111111111111111111111111111111111111111111111111 No match aaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaa @@ -865,7 +827,7 @@ Matched, but offsets vector is too small to show all matches 20: aaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaa 21: aaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaa -/[\D]+/8 +/[\D]+/8O 11111111111111111111111111111111111111111111111111111111111111111111111 No match aaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaa @@ -893,7 +855,7 @@ Matched, but offsets vector is too small to show all matches 20: aaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaa 21: aaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaa -/[\P{Nd}]+/8 +/[\P{Nd}]+/8O 11111111111111111111111111111111111111111111111111111111111111111111111 No match aaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaa @@ -921,7 +883,7 @@ Matched, but offsets vector is too small to show all matches 20: aaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaa 21: aaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaa -/[\D\P{Nd}]+/8 +/[\D\P{Nd}]+/8O 11111111111111111111111111111111111111111111111111111111111111111111111 No match aaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaa @@ -1046,10 +1008,6 @@ No match /\x{391}+/8i \x{391}\x{3b1}\x{3b1}\x{3b1}\x{391} 0: \x{391}\x{3b1}\x{3b1}\x{3b1}\x{391} - 1: \x{391}\x{3b1}\x{3b1}\x{3b1} - 2: \x{391}\x{3b1}\x{3b1} - 3: \x{391}\x{3b1} - 4: \x{391} /\x{391}{3,5}(.)/8i \x{391}\x{3b1}\x{3b1}\x{3b1}\x{391}X @@ -1236,8 +1194,6 @@ No match /^\p{Han}+/8 \x{2e81}\x{3007}\x{2f804}\x{31a0} 0: \x{2e81}\x{3007}\x{2f804} - 1: \x{2e81}\x{3007} - 2: \x{2e81} ** Failers No match \x{2e7f} @@ -1248,15 +1204,6 @@ No match 0: \x{3105} ** Failers 0: ** Failers - 1: ** Failer - 2: ** Faile - 3: ** Fail - 4: ** Fai - 5: ** Fa - 6: ** F - 7: ** - 8: ** - 9: * \x{30ff} No match @@ -1469,12 +1416,8 @@ No match /^\p{Any}{3,5}/8 abcdefgh 0: abcde - 1: abcd - 2: abc \x{1234}\n\r\x{3456}xyz 0: \x{1234}\x{0a}\x{0d}\x{3456}x - 1: \x{1234}\x{0a}\x{0d}\x{3456} - 2: \x{1234}\x{0a}\x{0d} /^\P{Any}{3,5}?/8 ** Failers @@ -1639,14 +1582,10 @@ No match /\x{c0}+\x{116}+/8i \x{c0}\x{e0}\x{116}\x{117} 0: \x{c0}\x{e0}\x{116}\x{117} - 1: \x{c0}\x{e0}\x{116} /[\x{c0}\x{116}]+/8i \x{c0}\x{e0}\x{116}\x{117} 0: \x{c0}\x{e0}\x{116}\x{117} - 1: \x{c0}\x{e0}\x{116} - 2: \x{c0}\x{e0} - 3: \x{c0} /Check property support in non-UTF-8 mode/ @@ -1693,16 +1632,6 @@ No match /^\p{Xan}+/8 ABCD1234\x{6ca}\x{a6c}\x{10a7}_ 0: ABCD1234\x{6ca}\x{a6c}\x{10a7} - 1: ABCD1234\x{6ca}\x{a6c} - 2: ABCD1234\x{6ca} - 3: ABCD1234 - 4: ABCD123 - 5: ABCD12 - 6: ABCD1 - 7: ABCD - 8: ABC - 9: AB -10: A ** Failers No match _ABC @@ -1711,28 +1640,10 @@ No match /^\p{Xan}*/8 ABCD1234\x{6ca}\x{a6c}\x{10a7}_ 0: ABCD1234\x{6ca}\x{a6c}\x{10a7} - 1: ABCD1234\x{6ca}\x{a6c} - 2: ABCD1234\x{6ca} - 3: ABCD1234 - 4: ABCD123 - 5: ABCD12 - 6: ABCD1 - 7: ABCD - 8: ABC - 9: AB -10: A -11: /^\p{Xan}{2,9}/8 ABCD1234\x{6ca}\x{a6c}\x{10a7}_ 0: ABCD1234\x{6ca} - 1: ABCD1234 - 2: ABCD123 - 3: ABCD12 - 4: ABCD1 - 5: ABCD - 6: ABC - 7: AB /^[\p{Xan}]/8 ABCD1234_ @@ -1753,16 +1664,6 @@ No match /^[\p{Xan}]+/8 ABCD1234\x{6ca}\x{a6c}\x{10a7}_ 0: ABCD1234\x{6ca}\x{a6c}\x{10a7} - 1: ABCD1234\x{6ca}\x{a6c} - 2: ABCD1234\x{6ca} - 3: ABCD1234 - 4: ABCD123 - 5: ABCD12 - 6: ABCD1 - 7: ABCD - 8: ABC - 9: AB -10: A ** Failers No match _ABC @@ -1776,53 +1677,57 @@ No match \x{0b} No match -/^>\p{Xsp}+/8 +/^>\p{Xsp}+/8O > \x{09}\x{0a}\x{0c}\x{0d}\x{a0}\x{1680}\x{2028}\x{0b} - 0: > \x{09}\x{0a}\x{0c}\x{0d}\x{a0}\x{1680}\x{2028} - 1: > \x{09}\x{0a}\x{0c}\x{0d}\x{a0}\x{1680} - 2: > \x{09}\x{0a}\x{0c}\x{0d}\x{a0} - 3: > \x{09}\x{0a}\x{0c}\x{0d} - 4: > \x{09}\x{0a}\x{0c} - 5: > \x{09}\x{0a} - 6: > \x{09} - 7: > - -/^>\p{Xsp}*/8 + 0: > \x{09}\x{0a}\x{0c}\x{0d}\x{a0}\x{1680}\x{2028}\x{0b} + 1: > \x{09}\x{0a}\x{0c}\x{0d}\x{a0}\x{1680}\x{2028} + 2: > \x{09}\x{0a}\x{0c}\x{0d}\x{a0}\x{1680} + 3: > \x{09}\x{0a}\x{0c}\x{0d}\x{a0} + 4: > \x{09}\x{0a}\x{0c}\x{0d} + 5: > \x{09}\x{0a}\x{0c} + 6: > \x{09}\x{0a} + 7: > \x{09} + 8: > + +/^>\p{Xsp}*/8O > \x{09}\x{0a}\x{0c}\x{0d}\x{a0}\x{1680}\x{2028}\x{0b} - 0: > \x{09}\x{0a}\x{0c}\x{0d}\x{a0}\x{1680}\x{2028} - 1: > \x{09}\x{0a}\x{0c}\x{0d}\x{a0}\x{1680} - 2: > \x{09}\x{0a}\x{0c}\x{0d}\x{a0} - 3: > \x{09}\x{0a}\x{0c}\x{0d} - 4: > \x{09}\x{0a}\x{0c} - 5: > \x{09}\x{0a} - 6: > \x{09} - 7: > - 8: > + 0: > \x{09}\x{0a}\x{0c}\x{0d}\x{a0}\x{1680}\x{2028}\x{0b} + 1: > \x{09}\x{0a}\x{0c}\x{0d}\x{a0}\x{1680}\x{2028} + 2: > \x{09}\x{0a}\x{0c}\x{0d}\x{a0}\x{1680} + 3: > \x{09}\x{0a}\x{0c}\x{0d}\x{a0} + 4: > \x{09}\x{0a}\x{0c}\x{0d} + 5: > \x{09}\x{0a}\x{0c} + 6: > \x{09}\x{0a} + 7: > \x{09} + 8: > + 9: > -/^>\p{Xsp}{2,9}/8 +/^>\p{Xsp}{2,9}/8O > \x{09}\x{0a}\x{0c}\x{0d}\x{a0}\x{1680}\x{2028}\x{0b} - 0: > \x{09}\x{0a}\x{0c}\x{0d}\x{a0}\x{1680}\x{2028} - 1: > \x{09}\x{0a}\x{0c}\x{0d}\x{a0}\x{1680} - 2: > \x{09}\x{0a}\x{0c}\x{0d}\x{a0} - 3: > \x{09}\x{0a}\x{0c}\x{0d} - 4: > \x{09}\x{0a}\x{0c} - 5: > \x{09}\x{0a} - 6: > \x{09} + 0: > \x{09}\x{0a}\x{0c}\x{0d}\x{a0}\x{1680}\x{2028}\x{0b} + 1: > \x{09}\x{0a}\x{0c}\x{0d}\x{a0}\x{1680}\x{2028} + 2: > \x{09}\x{0a}\x{0c}\x{0d}\x{a0}\x{1680} + 3: > \x{09}\x{0a}\x{0c}\x{0d}\x{a0} + 4: > \x{09}\x{0a}\x{0c}\x{0d} + 5: > \x{09}\x{0a}\x{0c} + 6: > \x{09}\x{0a} + 7: > \x{09} -/^>[\p{Xsp}]/8 +/^>[\p{Xsp}]/8O >\x{2028}\x{0b} 0: >\x{2028} -/^>[\p{Xsp}]+/8 +/^>[\p{Xsp}]+/8O > \x{09}\x{0a}\x{0c}\x{0d}\x{a0}\x{1680}\x{2028}\x{0b} - 0: > \x{09}\x{0a}\x{0c}\x{0d}\x{a0}\x{1680}\x{2028} - 1: > \x{09}\x{0a}\x{0c}\x{0d}\x{a0}\x{1680} - 2: > \x{09}\x{0a}\x{0c}\x{0d}\x{a0} - 3: > \x{09}\x{0a}\x{0c}\x{0d} - 4: > \x{09}\x{0a}\x{0c} - 5: > \x{09}\x{0a} - 6: > \x{09} - 7: > + 0: > \x{09}\x{0a}\x{0c}\x{0d}\x{a0}\x{1680}\x{2028}\x{0b} + 1: > \x{09}\x{0a}\x{0c}\x{0d}\x{a0}\x{1680}\x{2028} + 2: > \x{09}\x{0a}\x{0c}\x{0d}\x{a0}\x{1680} + 3: > \x{09}\x{0a}\x{0c}\x{0d}\x{a0} + 4: > \x{09}\x{0a}\x{0c}\x{0d} + 5: > \x{09}\x{0a}\x{0c} + 6: > \x{09}\x{0a} + 7: > \x{09} + 8: > /^>\p{Xps}/8 >\x{1680}\x{2028}\x{0b} @@ -1837,14 +1742,6 @@ No match /^>\p{Xps}+/8 > \x{09}\x{0a}\x{0c}\x{0d}\x{a0}\x{1680}\x{2028}\x{0b} 0: > \x{09}\x{0a}\x{0c}\x{0d}\x{a0}\x{1680}\x{2028}\x{0b} - 1: > \x{09}\x{0a}\x{0c}\x{0d}\x{a0}\x{1680}\x{2028} - 2: > \x{09}\x{0a}\x{0c}\x{0d}\x{a0}\x{1680} - 3: > \x{09}\x{0a}\x{0c}\x{0d}\x{a0} - 4: > \x{09}\x{0a}\x{0c}\x{0d} - 5: > \x{09}\x{0a}\x{0c} - 6: > \x{09}\x{0a} - 7: > \x{09} - 8: > /^>\p{Xps}+?/8 >\x{1680}\x{2028}\x{0b} @@ -1855,26 +1752,10 @@ No match /^>\p{Xps}*/8 > \x{09}\x{0a}\x{0c}\x{0d}\x{a0}\x{1680}\x{2028}\x{0b} 0: > \x{09}\x{0a}\x{0c}\x{0d}\x{a0}\x{1680}\x{2028}\x{0b} - 1: > \x{09}\x{0a}\x{0c}\x{0d}\x{a0}\x{1680}\x{2028} - 2: > \x{09}\x{0a}\x{0c}\x{0d}\x{a0}\x{1680} - 3: > \x{09}\x{0a}\x{0c}\x{0d}\x{a0} - 4: > \x{09}\x{0a}\x{0c}\x{0d} - 5: > \x{09}\x{0a}\x{0c} - 6: > \x{09}\x{0a} - 7: > \x{09} - 8: > - 9: > /^>\p{Xps}{2,9}/8 > \x{09}\x{0a}\x{0c}\x{0d}\x{a0}\x{1680}\x{2028}\x{0b} 0: > \x{09}\x{0a}\x{0c}\x{0d}\x{a0}\x{1680}\x{2028}\x{0b} - 1: > \x{09}\x{0a}\x{0c}\x{0d}\x{a0}\x{1680}\x{2028} - 2: > \x{09}\x{0a}\x{0c}\x{0d}\x{a0}\x{1680} - 3: > \x{09}\x{0a}\x{0c}\x{0d}\x{a0} - 4: > \x{09}\x{0a}\x{0c}\x{0d} - 5: > \x{09}\x{0a}\x{0c} - 6: > \x{09}\x{0a} - 7: > \x{09} /^>\p{Xps}{2,9}?/8 > \x{09}\x{0a}\x{0c}\x{0d}\x{a0}\x{1680}\x{2028}\x{0b} @@ -1894,14 +1775,6 @@ No match /^>[\p{Xps}]+/8 > \x{09}\x{0a}\x{0c}\x{0d}\x{a0}\x{1680}\x{2028}\x{0b} 0: > \x{09}\x{0a}\x{0c}\x{0d}\x{a0}\x{1680}\x{2028}\x{0b} - 1: > \x{09}\x{0a}\x{0c}\x{0d}\x{a0}\x{1680}\x{2028} - 2: > \x{09}\x{0a}\x{0c}\x{0d}\x{a0}\x{1680} - 3: > \x{09}\x{0a}\x{0c}\x{0d}\x{a0} - 4: > \x{09}\x{0a}\x{0c}\x{0d} - 5: > \x{09}\x{0a}\x{0c} - 6: > \x{09}\x{0a} - 7: > \x{09} - 8: > /^\p{Xwd}/8 ABCD @@ -1924,42 +1797,14 @@ No match /^\p{Xwd}+/8 ABCD1234\x{6ca}\x{a6c}\x{10a7}_ 0: ABCD1234\x{6ca}\x{a6c}\x{10a7}_ - 1: ABCD1234\x{6ca}\x{a6c}\x{10a7} - 2: ABCD1234\x{6ca}\x{a6c} - 3: ABCD1234\x{6ca} - 4: ABCD1234 - 5: ABCD123 - 6: ABCD12 - 7: ABCD1 - 8: ABCD - 9: ABC -10: AB -11: A /^\p{Xwd}*/8 ABCD1234\x{6ca}\x{a6c}\x{10a7}_ 0: ABCD1234\x{6ca}\x{a6c}\x{10a7}_ - 1: ABCD1234\x{6ca}\x{a6c}\x{10a7} - 2: ABCD1234\x{6ca}\x{a6c} - 3: ABCD1234\x{6ca} - 4: ABCD1234 - 5: ABCD123 - 6: ABCD12 - 7: ABCD1 - 8: ABCD - 9: ABC -10: AB -11: A -12: /^\p{Xwd}{2,9}/8 A_12\x{6ca}\x{a6c}\x{10a7} 0: A_12\x{6ca}\x{a6c}\x{10a7} - 1: A_12\x{6ca}\x{a6c} - 2: A_12\x{6ca} - 3: A_12 - 4: A_1 - 5: A_ /^[\p{Xwd}]/8 ABCD1234_ @@ -1982,17 +1827,6 @@ No match /^[\p{Xwd}]+/8 ABCD1234\x{6ca}\x{a6c}\x{10a7}_ 0: ABCD1234\x{6ca}\x{a6c}\x{10a7}_ - 1: ABCD1234\x{6ca}\x{a6c}\x{10a7} - 2: ABCD1234\x{6ca}\x{a6c} - 3: ABCD1234\x{6ca} - 4: ABCD1234 - 5: ABCD123 - 6: ABCD12 - 7: ABCD1 - 8: ABCD - 9: ABC -10: AB -11: A /-- Unicode properties for \b abd \B --/ @@ -2043,7 +1877,6 @@ No match /[^\x{100}]+/8i \x{100}\x{101}XX 0: XX - 1: X /^\X/8 A\P @@ -2090,7 +1923,6 @@ Partial match: A\x{300}\x{301}A\x{300}\x{301} /^\X+/8 AA\P 0: AA - 1: A AA\P\P Partial match: AA @@ -2271,435 +2103,299 @@ Partial match: AA /\x{1e9e}+/8i \x{1e9e}\x{00df} 0: \x{1e9e}\x{df} - 1: \x{1e9e} /[z\x{1e9e}]+/8i \x{1e9e}\x{00df} 0: \x{1e9e}\x{df} - 1: \x{1e9e} /\x{00df}+/8i \x{1e9e}\x{00df} 0: \x{1e9e}\x{df} - 1: \x{1e9e} /[z\x{00df}]+/8i \x{1e9e}\x{00df} 0: \x{1e9e}\x{df} - 1: \x{1e9e} /\x{1f88}+/8i \x{1f88}\x{1f80} 0: \x{1f88}\x{1f80} - 1: \x{1f88} /[z\x{1f88}]+/8i \x{1f88}\x{1f80} 0: \x{1f88}\x{1f80} - 1: \x{1f88} /-- Perl matches these --/ /\x{00b5}+/8i \x{00b5}\x{039c}\x{03bc} 0: \x{b5}\x{39c}\x{3bc} - 1: \x{b5}\x{39c} - 2: \x{b5} /\x{039c}+/8i \x{00b5}\x{039c}\x{03bc} 0: \x{b5}\x{39c}\x{3bc} - 1: \x{b5}\x{39c} - 2: \x{b5} /\x{03bc}+/8i \x{00b5}\x{039c}\x{03bc} 0: \x{b5}\x{39c}\x{3bc} - 1: \x{b5}\x{39c} - 2: \x{b5} /\x{00c5}+/8i \x{00c5}\x{00e5}\x{212b} 0: \x{c5}\x{e5}\x{212b} - 1: \x{c5}\x{e5} - 2: \x{c5} /\x{00e5}+/8i \x{00c5}\x{00e5}\x{212b} 0: \x{c5}\x{e5}\x{212b} - 1: \x{c5}\x{e5} - 2: \x{c5} /\x{212b}+/8i \x{00c5}\x{00e5}\x{212b} 0: \x{c5}\x{e5}\x{212b} - 1: \x{c5}\x{e5} - 2: \x{c5} /\x{01c4}+/8i \x{01c4}\x{01c5}\x{01c6} 0: \x{1c4}\x{1c5}\x{1c6} - 1: \x{1c4}\x{1c5} - 2: \x{1c4} /\x{01c5}+/8i \x{01c4}\x{01c5}\x{01c6} 0: \x{1c4}\x{1c5}\x{1c6} - 1: \x{1c4}\x{1c5} - 2: \x{1c4} /\x{01c6}+/8i \x{01c4}\x{01c5}\x{01c6} 0: \x{1c4}\x{1c5}\x{1c6} - 1: \x{1c4}\x{1c5} - 2: \x{1c4} /\x{01c7}+/8i \x{01c7}\x{01c8}\x{01c9} 0: \x{1c7}\x{1c8}\x{1c9} - 1: \x{1c7}\x{1c8} - 2: \x{1c7} /\x{01c8}+/8i \x{01c7}\x{01c8}\x{01c9} 0: \x{1c7}\x{1c8}\x{1c9} - 1: \x{1c7}\x{1c8} - 2: \x{1c7} /\x{01c9}+/8i \x{01c7}\x{01c8}\x{01c9} 0: \x{1c7}\x{1c8}\x{1c9} - 1: \x{1c7}\x{1c8} - 2: \x{1c7} /\x{01ca}+/8i \x{01ca}\x{01cb}\x{01cc} 0: \x{1ca}\x{1cb}\x{1cc} - 1: \x{1ca}\x{1cb} - 2: \x{1ca} /\x{01cb}+/8i \x{01ca}\x{01cb}\x{01cc} 0: \x{1ca}\x{1cb}\x{1cc} - 1: \x{1ca}\x{1cb} - 2: \x{1ca} /\x{01cc}+/8i \x{01ca}\x{01cb}\x{01cc} 0: \x{1ca}\x{1cb}\x{1cc} - 1: \x{1ca}\x{1cb} - 2: \x{1ca} /\x{01f1}+/8i \x{01f1}\x{01f2}\x{01f3} 0: \x{1f1}\x{1f2}\x{1f3} - 1: \x{1f1}\x{1f2} - 2: \x{1f1} /\x{01f2}+/8i \x{01f1}\x{01f2}\x{01f3} 0: \x{1f1}\x{1f2}\x{1f3} - 1: \x{1f1}\x{1f2} - 2: \x{1f1} /\x{01f3}+/8i \x{01f1}\x{01f2}\x{01f3} 0: \x{1f1}\x{1f2}\x{1f3} - 1: \x{1f1}\x{1f2} - 2: \x{1f1} /\x{0345}+/8i \x{0345}\x{0399}\x{03b9}\x{1fbe} 0: \x{345}\x{399}\x{3b9}\x{1fbe} - 1: \x{345}\x{399}\x{3b9} - 2: \x{345}\x{399} - 3: \x{345} /\x{0399}+/8i \x{0345}\x{0399}\x{03b9}\x{1fbe} 0: \x{345}\x{399}\x{3b9}\x{1fbe} - 1: \x{345}\x{399}\x{3b9} - 2: \x{345}\x{399} - 3: \x{345} /\x{03b9}+/8i \x{0345}\x{0399}\x{03b9}\x{1fbe} 0: \x{345}\x{399}\x{3b9}\x{1fbe} - 1: \x{345}\x{399}\x{3b9} - 2: \x{345}\x{399} - 3: \x{345} /\x{1fbe}+/8i \x{0345}\x{0399}\x{03b9}\x{1fbe} 0: \x{345}\x{399}\x{3b9}\x{1fbe} - 1: \x{345}\x{399}\x{3b9} - 2: \x{345}\x{399} - 3: \x{345} /\x{0392}+/8i \x{0392}\x{03b2}\x{03d0} 0: \x{392}\x{3b2}\x{3d0} - 1: \x{392}\x{3b2} - 2: \x{392} /\x{03b2}+/8i \x{0392}\x{03b2}\x{03d0} 0: \x{392}\x{3b2}\x{3d0} - 1: \x{392}\x{3b2} - 2: \x{392} /\x{03d0}+/8i \x{0392}\x{03b2}\x{03d0} 0: \x{392}\x{3b2}\x{3d0} - 1: \x{392}\x{3b2} - 2: \x{392} /\x{0395}+/8i \x{0395}\x{03b5}\x{03f5} 0: \x{395}\x{3b5}\x{3f5} - 1: \x{395}\x{3b5} - 2: \x{395} /\x{03b5}+/8i \x{0395}\x{03b5}\x{03f5} 0: \x{395}\x{3b5}\x{3f5} - 1: \x{395}\x{3b5} - 2: \x{395} /\x{03f5}+/8i \x{0395}\x{03b5}\x{03f5} 0: \x{395}\x{3b5}\x{3f5} - 1: \x{395}\x{3b5} - 2: \x{395} /\x{0398}+/8i \x{0398}\x{03b8}\x{03d1}\x{03f4} 0: \x{398}\x{3b8}\x{3d1}\x{3f4} - 1: \x{398}\x{3b8}\x{3d1} - 2: \x{398}\x{3b8} - 3: \x{398} /\x{03b8}+/8i \x{0398}\x{03b8}\x{03d1}\x{03f4} 0: \x{398}\x{3b8}\x{3d1}\x{3f4} - 1: \x{398}\x{3b8}\x{3d1} - 2: \x{398}\x{3b8} - 3: \x{398} /\x{03d1}+/8i \x{0398}\x{03b8}\x{03d1}\x{03f4} 0: \x{398}\x{3b8}\x{3d1}\x{3f4} - 1: \x{398}\x{3b8}\x{3d1} - 2: \x{398}\x{3b8} - 3: \x{398} /\x{03f4}+/8i \x{0398}\x{03b8}\x{03d1}\x{03f4} 0: \x{398}\x{3b8}\x{3d1}\x{3f4} - 1: \x{398}\x{3b8}\x{3d1} - 2: \x{398}\x{3b8} - 3: \x{398} /\x{039a}+/8i \x{039a}\x{03ba}\x{03f0} 0: \x{39a}\x{3ba}\x{3f0} - 1: \x{39a}\x{3ba} - 2: \x{39a} /\x{03ba}+/8i \x{039a}\x{03ba}\x{03f0} 0: \x{39a}\x{3ba}\x{3f0} - 1: \x{39a}\x{3ba} - 2: \x{39a} /\x{03f0}+/8i \x{039a}\x{03ba}\x{03f0} 0: \x{39a}\x{3ba}\x{3f0} - 1: \x{39a}\x{3ba} - 2: \x{39a} /\x{03a0}+/8i \x{03a0}\x{03c0}\x{03d6} 0: \x{3a0}\x{3c0}\x{3d6} - 1: \x{3a0}\x{3c0} - 2: \x{3a0} /\x{03c0}+/8i \x{03a0}\x{03c0}\x{03d6} 0: \x{3a0}\x{3c0}\x{3d6} - 1: \x{3a0}\x{3c0} - 2: \x{3a0} /\x{03d6}+/8i \x{03a0}\x{03c0}\x{03d6} 0: \x{3a0}\x{3c0}\x{3d6} - 1: \x{3a0}\x{3c0} - 2: \x{3a0} /\x{03a1}+/8i \x{03a1}\x{03c1}\x{03f1} 0: \x{3a1}\x{3c1}\x{3f1} - 1: \x{3a1}\x{3c1} - 2: \x{3a1} /\x{03c1}+/8i \x{03a1}\x{03c1}\x{03f1} 0: \x{3a1}\x{3c1}\x{3f1} - 1: \x{3a1}\x{3c1} - 2: \x{3a1} /\x{03f1}+/8i \x{03a1}\x{03c1}\x{03f1} 0: \x{3a1}\x{3c1}\x{3f1} - 1: \x{3a1}\x{3c1} - 2: \x{3a1} /\x{03a3}+/8i \x{03A3}\x{03C2}\x{03C3} 0: \x{3a3}\x{3c2}\x{3c3} - 1: \x{3a3}\x{3c2} - 2: \x{3a3} /\x{03c2}+/8i \x{03A3}\x{03C2}\x{03C3} 0: \x{3a3}\x{3c2}\x{3c3} - 1: \x{3a3}\x{3c2} - 2: \x{3a3} /\x{03c3}+/8i \x{03A3}\x{03C2}\x{03C3} 0: \x{3a3}\x{3c2}\x{3c3} - 1: \x{3a3}\x{3c2} - 2: \x{3a3} /\x{03a6}+/8i \x{03a6}\x{03c6}\x{03d5} 0: \x{3a6}\x{3c6}\x{3d5} - 1: \x{3a6}\x{3c6} - 2: \x{3a6} /\x{03c6}+/8i \x{03a6}\x{03c6}\x{03d5} 0: \x{3a6}\x{3c6}\x{3d5} - 1: \x{3a6}\x{3c6} - 2: \x{3a6} /\x{03d5}+/8i \x{03a6}\x{03c6}\x{03d5} 0: \x{3a6}\x{3c6}\x{3d5} - 1: \x{3a6}\x{3c6} - 2: \x{3a6} /\x{03c9}+/8i \x{03c9}\x{03a9}\x{2126} 0: \x{3c9}\x{3a9}\x{2126} - 1: \x{3c9}\x{3a9} - 2: \x{3c9} /\x{03a9}+/8i \x{03c9}\x{03a9}\x{2126} 0: \x{3c9}\x{3a9}\x{2126} - 1: \x{3c9}\x{3a9} - 2: \x{3c9} /\x{2126}+/8i \x{03c9}\x{03a9}\x{2126} 0: \x{3c9}\x{3a9}\x{2126} - 1: \x{3c9}\x{3a9} - 2: \x{3c9} /\x{1e60}+/8i \x{1e60}\x{1e61}\x{1e9b} 0: \x{1e60}\x{1e61}\x{1e9b} - 1: \x{1e60}\x{1e61} - 2: \x{1e60} /\x{1e61}+/8i \x{1e60}\x{1e61}\x{1e9b} 0: \x{1e60}\x{1e61}\x{1e9b} - 1: \x{1e60}\x{1e61} - 2: \x{1e60} /\x{1e9b}+/8i \x{1e60}\x{1e61}\x{1e9b} 0: \x{1e60}\x{1e61}\x{1e9b} - 1: \x{1e60}\x{1e61} - 2: \x{1e60} /\x{1e9e}+/8i \x{1e9e}\x{00df} 0: \x{1e9e}\x{df} - 1: \x{1e9e} /\x{00df}+/8i \x{1e9e}\x{00df} 0: \x{1e9e}\x{df} - 1: \x{1e9e} /\x{1f88}+/8i \x{1f88}\x{1f80} 0: \x{1f88}\x{1f80} - 1: \x{1f88} /\x{1f80}+/8i \x{1f88}\x{1f80} 0: \x{1f88}\x{1f80} - 1: \x{1f88} /\x{004b}+/8i \x{004b}\x{006b}\x{212a} 0: Kk\x{212a} - 1: Kk - 2: K /\x{006b}+/8i \x{004b}\x{006b}\x{212a} 0: Kk\x{212a} - 1: Kk - 2: K /\x{212a}+/8i \x{004b}\x{006b}\x{212a} 0: Kk\x{212a} - 1: Kk - 2: K /\x{0053}+/8i \x{0053}\x{0073}\x{017f} 0: Ss\x{17f} - 1: Ss - 2: S /\x{0073}+/8i \x{0053}\x{0073}\x{017f} 0: Ss\x{17f} - 1: Ss - 2: S /\x{017f}+/8i \x{0053}\x{0073}\x{017f} 0: Ss\x{17f} - 1: Ss - 2: S /ist/8i ikt @@ -2740,11 +2436,6 @@ No match /^\p{Xuc}+/8 $@`\x{a0}\x{1234}\x{e000}** 0: $@`\x{a0}\x{1234}\x{e000} - 1: $@`\x{a0}\x{1234} - 2: $@`\x{a0} - 3: $@` - 4: $@ - 5: $ ** Failers No match \x{9f} @@ -2782,8 +2473,6 @@ No match /^\p{Xuc}{3,5}/8 $@`\x{a0}\x{1234}\x{e000}** 0: $@`\x{a0}\x{1234} - 1: $@`\x{a0} - 2: $@` ** Failers No match \x{9f} @@ -2810,11 +2499,6 @@ No match /^[\p{Xuc}]+/8 $@`\x{a0}\x{1234}\x{e000}** 0: $@`\x{a0}\x{1234}\x{e000} - 1: $@`\x{a0}\x{1234} - 2: $@`\x{a0} - 3: $@` - 4: $@ - 5: $ ** Failers No match \x{9f} @@ -2848,4 +2532,16 @@ No match \x{1234}abc No match +/^A\s+Z/8W + A\x{2005}Z + 0: A\x{2005}Z + A\x{85}\x{180e}\x{2005}Z + 0: A\x{85}\x{180e}\x{2005}Z + +/^A[\s]+Z/8W + A\x{2005}Z + 0: A\x{2005}Z + A\x{85}\x{180e}\x{2005}Z + 0: A\x{85}\x{180e}\x{2005}Z + /-- End of testinput10 --/ diff --git a/pcre/testdata/testoutput11-16 b/pcre/testdata/testoutput11-16 index dff72b9477c..f1ad8887b4d 100644 --- a/pcre/testdata/testoutput11-16 +++ b/pcre/testdata/testoutput11-16 @@ -63,6 +63,7 @@ Memory allocation (code space): 10 4 End ------------------------------------------------------------------ Capturing subpattern count = 0 +May match empty string Options: extended No first char No need char @@ -99,15 +100,13 @@ Memory allocation (code space): 14 ------------------------------------------------------------------ /x{1,3}+/BM -Memory allocation (code space): 28 +Memory allocation (code space): 20 ------------------------------------------------------------------ - 0 11 Bra - 2 7 Once - 4 x - 6 x{0,2} - 9 7 Ket - 11 11 Ket - 13 End + 0 7 Bra + 2 x + 4 x{0,2}+ + 7 7 Ket + 9 End ------------------------------------------------------------------ /(x)*+/BM @@ -138,7 +137,7 @@ Memory allocation (code space): 142 39 [bc]+ 57 21 Ket 59 5 CBra 5 - 62 \w* + 62 \w*+ 64 5 Ket 66 63 Ket 68 68 Ket @@ -327,7 +326,7 @@ Memory allocation (code space): 16 ------------------------------------------------------------------ /\x{110000}/8BM -Failed: character value in \x{...} sequence is too large at offset 9 +Failed: character value in \x{} or \o{} is too large at offset 9 /[\x{ff}]/8BM Memory allocation (code space): 14 @@ -503,7 +502,7 @@ Memory allocation (code space): 24 Memory allocation (code space): 58 ------------------------------------------------------------------ 0 26 Bra - 2 [+\-\p{Nd}]+ + 2 [+\-\p{Nd}]++ 26 26 Ket 28 End ------------------------------------------------------------------ @@ -652,7 +651,7 @@ Memory allocation (code space): 14 /[[:^alpha:][:^cntrl:]]+/8WB ------------------------------------------------------------------ 0 26 Bra - 2 [ -~\x80-\xff\P{L}]+ + 2 [ -~\x80-\xff\P{L}]++ 26 26 Ket 28 End ------------------------------------------------------------------ @@ -660,7 +659,7 @@ Memory allocation (code space): 14 /[[:^cntrl:][:^alpha:]]+/8WB ------------------------------------------------------------------ 0 26 Bra - 2 [ -~\x80-\xff\P{L}]+ + 2 [ -~\x80-\xff\P{L}]++ 26 26 Ket 28 End ------------------------------------------------------------------ @@ -668,7 +667,7 @@ Memory allocation (code space): 14 /[[:alpha:]]+/8WB ------------------------------------------------------------------ 0 10 Bra - 2 [\p{L}]+ + 2 [\p{L}]++ 10 10 Ket 12 End ------------------------------------------------------------------ @@ -676,7 +675,7 @@ Memory allocation (code space): 14 /[[:^alpha:]\S]+/8WB ------------------------------------------------------------------ 0 13 Bra - 2 [\P{L}\P{Xsp}]+ + 2 [\P{L}\P{Xsp}]++ 13 13 Ket 15 End ------------------------------------------------------------------ diff --git a/pcre/testdata/testoutput11-32 b/pcre/testdata/testoutput11-32 index 8335fb82418..266e55d0672 100644 --- a/pcre/testdata/testoutput11-32 +++ b/pcre/testdata/testoutput11-32 @@ -63,6 +63,7 @@ Memory allocation (code space): 20 4 End ------------------------------------------------------------------ Capturing subpattern count = 0 +May match empty string Options: extended No first char No need char @@ -99,15 +100,13 @@ Memory allocation (code space): 28 ------------------------------------------------------------------ /x{1,3}+/BM -Memory allocation (code space): 56 +Memory allocation (code space): 40 ------------------------------------------------------------------ - 0 11 Bra - 2 7 Once - 4 x - 6 x{0,2} - 9 7 Ket - 11 11 Ket - 13 End + 0 7 Bra + 2 x + 4 x{0,2}+ + 7 7 Ket + 9 End ------------------------------------------------------------------ /(x)*+/BM @@ -138,7 +137,7 @@ Memory allocation (code space): 220 31 [bc]+ 41 13 Ket 43 5 CBra 5 - 46 \w* + 46 \w*+ 48 5 Ket 50 47 Ket 52 52 Ket @@ -327,7 +326,7 @@ Memory allocation (code space): 28 ------------------------------------------------------------------ /\x{110000}/8BM -Failed: character value in \x{...} sequence is too large at offset 9 +Failed: character value in \x{} or \o{} is too large at offset 9 /[\x{ff}]/8BM Memory allocation (code space): 28 @@ -503,7 +502,7 @@ Memory allocation (code space): 48 Memory allocation (code space): 84 ------------------------------------------------------------------ 0 18 Bra - 2 [+\-\p{Nd}]+ + 2 [+\-\p{Nd}]++ 18 18 Ket 20 End ------------------------------------------------------------------ @@ -652,7 +651,7 @@ Memory allocation (code space): 28 /[[:^alpha:][:^cntrl:]]+/8WB ------------------------------------------------------------------ 0 18 Bra - 2 [ -~\x80-\xff\P{L}]+ + 2 [ -~\x80-\xff\P{L}]++ 18 18 Ket 20 End ------------------------------------------------------------------ @@ -660,7 +659,7 @@ Memory allocation (code space): 28 /[[:^cntrl:][:^alpha:]]+/8WB ------------------------------------------------------------------ 0 18 Bra - 2 [ -~\x80-\xff\P{L}]+ + 2 [ -~\x80-\xff\P{L}]++ 18 18 Ket 20 End ------------------------------------------------------------------ @@ -668,7 +667,7 @@ Memory allocation (code space): 28 /[[:alpha:]]+/8WB ------------------------------------------------------------------ 0 10 Bra - 2 [\p{L}]+ + 2 [\p{L}]++ 10 10 Ket 12 End ------------------------------------------------------------------ @@ -676,7 +675,7 @@ Memory allocation (code space): 28 /[[:^alpha:]\S]+/8WB ------------------------------------------------------------------ 0 13 Bra - 2 [\P{L}\P{Xsp}]+ + 2 [\P{L}\P{Xsp}]++ 13 13 Ket 15 End ------------------------------------------------------------------ diff --git a/pcre/testdata/testoutput11-8 b/pcre/testdata/testoutput11-8 index c1c85f9a3b6..d4a21334e36 100644 --- a/pcre/testdata/testoutput11-8 +++ b/pcre/testdata/testoutput11-8 @@ -63,6 +63,7 @@ Memory allocation (code space): 7 6 End ------------------------------------------------------------------ Capturing subpattern count = 0 +May match empty string Options: extended No first char No need char @@ -99,15 +100,13 @@ Memory allocation (code space): 9 ------------------------------------------------------------------ /x{1,3}+/BM -Memory allocation (code space): 19 +Memory allocation (code space): 13 ------------------------------------------------------------------ - 0 15 Bra - 3 9 Once - 6 x - 8 x{0,2} - 12 9 Ket - 15 15 Ket - 18 End + 0 9 Bra + 3 x + 5 x{0,2}+ + 9 9 Ket + 12 End ------------------------------------------------------------------ /(x)*+/BM @@ -138,7 +137,7 @@ Memory allocation (code space): 120 66 [bc]+ 100 39 Ket 103 7 CBra 5 -108 \w* +108 \w*+ 110 7 Ket 113 109 Ket 116 116 Ket @@ -327,7 +326,7 @@ Memory allocation (code space): 12 ------------------------------------------------------------------ /\x{110000}/8BM -Failed: character value in \x{...} sequence is too large at offset 9 +Failed: character value in \x{} or \o{} is too large at offset 9 /[\x{ff}]/8BM Memory allocation (code space): 10 @@ -503,7 +502,7 @@ Memory allocation (code space): 15 Memory allocation (code space): 48 ------------------------------------------------------------------ 0 44 Bra - 3 [+\-\p{Nd}]+ + 3 [+\-\p{Nd}]++ 44 44 Ket 47 End ------------------------------------------------------------------ @@ -652,7 +651,7 @@ Memory allocation (code space): 10 /[[:^alpha:][:^cntrl:]]+/8WB ------------------------------------------------------------------ 0 44 Bra - 3 [ -~\x80-\xff\P{L}]+ + 3 [ -~\x80-\xff\P{L}]++ 44 44 Ket 47 End ------------------------------------------------------------------ @@ -660,7 +659,7 @@ Memory allocation (code space): 10 /[[:^cntrl:][:^alpha:]]+/8WB ------------------------------------------------------------------ 0 44 Bra - 3 [ -~\x80-\xff\P{L}]+ + 3 [ -~\x80-\xff\P{L}]++ 44 44 Ket 47 End ------------------------------------------------------------------ @@ -668,7 +667,7 @@ Memory allocation (code space): 10 /[[:alpha:]]+/8WB ------------------------------------------------------------------ 0 12 Bra - 3 [\p{L}]+ + 3 [\p{L}]++ 12 12 Ket 15 End ------------------------------------------------------------------ @@ -676,7 +675,7 @@ Memory allocation (code space): 10 /[[:^alpha:]\S]+/8WB ------------------------------------------------------------------ 0 15 Bra - 3 [\P{L}\P{Xsp}]+ + 3 [\P{L}\P{Xsp}]++ 15 15 Ket 18 End ------------------------------------------------------------------ diff --git a/pcre/testdata/testoutput12 b/pcre/testdata/testoutput12 index 6c986d1185d..a76e2aef880 100644 --- a/pcre/testdata/testoutput12 +++ b/pcre/testdata/testoutput12 @@ -13,16 +13,18 @@ JIT study was successful /(?(?C1)(?=a)a)/S+I Capturing subpattern count = 0 +May match empty string No options -First char = 'a' +No first char No need char Study returned NULL JIT study was not successful /(?(?C1)(?=a)a)/S!+I Capturing subpattern count = 0 +May match empty string No options -First char = 'a' +No first char No need char Subject length lower bound = -1 No set of starting bytes @@ -47,6 +49,7 @@ Study data loaded from testsavedregex /a*/SI Capturing subpattern count = 0 +May match empty string No options No first char No need char diff --git a/pcre/testdata/testoutput13 b/pcre/testdata/testoutput13 index e9cbbcf0a2b..9f73c5000f6 100644 --- a/pcre/testdata/testoutput13 +++ b/pcre/testdata/testoutput13 @@ -13,6 +13,7 @@ JIT support is not available in this version of PCRE /a*/SI Capturing subpattern count = 0 +May match empty string No options No first char No need char diff --git a/pcre/testdata/testoutput14 b/pcre/testdata/testoutput14 index 5f05d77d24e..52680a8f9cd 100644 --- a/pcre/testdata/testoutput14 +++ b/pcre/testdata/testoutput14 @@ -1,6 +1,9 @@ -/-- This set of tests is run only with the 8-bit library. It starts with all - the tests of the POSIX interface, because that is supported only with the - 8-bit library. --/ +/-- This set of tests is run only with the 8-bit library. They do not require + UTF-8 or Unicode property support. The file starts with all the tests of + the POSIX interface, because that is supported only with the 8-bit library. + --/ + +< forbid 8W /abc/P abc @@ -147,9 +150,16 @@ No match ** Character \x{123} is greater than 255 and UTF-8 mode is not enabled. ** Truncation will probably give the wrong result. No match + A\o{443}B +** Character \x{123} is greater than 255 and UTF-8 mode is not enabled. +** Truncation will probably give the wrong result. +No match /\x{100}/I -Failed: character value in \x{...} sequence is too large at offset 6 +Failed: character value in \x{} or \o{} is too large at offset 6 + +/\o{400}/I +Failed: character value in \x{} or \o{} is too large at offset 6 / (?: [\040\t] | \( (?: [^\\\x80-\xff\n\015()] | \\ [^\x80-\xff] | \( (?: [^\\\x80-\xff\n\015()] | \\ [^\x80-\xff] )* \) )* @@ -380,6 +390,14 @@ No need char Subject length lower bound = 1 Starting byte set: \x09 \x20 \xa0 +/\H/SI +Capturing subpattern count = 0 +No options +No first char +No need char +Subject length lower bound = 1 +No set of starting bytes + /\v/SI Capturing subpattern count = 0 No options @@ -388,6 +406,14 @@ No need char Subject length lower bound = 1 Starting byte set: \x0a \x0b \x0c \x0d \x85 +/\V/SI +Capturing subpattern count = 0 +No options +No first char +No need char +Subject length lower bound = 1 +No set of starting bytes + /\R/SI Capturing subpattern count = 0 No options @@ -409,7 +435,7 @@ Starting byte set: \x0a \x0b \x0c \x0d \x85 /[\h]+/BZ ------------------------------------------------------------------ Bra - [\x09 \xa0]+ + [\x09 \xa0]++ Ket End ------------------------------------------------------------------ @@ -473,4 +499,32 @@ Failed: character value in \u.... sequence is too large at offset 5 /[\u0100-\u0200]/<JS> Failed: character value in \u.... sequence is too large at offset 6 +/[^\x00-a]{12,}[^b-\xff]*/BZ +------------------------------------------------------------------ + Bra + [b-\xff] (neg){12,}+ + [\x00-a] (neg)*+ + Ket + End +------------------------------------------------------------------ + +/[^\s]*\s* [^\W]+\W+ [^\d]*?\d0 [^\d\w]{4,6}?\w*A/BZ +------------------------------------------------------------------ + Bra + [\x00-\x08\x0e-\x1f!-\xff] (neg)*+ + \s* + + [0-9A-Z_a-z]++ + \W+ + + [\x00-/:-\xff] (neg)*+ + \d + 0 + [\x00-/:-@[-^`{-\xff] (neg){4,6}+ + \w* + A + Ket + End +------------------------------------------------------------------ + /-- End of testinput14 --/ diff --git a/pcre/testdata/testoutput15 b/pcre/testdata/testoutput15 index 1541637de8d..5792be72df7 100644 --- a/pcre/testdata/testoutput15 +++ b/pcre/testdata/testoutput15 @@ -1,5 +1,7 @@ -/-- This set of tests is for UTF-8 support, and is relevant only to the 8-bit - library. --/ +/-- This set of tests is for UTF-8 support but not Unicode property support, + and is relevant only to the 8-bit library. --/ + +< forbid W /X(\C{3})/8 X\x{1234} @@ -72,7 +74,7 @@ Failed: invalid UTF-8 string at offset 0 /ÃÃÃxxx/8 Failed: invalid UTF-8 string at offset 0 -/ÃÃÃxxx/8?DZSS +/ÃÃÃxxx/8?DZSSO ------------------------------------------------------------------ Bra \X{c0}\X{c0}\X{c0}xxx @@ -80,7 +82,7 @@ Failed: invalid UTF-8 string at offset 0 End ------------------------------------------------------------------ Capturing subpattern count = 0 -Options: utf no_utf_check +Options: no_auto_possessify utf no_utf_check First char = \x{c3} Need char = 'x' @@ -508,7 +510,7 @@ No match ------------------------------------------------------------------ Bra \x{100}{3} - \x{100}? + \x{100}?+ Ket End ------------------------------------------------------------------ @@ -525,7 +527,7 @@ No set of starting bytes ------------------------------------------------------------------ Bra CBra 1 - \x{100}+ + \x{100}++ Alt x Ket @@ -562,7 +564,7 @@ Starting byte set: a x \xc4 ------------------------------------------------------------------ Bra CBra 1 - \x{100}{0,2} + \x{100}{0,2}+ a Alt x @@ -582,7 +584,7 @@ Starting byte set: a x \xc4 Bra CBra 1 \x{100} - \x{100}{0,1} + \x{100}{0,1}+ a Alt x @@ -613,7 +615,7 @@ Need char = \x{80} ------------------------------------------------------------------ Bra a\x{100} - \x{101}* + \x{101}*+ Ket End ------------------------------------------------------------------ @@ -626,7 +628,7 @@ Need char = \x{80} ------------------------------------------------------------------ Bra a\x{100} - \x{101}+ + \x{101}++ Ket End ------------------------------------------------------------------ @@ -861,7 +863,7 @@ Options: utf No first char Need char = 'x' Subject length lower bound = 4 -Starting byte set: \x09 \x0a \x0c \x0d \x20 x +Starting byte set: \x09 \x0a \x0b \x0c \x0d \x20 x /\sxxx\s/I8ST1 Capturing subpattern count = 0 diff --git a/pcre/testdata/testoutput17 b/pcre/testdata/testoutput17 index ef82dc9d0d8..9a469c51ae1 100644 --- a/pcre/testdata/testoutput17 +++ b/pcre/testdata/testoutput17 @@ -1,6 +1,8 @@ /-- This set of tests is for the 16- and 32-bit library's basic (non-UTF-16 or -32) features that are not compatible with the 8-bit library, or which give different output in 16- or 32-bit mode. --/ + +< forbid 8W /a\Cb/ aXb @@ -243,7 +245,7 @@ Starting byte set: \x09 \x20 ! " # $ % & ' ( * + - / 0 1 2 3 4 5 6 7 8 /[\h]+/BZ ------------------------------------------------------------------ Bra - [\x09 \xa0\x{1680}\x{180e}\x{2000}-\x{200a}\x{202f}\x{205f}\x{3000}]+ + [\x09 \xa0\x{1680}\x{180e}\x{2000}-\x{200a}\x{202f}\x{205f}\x{3000}]++ Ket End ------------------------------------------------------------------ @@ -281,7 +283,7 @@ Starting byte set: \x09 \x20 \xa0 \xff /[\h\x{dc00}]+/BZSI ------------------------------------------------------------------ Bra - [\x09 \xa0\x{1680}\x{180e}\x{2000}-\x{200a}\x{202f}\x{205f}\x{3000}\x{dc00}]+ + [\x09 \xa0\x{1680}\x{180e}\x{2000}-\x{200a}\x{202f}\x{205f}\x{3000}\x{dc00}]++ Ket End ------------------------------------------------------------------ @@ -337,7 +339,7 @@ Starting byte set: \x0a \x0b \x0c \x0d \x85 \xff /[\v\x{dc00}]+/BZSI ------------------------------------------------------------------ Bra - [\x0a-\x0d\x85\x{2028}-\x{2029}\x{dc00}]+ + [\x0a-\x0d\x85\x{2028}-\x{2029}\x{dc00}]++ Ket End ------------------------------------------------------------------ @@ -440,10 +442,8 @@ Need char = \x{dd00} /i [^\x{8000}]* /i [^\x{7fff}]{2} /i [^\x{7fff}]{0,7}? - Once /i [^\x{100}]{5} - /i [^\x{100}]? - Ket + /i [^\x{100}]?+ Ket End ------------------------------------------------------------------ @@ -502,4 +502,57 @@ MK: 0123456789ABCDEF0123456789ABCDEF0123456789ABCDEF0123456789ABCDEF0123456789AB \x{ffff} 0: \x{ffff} +/[^\x00-a]{12,}[^b-\xff]*/BZ +------------------------------------------------------------------ + Bra + [b-\xff] (neg){12,} + [\x00-a] (neg)*+ + Ket + End +------------------------------------------------------------------ + +/[^\s]*\s* [^\W]+\W+ [^\d]*?\d0 [^\d\w]{4,6}?\w*A/BZ +------------------------------------------------------------------ + Bra + [\x00-\x08\x0e-\x1f!-\xff] (neg)* + \s* + + [0-9A-Z_a-z]++ + \W+ + + [\x00-/:-\xff] (neg)*? + \d + 0 + [\x00-/:-@[-^`{-\xff] (neg){4,6}? + \w* + A + Ket + End +------------------------------------------------------------------ + +/a*[b-\x{200}]?a#a*[b-\x{200}]?b#[a-f]*[g-\x{200}]*#[g-\x{200}]*[a-c]*#[g-\x{200}]*[a-h]*/BZ +------------------------------------------------------------------ + Bra + a* + [b-\x{200}]?+ + a# + a*+ + [b-\x{200}]? + b# + [a-f]* + [g-\x{200}]*+ + # + [g-\x{200}]* + [a-c]*+ + # + [g-\x{200}]* + [a-h]*+ + Ket + End +------------------------------------------------------------------ + +/^[\x{1234}\x{4321}]{2,4}?/ + \x{1234}\x{1234}\x{1234} + 0: \x{1234}\x{1234} + /-- End of testinput17 --/ diff --git a/pcre/testdata/testoutput18-16 b/pcre/testdata/testoutput18-16 index 3414a661808..1ca9ee74018 100644 --- a/pcre/testdata/testoutput18-16 +++ b/pcre/testdata/testoutput18-16 @@ -1,5 +1,7 @@ -/-- This set of tests is for UTF-16 and UTF-32 support, and is relevant only to the - 16- and 32-bit library. --/ +/-- This set of tests is for UTF-16 and UTF-32 support, and is relevant only to + the 16- and 32-bit libraries. --/ + +< forbid W /ÃÃÃxxx/8?DZSS **Failed: invalid UTF-8 string cannot be converted to UTF-16 @@ -367,7 +369,7 @@ No match ------------------------------------------------------------------ Bra \x{100}{3} - \x{100}? + \x{100}?+ Ket End ------------------------------------------------------------------ @@ -384,7 +386,7 @@ No set of starting bytes ------------------------------------------------------------------ Bra CBra 1 - \x{100}+ + \x{100}++ Alt x Ket @@ -421,7 +423,7 @@ Starting byte set: a x \xff ------------------------------------------------------------------ Bra CBra 1 - \x{100}{0,2} + \x{100}{0,2}+ a Alt x @@ -441,7 +443,7 @@ Starting byte set: a x \xff Bra CBra 1 \x{100} - \x{100}{0,1} + \x{100}{0,1}+ a Alt x @@ -472,7 +474,7 @@ No need char ------------------------------------------------------------------ Bra a\x{100} - \x{101}* + \x{101}*+ Ket End ------------------------------------------------------------------ @@ -485,7 +487,7 @@ Need char = \x{100} ------------------------------------------------------------------ Bra a\x{100} - \x{101}+ + \x{101}++ Ket End ------------------------------------------------------------------ @@ -742,7 +744,7 @@ Options: utf No first char Need char = 'x' Subject length lower bound = 4 -Starting byte set: \x09 \x0a \x0c \x0d \x20 x +Starting byte set: \x09 \x0a \x0b \x0c \x0d \x20 x /\sxxx\s/I8ST1 Capturing subpattern count = 0 diff --git a/pcre/testdata/testoutput18-32 b/pcre/testdata/testoutput18-32 index e917e3baec4..89be3a4b051 100644 --- a/pcre/testdata/testoutput18-32 +++ b/pcre/testdata/testoutput18-32 @@ -1,5 +1,7 @@ -/-- This set of tests is for UTF-16 and UTF-32 support, and is relevant only to the - 16- and 32-bit library. --/ +/-- This set of tests is for UTF-16 and UTF-32 support, and is relevant only to + the 16- and 32-bit libraries. --/ + +< forbid W /ÃÃÃxxx/8?DZSS **Failed: invalid UTF-8 string cannot be converted to UTF-32 @@ -365,7 +367,7 @@ No match ------------------------------------------------------------------ Bra \x{100}{3} - \x{100}? + \x{100}?+ Ket End ------------------------------------------------------------------ @@ -382,7 +384,7 @@ No set of starting bytes ------------------------------------------------------------------ Bra CBra 1 - \x{100}+ + \x{100}++ Alt x Ket @@ -419,7 +421,7 @@ Starting byte set: a x \xff ------------------------------------------------------------------ Bra CBra 1 - \x{100}{0,2} + \x{100}{0,2}+ a Alt x @@ -439,7 +441,7 @@ Starting byte set: a x \xff Bra CBra 1 \x{100} - \x{100}{0,1} + \x{100}{0,1}+ a Alt x @@ -470,7 +472,7 @@ No need char ------------------------------------------------------------------ Bra a\x{100} - \x{101}* + \x{101}*+ Ket End ------------------------------------------------------------------ @@ -483,7 +485,7 @@ Need char = \x{100} ------------------------------------------------------------------ Bra a\x{100} - \x{101}+ + \x{101}++ Ket End ------------------------------------------------------------------ @@ -739,7 +741,7 @@ Options: utf No first char Need char = 'x' Subject length lower bound = 4 -Starting byte set: \x09 \x0a \x0c \x0d \x20 x +Starting byte set: \x09 \x0a \x0b \x0c \x0d \x20 x /\sxxx\s/I8ST1 Capturing subpattern count = 0 diff --git a/pcre/testdata/testoutput2 b/pcre/testdata/testoutput2 index fd958c2eb7e..844497abcdc 100644 --- a/pcre/testdata/testoutput2 +++ b/pcre/testdata/testoutput2 @@ -7,9 +7,12 @@ NOTE: This is a non-UTF set of tests. When UTF support is needed, use test 5, and if Unicode Property Support is needed, use test 7. --/ + +< forbid 8W /(a)b|/I Capturing subpattern count = 1 +May match empty string No options No first char No need char @@ -228,7 +231,7 @@ No options No first char No need char Subject length lower bound = 1 -Starting byte set: \x09 \x0a \x0c \x0d \x20 a b +Starting byte set: \x09 \x0a \x0b \x0c \x0d \x20 a b /(ab\2)/ Failed: reference to non-existent subpattern at offset 6 @@ -498,6 +501,7 @@ No need char /(?s).*/I Capturing subpattern count = 0 +May match empty string Options: anchored dotall No first char No need char @@ -545,10 +549,10 @@ Failed: conditional group contains more than two branches at offset 13 Failed: conditional group contains more than two branches at offset 12 /(?(1a)/ -Failed: missing ) at offset 6 +Failed: malformed number or name after (?( at offset 4 /(?(1a))/ -Failed: reference to non-existent subpattern at offset 6 +Failed: malformed number or name after (?( at offset 4 /(?(?i))/ Failed: assertion expected after (?( at offset 3 @@ -762,6 +766,7 @@ No match /(?<=ab(?i)x|y|z)/I Capturing subpattern count = 0 Max lookbehind = 3 +May match empty string No options No first char No need char @@ -769,6 +774,7 @@ No need char /(?>.*)(?<=(abcd)|(xyz))/I Capturing subpattern count = 2 Max lookbehind = 4 +May match empty string No options No first char No need char @@ -1377,6 +1383,7 @@ Need char = 'c' /a*/I Capturing subpattern count = 0 +May match empty string No options No first char No need char @@ -1395,6 +1402,7 @@ Need char = 'a' /a{0,3}/I Capturing subpattern count = 0 +May match empty string No options No first char No need char @@ -1594,6 +1602,7 @@ Need char = 'e' /a?b?/I Capturing subpattern count = 0 +May match empty string No options No first char No need char @@ -1612,6 +1621,7 @@ No match /|-/I Capturing subpattern count = 0 +May match empty string No options No first char No need char @@ -2625,6 +2635,7 @@ Need char = '-' End ------------------------------------------------------------------ Capturing subpattern count = 0 +May match empty string Options: extended No first char No need char @@ -2644,7 +2655,7 @@ No need char /[\s]/DZ ------------------------------------------------------------------ Bra - [\x09\x0a\x0c\x0d ] + [\x09-\x0d ] Ket End ------------------------------------------------------------------ @@ -2656,7 +2667,7 @@ No need char /[\S]/DZ ------------------------------------------------------------------ Bra - [\x00-\x08\x0b\x0e-\x1f!-\xff] (neg) + [\x00-\x08\x0e-\x1f!-\xff] (neg) Ket End ------------------------------------------------------------------ @@ -2767,6 +2778,7 @@ Need char = '0' End ------------------------------------------------------------------ Capturing subpattern count = 0 +May match empty string No options No first char No need char @@ -2866,6 +2878,7 @@ No match End ------------------------------------------------------------------ Capturing subpattern count = 0 +May match empty string No options No first char No need char @@ -2882,20 +2895,41 @@ No options First char = 'x' No need char -/x{1,3}+/DZ +/x{1,3}+/BZO ------------------------------------------------------------------ Bra - Once x - x{0,2} + x{0,2}+ Ket + End +------------------------------------------------------------------ + +/x{1,3}+/BZOi +------------------------------------------------------------------ + Bra + /i x + /i x{0,2}+ + Ket + End +------------------------------------------------------------------ + +/[^x]{1,3}+/BZO +------------------------------------------------------------------ + Bra + [^x] + [^x]{0,2}+ + Ket + End +------------------------------------------------------------------ + +/[^x]{1,3}+/BZOi +------------------------------------------------------------------ + Bra + /i [^x] + /i [^x]{0,2}+ Ket End ------------------------------------------------------------------ -Capturing subpattern count = 0 -No options -First char = 'x' -No need char /(x)*+/DZ ------------------------------------------------------------------ @@ -2908,12 +2942,14 @@ No need char End ------------------------------------------------------------------ Capturing subpattern count = 1 +May match empty string No options No first char No need char /^(\w++|\s++)*$/I Capturing subpattern count = 1 +May match empty string Options: anchored No first char No need char @@ -3075,7 +3111,7 @@ Need char = 'b' [bc]+ Ket CBra 5 - \w* + \w*+ Ket Ket Ket @@ -3154,7 +3190,7 @@ Failed: missing terminating ] for character class at offset 10 /[\s]/IDZ ------------------------------------------------------------------ Bra - [\x09\x0a\x0c\x0d ] + [\x09-\x0d ] Ket End ------------------------------------------------------------------ @@ -3289,6 +3325,7 @@ Need char = 'b' /(?=a).*/I Capturing subpattern count = 0 +May match empty string No options First char = 'a' No need char @@ -3307,6 +3344,7 @@ Need char = 'z' (caseless) /(?=a)(?=b)/I Capturing subpattern count = 0 +May match empty string No options First char = 'a' No need char @@ -3373,6 +3411,7 @@ Need char = 'a' /(a)*/I Capturing subpattern count = 1 +May match empty string No options No first char No need char @@ -3601,6 +3640,7 @@ No match /(?C0)(abc(?C1))*/I Capturing subpattern count = 1 +May match empty string No options No first char No need char @@ -3634,6 +3674,7 @@ No need char /(\d{3}(?C))*/I Capturing subpattern count = 1 +May match empty string No options No first char No need char @@ -3770,20 +3811,6 @@ Need char = 'b' --->abbbbbccc 1 ^ ^ Callout data = 1 - 1 ^ ^ -Callout data = 1 - 1 ^ ^ -Callout data = 1 - 1 ^ ^ -Callout data = 1 - 1 ^ ^ -Callout data = 1 - 1 ^ ^ -Callout data = 1 - 1 ^ ^ -Callout data = 1 - 1 ^ ^ -Callout data = 1 No match /a(b+?)(c*?)(?C1)/I @@ -3880,6 +3907,7 @@ Failed: recursive call could loop indefinitely at offset 16 /^([^()]|\((?1)*\))*$/I Capturing subpattern count = 1 +May match empty string Options: anchored No first char No need char @@ -4159,6 +4187,7 @@ Named capturing subpatterns: one 1 three 3 two 2 +May match empty string Options: anchored caseless No first char No need char @@ -4258,6 +4287,7 @@ Need char = 'z' /(.*)|(.*)|(.*)|(.*)|(.*)|(.*)|(.*)|(.*)|(.*)|(.*)|(.*)|(.*)|(.*)|(.*)|(.*)|(.*)|(.*)|(.*)|(.*)|(.*)|(.*)|(.*)|(.*)|(.*)|(.*)|(.*)|(.*)|(.*)|(.*)|(.*)|(.*)a/Is Capturing subpattern count = 31 +May match empty string Options: anchored dotall No first char No need char @@ -4265,6 +4295,7 @@ No need char /(.*)|(.*)|(.*)|(.*)|(.*)|(.*)|(.*)|(.*)|(.*)|(.*)|(.*)|(.*)|(.*)|(.*)|(.*)|(.*)|(.*)|(.*)|(.*)|(.*)|(.*)|(.*)|(.*)|(.*)|(.*)|(.*)|(.*)|(.*)|(.*)|(.*)|(.*)a\31/Is Capturing subpattern count = 31 Max back reference = 31 +May match empty string Options: dotall No first char No need char @@ -4272,6 +4303,7 @@ No need char /(.*)|(.*)|(.*)|(.*)|(.*)|(.*)|(.*)|(.*)|(.*)|(.*)|(.*)|(.*)|(.*)|(.*)|(.*)|(.*)|(.*)|(.*)|(.*)|(.*)|(.*)|(.*)|(.*)|(.*)|(.*)|(.*)|(.*)|(.*)|(.*)|(.*)|(.*)|(.*)a\32/Is Capturing subpattern count = 32 Max back reference = 32 +May match empty string Options: dotall No first char No need char @@ -4423,6 +4455,7 @@ Capturing subpattern count = 2 Named capturing subpatterns: Tes 1 Test 2 +May match empty string No options No first char No need char @@ -4441,6 +4474,7 @@ Capturing subpattern count = 2 Named capturing subpatterns: Tes 2 Test 1 +May match empty string No options No first char No need char @@ -4518,6 +4552,7 @@ Need char = ']' End ------------------------------------------------------------------ Capturing subpattern count = 2 +May match empty string No options No first char No need char @@ -4538,6 +4573,7 @@ No need char End ------------------------------------------------------------------ Capturing subpattern count = 2 +May match empty string No options No first char No need char @@ -4569,6 +4605,7 @@ No need char End ------------------------------------------------------------------ Capturing subpattern count = 2 +May match empty string No options No first char No need char @@ -4576,9 +4613,7 @@ No need char /[ab]{1}+/DZ ------------------------------------------------------------------ Bra - Once - [ab]{1,1} - Ket + [ab]{1,1}+ Ket End ------------------------------------------------------------------ @@ -5290,7 +5325,7 @@ No match Callout 255 0 21 CBra 1 Callout 255 1 9 - [ab]{1,4} + [ab]{1,4}+ Callout 255 10 1 c Callout 255 11 0 @@ -5303,7 +5338,7 @@ No match Ket CBra 1 Callout 255 1 9 - [ab]{1,4} + [ab]{1,4}+ Callout 255 10 1 c Callout 255 11 0 @@ -5316,7 +5351,7 @@ No match Ket CBra 1 Callout 255 1 9 - [ab]{1,4} + [ab]{1,4}+ Callout 255 10 1 c Callout 255 11 0 @@ -5329,7 +5364,7 @@ No match Ket CBra 1 Callout 255 1 9 - [ab]{1,4} + [ab]{1,4}+ Callout 255 10 1 c Callout 255 11 0 @@ -5343,7 +5378,7 @@ No match Braminzero CBra 1 Callout 255 1 9 - [ab]{1,4} + [ab]{1,4}+ Callout 255 10 1 c Callout 255 11 0 @@ -5397,6 +5432,7 @@ Need char = '3' /\b.*/I Capturing subpattern count = 0 Max lookbehind = 1 +May match empty string No options No first char No need char @@ -5406,6 +5442,7 @@ No need char /\b.*/Is Capturing subpattern count = 0 Max lookbehind = 1 +May match empty string Options: dotall No first char No need char @@ -5414,6 +5451,7 @@ No need char /(?!.bcd).*/I Capturing subpattern count = 0 +May match empty string No options No first char No need char @@ -6002,6 +6040,7 @@ Matched, but too many substrings /[^()]*(?:\((?R)\)[^()]*)*/I Capturing subpattern count = 0 +May match empty string No options No first char No need char @@ -6014,6 +6053,7 @@ No need char /[^()]*(?:\((?>(?R))\)[^()]*)*/I Capturing subpattern count = 0 +May match empty string No options No first char No need char @@ -6024,6 +6064,7 @@ No need char /[^()]*(?:\((?R)\))*[^()]*/I Capturing subpattern count = 0 +May match empty string No options No first char No need char @@ -6034,6 +6075,7 @@ No need char /(?:\((?R)\))*[^()]*/I Capturing subpattern count = 0 +May match empty string No options No first char No need char @@ -6046,6 +6088,7 @@ No need char /(?:\((?R)\))|[^()]*/I Capturing subpattern count = 0 +May match empty string No options No first char No need char @@ -6095,6 +6138,17 @@ no parentheses with name "Z" 2: a1 copy substring Z failed -7 C a1 (2) A + +/(?|(?<a>)(?<b>)(?<a>)|(?<a>)(?<b>)(?<a>))/IJ +Capturing subpattern count = 3 +Named capturing subpatterns: + a 1 + a 3 + b 2 +May match empty string +Options: dupnames +No first char +No need char /^(?P<A>a)(?P<A>b)/IJ Capturing subpattern count = 2 @@ -6305,7 +6359,7 @@ Need char = 'X' 1: X /(?:(?(2y)a|b)(X))+/I -Failed: reference to non-existent subpattern at offset 9 +Failed: malformed number or name after (?( at offset 7 /(?:(?(ZA)a|b)(?P<ZZ>X))+/I Failed: reference to non-existent subpattern at offset 9 @@ -6377,9 +6431,9 @@ No options No first char Need char = ',' Subject length lower bound = 1 -Starting byte set: \x09 \x0a \x0c \x0d \x20 , +Starting byte set: \x09 \x0a \x0b \x0c \x0d \x20 , \x0b,\x0b - 0: , + 0: \x0b,\x0b \x0c,\x0d 0: \x0c,\x0d @@ -6488,7 +6542,7 @@ No match No match /^abc/Im<bad> -Unknown newline type at: <bad> +Unknown modifier at: <bad> /abc/I @@ -6497,12 +6551,13 @@ No options First char = 'a' Need char = 'c' xyz\rabc\<bad> -Unknown newline type at: <bad> +Unknown escape sequence at: <bad> abc 0: abc /.*/I<lf> Capturing subpattern count = 0 +May match empty string Options: Forced newline sequence: LF First char at start or follows newline @@ -6544,6 +6599,7 @@ Need char = 'f' +((?:\s|//.*\\n|/[*](?:\\n|.)*?[*]/)*)+I Capturing subpattern count = 1 +May match empty string No options No first char No need char @@ -7467,7 +7523,7 @@ Matched, but too many substrings /a*[^a]/BZ ------------------------------------------------------------------ Bra - a* + a*+ [^a] Ket End @@ -7609,7 +7665,7 @@ No match ------------------------------------------------------------------ Bra ^ - [a-z]+ + [a-z]++ Ket End ------------------------------------------------------------------ @@ -7650,7 +7706,7 @@ No match ^ CBra 1 Cond - 2 Cond nref + 2 Cond ref y Ket [()] @@ -7710,6 +7766,7 @@ Named capturing subpatterns: one 1 three 3 two 2 +May match empty string Options: anchored caseless No first char No need char @@ -7809,15 +7866,9 @@ Failed: reference to non-existent subpattern at offset 7 1: abcabc1Xabc2XabcX 2: abcabc1Xabc2XabcX -/(?<A> (?'B' abc (?(R) (?(R&1)1) (?(R&B)2) X | (?1) (?2) (?R) ))) /x +/(?<A> (?'B' abc (?(R) (?(R&C)1) (?(R&B)2) X | (?1) (?2) (?R) ))) /x Failed: reference to non-existent subpattern at offset 29 -/(?<1> (?'B' abc (?(R) (?(R&1)1) (?(R&B)2) X | (?1) (?2) (?R) ))) /x - abcabc1Xabc2XabcXabcabc - 0: abcabc1Xabc2XabcX - 1: abcabc1Xabc2XabcX - 2: abcabc1Xabc2XabcX - /^(?(DEFINE) abc | xyz ) /x Failed: DEFINE group contains more than one branch at offset 22 @@ -8041,7 +8092,7 @@ Failed: a numbered reference must not be zero at offset 8 /^(a)\g{3/ Failed: \g is not followed by a braced, angle-bracketed, or quoted name/number or by a plain number at offset 8 -/^(a)\g{4a}/ +/^(a)\g{aa}/ Failed: reference to non-existent subpattern at offset 9 /^a.b/<lf> @@ -8546,7 +8597,7 @@ No match \d \v++ \w - \v+ + \v++ \S \v++ \V @@ -8644,27 +8695,18 @@ No match +6 ^ ^ (*FAIL) +6 ^ ^ (*FAIL) +6 ^ ^ (*FAIL) - +4 ^ ^ c+ - +2 ^ ^ b? - +4 ^ ^ c+ - +2 ^^ b? - +4 ^^ c+ +0 ^ a+ +2 ^ ^ b? +4 ^ ^ c+ +6 ^ ^ (*FAIL) +6 ^ ^ (*FAIL) +6 ^ ^ (*FAIL) - +4 ^ ^ c+ - +2 ^^ b? - +4 ^^ c+ +0 ^ a+ +2 ^^ b? +4 ^ ^ c+ +6 ^ ^ (*FAIL) +6 ^ ^ (*FAIL) +6 ^ ^ (*FAIL) - +4 ^^ c+ No match /a+b?(*PRUNE)c+(*FAIL)/C @@ -9233,8 +9275,28 @@ No match ab No match -/a(?!)+b/ -Failed: nothing to repeat at offset 5 +/a(?!)b/BZ +------------------------------------------------------------------ + Bra + a + *FAIL + b + Ket + End +------------------------------------------------------------------ + +/(?!)?a/BZ +------------------------------------------------------------------ + Bra + Brazero + Assert not + Ket + a + Ket + End +------------------------------------------------------------------ + ab + 0: a /a(*FAIL)+b/ Failed: nothing to repeat at offset 8 @@ -9249,6 +9311,7 @@ Starting byte set: x y z /(?(?=.*b)b|^)/CI Capturing subpattern count = 0 +May match empty string Options: No first char No need char @@ -9353,7 +9416,7 @@ No match No match /(*NO_START_OPT)xyz/C - abcxyz + abcxyz --->abcxyz +15 ^ x +15 ^ x @@ -9363,6 +9426,15 @@ No match +17 ^ ^ z +18 ^ ^ 0: xyz + +/(*NO_AUTO_POSSESS)a+b/BZ +------------------------------------------------------------------ + Bra + a+ + b + Ket + End +------------------------------------------------------------------ /xyz/CY abcxyz @@ -10160,7 +10232,6 @@ No set of starting bytes Capturing subpattern count = 1 Named capturing subpatterns: a 1 - a 1 No options No first char No need char @@ -10233,7 +10304,7 @@ No match Ket Ket Cond - 4 Cond nref + Cond ref <D>2 X Alt Y @@ -10279,7 +10350,7 @@ No match CBra 4 d Cond - Cond nrecurse 1 + Cond recurse <A>2 $ Alt Recurse @@ -11036,12 +11107,14 @@ No need char /(^ab|^)+/I Capturing subpattern count = 1 +May match empty string Options: anchored No first char No need char /(^ab|^)++/I Capturing subpattern count = 1 +May match empty string Options: anchored No first char No need char @@ -11060,12 +11133,14 @@ No need char /(?:^ab|^)+/I Capturing subpattern count = 0 +May match empty string Options: anchored No first char No need char /(?:^ab|^)++/I Capturing subpattern count = 0 +May match empty string Options: anchored No first char No need char @@ -11084,12 +11159,14 @@ Need char = 'b' /(.*ab|.*)+/I Capturing subpattern count = 1 +May match empty string No options First char at start or follows newline No need char /(.*ab|.*)++/I Capturing subpattern count = 1 +May match empty string No options First char at start or follows newline No need char @@ -11108,12 +11185,14 @@ Need char = 'b' /(?:.*ab|.*)+/I Capturing subpattern count = 0 +May match empty string No options First char at start or follows newline No need char /(?:.*ab|.*)++/I Capturing subpattern count = 0 +May match empty string No options First char at start or follows newline No need char @@ -11519,7 +11598,7 @@ Matched, but too many substrings Assert not a Ket - \w+ + \w++ Ket End ------------------------------------------------------------------ @@ -11645,6 +11724,7 @@ Starting byte set: < o t u /a(*SKIP)c|b(*ACCEPT)|/+S!I Capturing subpattern count = 0 +May match empty string No options No first char No need char @@ -11715,11 +11795,11 @@ Minimum match() recursion limit = 45 Bra ^ Once_NC - a+ + a++ Ket Once CBra 1 - z+ + z++ Ket Ket \w @@ -11778,14 +11858,14 @@ No match /^(?>a+)(?>b+)(?>c+)(?>d+)(?>e+)/ \Maabbccddee -Minimum match() limit = 12 -Minimum match() recursion limit = 3 +Minimum match() limit = 7 +Minimum match() recursion limit = 2 0: aabbccddee /^(?>(a+))(?>(b+))(?>(c+))(?>(d+))(?>(e+))/ \Maabbccddee -Minimum match() limit = 22 -Minimum match() recursion limit = 21 +Minimum match() limit = 17 +Minimum match() recursion limit = 16 0: aabbccddee 1: aa 2: bb @@ -11795,8 +11875,8 @@ Minimum match() recursion limit = 21 /^(?>(a+))(?>b+)(?>(c+))(?>d+)(?>(e+))/ \Maabbccddee -Minimum match() limit = 18 -Minimum match() recursion limit = 13 +Minimum match() limit = 13 +Minimum match() recursion limit = 10 0: aabbccddee 1: aa 2: cc @@ -11887,7 +11967,10 @@ No match Failed: \N is not supported in a class at offset 3 /a[B-\Nc]/ -Failed: \N is not supported in a class at offset 5 +Failed: invalid range in character class at offset 5 + +/a[B\Nc]/ +Failed: \N is not supported in a class at offset 4 /(a)(?2){0,1999}?(b)/ @@ -12293,6 +12376,7 @@ No need char /(?>.*?)(?<=(abcd)|(wxyz))/I Capturing subpattern count = 2 Max lookbehind = 4 +May match empty string No options No first char No need char @@ -12300,6 +12384,7 @@ No need char /(?>.*)(?<=(abcd)|(wxyz))/I Capturing subpattern count = 2 Max lookbehind = 4 +May match empty string No options No first char No need char @@ -12338,6 +12423,7 @@ Need char = 'c' /.?/S-I Capturing subpattern count = 0 +May match empty string No options No first char No need char @@ -12345,6 +12431,7 @@ Study returned NULL /.?/S!I Capturing subpattern count = 0 +May match empty string No options No first char No need char @@ -12665,4 +12752,1377 @@ No match aaaaaaaaaaaaaz\Q10 Error -21 (recursion limit exceeded) +/-- This test causes a segfault with Perl 5.18.0 --/ + +/^(?=(a)){0}b(?1)/ + backgammon + 0: ba + +/(?|(?<n>f)|(?<n>b))/JI +Capturing subpattern count = 1 +Named capturing subpatterns: + n 1 +Options: dupnames +No first char +No need char + +/(?<a>abc)(?<a>z)\k<a>()/JDZS +------------------------------------------------------------------ + Bra + CBra 1 + abc + Ket + CBra 2 + z + Ket + \k<a>2 + CBra 3 + Ket + Ket + End +------------------------------------------------------------------ +Capturing subpattern count = 3 +Max back reference = 2 +Named capturing subpatterns: + a 1 + a 2 +Options: dupnames +First char = 'a' +Need char = 'z' +Subject length lower bound = 5 +No set of starting bytes + +/a*[bcd]/BZ +------------------------------------------------------------------ + Bra + a*+ + [b-d] + Ket + End +------------------------------------------------------------------ + +/[bcd]*a/BZ +------------------------------------------------------------------ + Bra + [b-d]*+ + a + Ket + End +------------------------------------------------------------------ + +/-- A complete set of tests for auto-possessification of character types --/ + +/\D+\D \D+\d \D+\S \D+\s \D+\W \D+\w \D+. \D+\C \D+\R \D+\H \D+\h \D+\V \D+\v \D+\Z \D+\z \D+$/BZx +------------------------------------------------------------------ + Bra + \D+ + \D + \D++ + \d + \D+ + \S + \D+ + \s + \D+ + \W + \D+ + \w + \D+ + Any + \D+ + AllAny + \D+ + \R + \D+ + \H + \D+ + \h + \D+ + \V + \D+ + \v + \D+ + \Z + \D++ + \z + \D+ + $ + Ket + End +------------------------------------------------------------------ + +/\d+\D \d+\d \d+\S \d+\s \d+\W \d+\w \d+. \d+\C \d+\R \d+\H \d+\h \d+\V \d+\v \d+\Z \d+\z \d+$/BZx +------------------------------------------------------------------ + Bra + \d++ + \D + \d+ + \d + \d+ + \S + \d++ + \s + \d++ + \W + \d+ + \w + \d+ + Any + \d+ + AllAny + \d++ + \R + \d+ + \H + \d++ + \h + \d+ + \V + \d++ + \v + \d++ + \Z + \d++ + \z + \d++ + $ + Ket + End +------------------------------------------------------------------ + +/\S+\D \S+\d \S+\S \S+\s \S+\W \S+\w \S+. \S+\C \S+\R \S+\H \S+\h \S+\V \S+\v \S+\Z \S+\z \S+$/BZx +------------------------------------------------------------------ + Bra + \S+ + \D + \S+ + \d + \S+ + \S + \S++ + \s + \S+ + \W + \S+ + \w + \S+ + Any + \S+ + AllAny + \S++ + \R + \S+ + \H + \S++ + \h + \S+ + \V + \S++ + \v + \S++ + \Z + \S++ + \z + \S++ + $ + Ket + End +------------------------------------------------------------------ + +/\s+\D \s+\d \s+\S \s+\s \s+\W \s+\w \s+. \s+\C \s+\R \s+\H \s+\h \s+\V \s+\v \s+\Z \s+\z \s+$/BZx +------------------------------------------------------------------ + Bra + \s+ + \D + \s++ + \d + \s++ + \S + \s+ + \s + \s+ + \W + \s++ + \w + \s+ + Any + \s+ + AllAny + \s+ + \R + \s+ + \H + \s+ + \h + \s+ + \V + \s+ + \v + \s+ + \Z + \s++ + \z + \s+ + $ + Ket + End +------------------------------------------------------------------ + +/\W+\D \W+\d \W+\S \W+\s \W+\W \W+\w \W+. \W+\C \W+\R \W+\H \W+\h \W+\V \W+\v \W+\Z \W+\z \W+$/BZx +------------------------------------------------------------------ + Bra + \W+ + \D + \W++ + \d + \W+ + \S + \W+ + \s + \W+ + \W + \W++ + \w + \W+ + Any + \W+ + AllAny + \W+ + \R + \W+ + \H + \W+ + \h + \W+ + \V + \W+ + \v + \W+ + \Z + \W++ + \z + \W+ + $ + Ket + End +------------------------------------------------------------------ + +/\w+\D \w+\d \w+\S \w+\s \w+\W \w+\w \w+. \w+\C \w+\R \w+\H \w+\h \w+\V \w+\v \w+\Z \w+\z \w+$/BZx +------------------------------------------------------------------ + Bra + \w+ + \D + \w+ + \d + \w+ + \S + \w++ + \s + \w++ + \W + \w+ + \w + \w+ + Any + \w+ + AllAny + \w++ + \R + \w+ + \H + \w++ + \h + \w+ + \V + \w++ + \v + \w++ + \Z + \w++ + \z + \w++ + $ + Ket + End +------------------------------------------------------------------ + +/\C+\D \C+\d \C+\S \C+\s \C+\W \C+\w \C+. \C+\C \C+\R \C+\H \C+\h \C+\V \C+\v \C+\Z \C+\z \C+$/BZx +------------------------------------------------------------------ + Bra + AllAny+ + \D + AllAny+ + \d + AllAny+ + \S + AllAny+ + \s + AllAny+ + \W + AllAny+ + \w + AllAny+ + Any + AllAny+ + AllAny + AllAny+ + \R + AllAny+ + \H + AllAny+ + \h + AllAny+ + \V + AllAny+ + \v + AllAny+ + \Z + AllAny++ + \z + AllAny+ + $ + Ket + End +------------------------------------------------------------------ + +/\R+\D \R+\d \R+\S \R+\s \R+\W \R+\w \R+. \R+\C \R+\R \R+\H \R+\h \R+\V \R+\v \R+\Z \R+\z \R+$/BZx +------------------------------------------------------------------ + Bra + \R+ + \D + \R++ + \d + \R+ + \S + \R++ + \s + \R+ + \W + \R++ + \w + \R++ + Any + \R+ + AllAny + \R+ + \R + \R+ + \H + \R++ + \h + \R+ + \V + \R+ + \v + \R+ + \Z + \R++ + \z + \R+ + $ + Ket + End +------------------------------------------------------------------ + +/\H+\D \H+\d \H+\S \H+\s \H+\W \H+\w \H+. \H+\C \H+\R \H+\H \H+\h \H+\V \H+\v \H+\Z \H+\z \H+$/BZx +------------------------------------------------------------------ + Bra + \H+ + \D + \H+ + \d + \H+ + \S + \H+ + \s + \H+ + \W + \H+ + \w + \H+ + Any + \H+ + AllAny + \H+ + \R + \H+ + \H + \H++ + \h + \H+ + \V + \H+ + \v + \H+ + \Z + \H++ + \z + \H+ + $ + Ket + End +------------------------------------------------------------------ + +/\h+\D \h+\d \h+\S \h+\s \h+\W \h+\w \h+. \h+\C \h+\R \h+\H \h+\h \h+\V \h+\v \h+\Z \h+\z \h+$/BZx +------------------------------------------------------------------ + Bra + \h+ + \D + \h++ + \d + \h++ + \S + \h+ + \s + \h+ + \W + \h++ + \w + \h+ + Any + \h+ + AllAny + \h++ + \R + \h++ + \H + \h+ + \h + \h+ + \V + \h++ + \v + \h+ + \Z + \h++ + \z + \h+ + $ + Ket + End +------------------------------------------------------------------ + +/\V+\D \V+\d \V+\S \V+\s \V+\W \V+\w \V+. \V+\C \V+\R \V+\H \V+\h \V+\V \V+\v \V+\Z \V+\z \V+$/BZx +------------------------------------------------------------------ + Bra + \V+ + \D + \V+ + \d + \V+ + \S + \V+ + \s + \V+ + \W + \V+ + \w + \V+ + Any + \V+ + AllAny + \V++ + \R + \V+ + \H + \V+ + \h + \V+ + \V + \V++ + \v + \V+ + \Z + \V++ + \z + \V+ + $ + Ket + End +------------------------------------------------------------------ + +/\v+\D \v+\d \v+\S \v+\s \v+\W \v+\w \v+. \v+\C \v+\R \v+\H \v+\h \v+\V \v+\v \v+\Z \v+\z \v+$/BZx +------------------------------------------------------------------ + Bra + \v+ + \D + \v++ + \d + \v++ + \S + \v+ + \s + \v+ + \W + \v++ + \w + \v+ + Any + \v+ + AllAny + \v+ + \R + \v+ + \H + \v++ + \h + \v++ + \V + \v+ + \v + \v+ + \Z + \v++ + \z + \v+ + $ + Ket + End +------------------------------------------------------------------ + +/ a+\D a+\d a+\S a+\s a+\W a+\w a+. a+\C a+\R a+\H a+\h a+\V a+\v a+\Z a+\z a+$/BZx +------------------------------------------------------------------ + Bra + a+ + \D + a++ + \d + a+ + \S + a++ + \s + a++ + \W + a+ + \w + a+ + Any + a+ + AllAny + a++ + \R + a+ + \H + a++ + \h + a+ + \V + a++ + \v + a++ + \Z + a++ + \z + a++ + $ + Ket + End +------------------------------------------------------------------ + +/\n+\D \n+\d \n+\S \n+\s \n+\W \n+\w \n+. \n+\C \n+\R \n+\H \n+\h \n+\V \n+\v \n+\Z \n+\z \n+$/BZx +------------------------------------------------------------------ + Bra + \x0a+ + \D + \x0a++ + \d + \x0a++ + \S + \x0a+ + \s + \x0a+ + \W + \x0a++ + \w + \x0a+ + Any + \x0a+ + AllAny + \x0a+ + \R + \x0a+ + \H + \x0a++ + \h + \x0a++ + \V + \x0a+ + \v + \x0a+ + \Z + \x0a++ + \z + \x0a+ + $ + Ket + End +------------------------------------------------------------------ + +/ .+\D .+\d .+\S .+\s .+\W .+\w .+. .+\C .+\R .+\H .+\h .+\V .+\v .+\Z .+\z .+$/BZx +------------------------------------------------------------------ + Bra + Any+ + \D + Any+ + \d + Any+ + \S + Any+ + \s + Any+ + \W + Any+ + \w + Any+ + Any + Any+ + AllAny + Any++ + \R + Any+ + \H + Any+ + \h + Any+ + \V + Any+ + \v + Any+ + \Z + Any++ + \z + Any+ + $ + Ket + End +------------------------------------------------------------------ + +/ .+\D .+\d .+\S .+\s .+\W .+\w .+. .+\C .+\R .+\H .+\h .+\V .+\v .+\Z .+\z .+$/BZxs +------------------------------------------------------------------ + Bra + AllAny+ + \D + AllAny+ + \d + AllAny+ + \S + AllAny+ + \s + AllAny+ + \W + AllAny+ + \w + AllAny+ + AllAny + AllAny+ + AllAny + AllAny+ + \R + AllAny+ + \H + AllAny+ + \h + AllAny+ + \V + AllAny+ + \v + AllAny+ + \Z + AllAny++ + \z + AllAny+ + $ + Ket + End +------------------------------------------------------------------ + +/\D+$ \d+$ \S+$ \s+$ \W+$ \w+$ \C+$ \R+$ \H+$ \h+$ \V+$ \v+$ a+$ \n+$ .+$ .+$/BZxm +------------------------------------------------------------------ + Bra + \D+ + /m $ + \d++ + /m $ + \S++ + /m $ + \s+ + /m $ + \W+ + /m $ + \w++ + /m $ + AllAny+ + /m $ + \R+ + /m $ + \H+ + /m $ + \h+ + /m $ + \V+ + /m $ + \v+ + /m $ + a+ + /m $ + \x0a+ + /m $ + Any+ + /m $ + Any+ + /m $ + Ket + End +------------------------------------------------------------------ + +/(?=a+)a(a+)++a/BZ +------------------------------------------------------------------ + Bra + Assert + a++ + Ket + a + CBraPos 1 + a++ + KetRpos + a + Ket + End +------------------------------------------------------------------ + +/a+(bb|cc)a+(?:bb|cc)a+(?>bb|cc)a+(?:bb|cc)+a+(aa)a+(?:bb|aa)/BZ +------------------------------------------------------------------ + Bra + a++ + CBra 1 + bb + Alt + cc + Ket + a++ + Bra + bb + Alt + cc + Ket + a++ + Once_NC + bb + Alt + cc + Ket + a++ + Bra + bb + Alt + cc + KetRmax + a+ + CBra 2 + aa + Ket + a+ + Bra + bb + Alt + aa + Ket + Ket + End +------------------------------------------------------------------ + +/a+(bb|cc)?#a+(?:bb|cc)??#a+(?:bb|cc)?+#a+(?:bb|cc)*#a+(bb|cc)?a#a+(?:aa)?/BZ +------------------------------------------------------------------ + Bra + a++ + Brazero + CBra 1 + bb + Alt + cc + Ket + # + a++ + Braminzero + Bra + bb + Alt + cc + Ket + # + a++ + Once + Brazero + Bra + bb + Alt + cc + Ket + Ket + # + a++ + Brazero + Bra + bb + Alt + cc + KetRmax + # + a+ + Brazero + CBra 2 + bb + Alt + cc + Ket + a# + a+ + Brazero + Bra + aa + Ket + Ket + End +------------------------------------------------------------------ + +/a+(?:bb)?a#a+(?:|||)#a+(?:|b)a#a+(?:|||)?a/BZ +------------------------------------------------------------------ + Bra + a+ + Brazero + Bra + bb + Ket + a# + a++ + Bra + Alt + Alt + Alt + Ket + # + a+ + Bra + Alt + b + Ket + a# + a+ + Brazero + Bra + Alt + Alt + Alt + Ket + a + Ket + End +------------------------------------------------------------------ + +/[ab]*/BZ +------------------------------------------------------------------ + Bra + [ab]*+ + Ket + End +------------------------------------------------------------------ + aaaa + 0: aaaa + +/[ab]*?/BZ +------------------------------------------------------------------ + Bra + [ab]*? + Ket + End +------------------------------------------------------------------ + aaaa + 0: + +/[ab]?/BZ +------------------------------------------------------------------ + Bra + [ab]?+ + Ket + End +------------------------------------------------------------------ + aaaa + 0: a + +/[ab]??/BZ +------------------------------------------------------------------ + Bra + [ab]?? + Ket + End +------------------------------------------------------------------ + aaaa + 0: + +/[ab]+/BZ +------------------------------------------------------------------ + Bra + [ab]++ + Ket + End +------------------------------------------------------------------ + aaaa + 0: aaaa + +/[ab]+?/BZ +------------------------------------------------------------------ + Bra + [ab]+? + Ket + End +------------------------------------------------------------------ + aaaa + 0: a + +/[ab]{2,3}/BZ +------------------------------------------------------------------ + Bra + [ab]{2,3}+ + Ket + End +------------------------------------------------------------------ + aaaa + 0: aaa + +/[ab]{2,3}?/BZ +------------------------------------------------------------------ + Bra + [ab]{2,3}? + Ket + End +------------------------------------------------------------------ + aaaa + 0: aa + +/[ab]{2,}/BZ +------------------------------------------------------------------ + Bra + [ab]{2,}+ + Ket + End +------------------------------------------------------------------ + aaaa + 0: aaaa + +/[ab]{2,}?/BZ +------------------------------------------------------------------ + Bra + [ab]{2,}? + Ket + End +------------------------------------------------------------------ + aaaa + 0: aa + +/\d+\s{0,5}=\s*\S?=\w{0,4}\W*/BZ +------------------------------------------------------------------ + Bra + \d++ + \s{0,5}+ + = + \s*+ + \S? + = + \w{0,4}+ + \W*+ + Ket + End +------------------------------------------------------------------ + +/[a-d]{5,12}[e-z0-9]*#[^a-z]+[b-y]*a[2-7]?[^0-9a-z]+/BZ +------------------------------------------------------------------ + Bra + [a-d]{5,12}+ + [0-9e-z]*+ + # + [\x00-`{-\xff] (neg)++ + [b-y]*+ + a + [2-7]?+ + [\x00-/:-`{-\xff] (neg)++ + Ket + End +------------------------------------------------------------------ + +/[a-z]*\s#[ \t]?\S#[a-c]*\S#[C-G]+?\d#[4-8]*\D#[4-9,]*\D#[!$]{0,5}\w#[M-Xf-l]+\W#[a-c,]?\W/BZ +------------------------------------------------------------------ + Bra + [a-z]*+ + \s + # + [\x09 ]?+ + \S + # + [a-c]* + \S + # + [C-G]++ + \d + # + [4-8]*+ + \D + # + [,4-9]* + \D + # + [!$]{0,5}+ + \w + # + [M-Xf-l]++ + \W + # + [,a-c]? + \W + Ket + End +------------------------------------------------------------------ + +/a+(aa|bb)*c#a*(bb|cc)*a#a?(bb|cc)*d#[a-f]*(g|hh)*f/BZ +------------------------------------------------------------------ + Bra + a+ + Brazero + CBra 1 + aa + Alt + bb + KetRmax + c# + a* + Brazero + CBra 2 + bb + Alt + cc + KetRmax + a# + a?+ + Brazero + CBra 3 + bb + Alt + cc + KetRmax + d# + [a-f]* + Brazero + CBra 4 + g + Alt + hh + KetRmax + f + Ket + End +------------------------------------------------------------------ + +/[a-f]*(g|hh|i)*i#[a-x]{4,}(y{0,6})*y#[a-k]+(ll|mm)+n/BZ +------------------------------------------------------------------ + Bra + [a-f]*+ + Brazero + CBra 1 + g + Alt + hh + Alt + i + KetRmax + i# + [a-x]{4,} + Brazero + SCBra 2 + y{0,6} + KetRmax + y# + [a-k]++ + CBra 3 + ll + Alt + mm + KetRmax + n + Ket + End +------------------------------------------------------------------ + +/[a-f]*(?>gg|hh)+#[a-f]*(?>gg|hh)?#[a-f]*(?>gg|hh)*a#[a-f]*(?>gg|hh)*h/BZ +------------------------------------------------------------------ + Bra + [a-f]*+ + Once_NC + gg + Alt + hh + KetRmax + # + [a-f]*+ + Brazero + Once_NC + gg + Alt + hh + Ket + # + [a-f]* + Brazero + Once_NC + gg + Alt + hh + KetRmax + a# + [a-f]*+ + Brazero + Once_NC + gg + Alt + hh + KetRmax + h + Ket + End +------------------------------------------------------------------ + +/[a-c]*d/DZS +------------------------------------------------------------------ + Bra + [a-c]*+ + d + Ket + End +------------------------------------------------------------------ +Capturing subpattern count = 0 +No options +No first char +Need char = 'd' +Subject length lower bound = 1 +Starting byte set: a b c d + +/[a-c]+d/DZS +------------------------------------------------------------------ + Bra + [a-c]++ + d + Ket + End +------------------------------------------------------------------ +Capturing subpattern count = 0 +No options +No first char +Need char = 'd' +Subject length lower bound = 2 +Starting byte set: a b c + +/[a-c]?d/DZS +------------------------------------------------------------------ + Bra + [a-c]?+ + d + Ket + End +------------------------------------------------------------------ +Capturing subpattern count = 0 +No options +No first char +Need char = 'd' +Subject length lower bound = 1 +Starting byte set: a b c d + +/[a-c]{4,6}d/DZS +------------------------------------------------------------------ + Bra + [a-c]{4,6}+ + d + Ket + End +------------------------------------------------------------------ +Capturing subpattern count = 0 +No options +No first char +Need char = 'd' +Subject length lower bound = 5 +Starting byte set: a b c + +/[a-c]{0,6}d/DZS +------------------------------------------------------------------ + Bra + [a-c]{0,6}+ + d + Ket + End +------------------------------------------------------------------ +Capturing subpattern count = 0 +No options +No first char +Need char = 'd' +Subject length lower bound = 1 +Starting byte set: a b c d + +/-- End of special auto-possessive tests --/ + +/^A\o{1239}B/ +Failed: non-octal character in \o{} (closing brace missing?) at offset 8 + +/^A\oB/ +Failed: missing opening brace after \o at offset 3 + +/^A\x{zz}B/ +Failed: non-hex character in \x{} (closing brace missing?) at offset 5 + +/^A\x{12Z/ +Failed: non-hex character in \x{} (closing brace missing?) at offset 7 + +/^A\x{/ +Failed: non-hex character in \x{} (closing brace missing?) at offset 5 + +/[ab]++/BZO +------------------------------------------------------------------ + Bra + [ab]++ + Ket + End +------------------------------------------------------------------ + +/[^ab]*+/BZO +------------------------------------------------------------------ + Bra + [\x00-`c-\xff] (neg)*+ + Ket + End +------------------------------------------------------------------ + +/a{4}+/BZO +------------------------------------------------------------------ + Bra + a{4} + Ket + End +------------------------------------------------------------------ + +/a{4}+/BZOi +------------------------------------------------------------------ + Bra + /i a{4} + Ket + End +------------------------------------------------------------------ + +/[a-[:digit:]]+/ +Failed: invalid range in character class at offset 3 + +/[A-[:digit:]]+/ +Failed: invalid range in character class at offset 3 + +/[a-[.xxx.]]+/ +Failed: invalid range in character class at offset 3 + +/[a-[=xxx=]]+/ +Failed: invalid range in character class at offset 3 + +/[a-[!xxx!]]+/ +Failed: range out of order in character class at offset 3 + +/[A-[!xxx!]]+/ + A]]] + 0: A]]] + +/[a-\d]+/ +Failed: invalid range in character class at offset 4 + +/(?<0abc>xx)/ +Failed: group name must start with a non-digit at offset 3 + +/(?&1abc)xx(?<1abc>y)/ +Failed: group name must start with a non-digit at offset 3 + +/(?<ab-cd>xx)/ +Failed: syntax error in subpattern name (missing terminator) at offset 5 + +/(?'0abc'xx)/ +Failed: group name must start with a non-digit at offset 3 + +/(?P<0abc>xx)/ +Failed: group name must start with a non-digit at offset 4 + +/\k<5ghj>/ +Failed: group name must start with a non-digit at offset 3 + +/\k'5ghj'/ +Failed: group name must start with a non-digit at offset 3 + +/\k{2fgh}/ +Failed: group name must start with a non-digit at offset 3 + +/(?P=8yuki)/ +Failed: group name must start with a non-digit at offset 4 + +/\g{4df}/ +Failed: group name must start with a non-digit at offset 3 + +/(?&1abc)xx(?<1abc>y)/ +Failed: group name must start with a non-digit at offset 3 + +/(?P>1abc)xx(?<1abc>y)/ +Failed: group name must start with a non-digit at offset 4 + +/\g'3gh'/ +Failed: \g is not followed by a braced, angle-bracketed, or quoted name/number or by a plain number at offset 7 + +/\g<5fg>/ +Failed: \g is not followed by a braced, angle-bracketed, or quoted name/number or by a plain number at offset 7 + +/(?(<4gh>)abc)/ +Failed: group name must start with a non-digit at offset 4 + +/(?('4gh')abc)/ +Failed: group name must start with a non-digit at offset 4 + +/(?(4gh)abc)/ +Failed: malformed number or name after (?( at offset 4 + +/(?(R&6yh)abc)/ +Failed: group name must start with a non-digit at offset 5 + +/-- Test the ugly "start or end of word" compatibility syntax --/ + +/[[:<:]]red[[:>:]]/BZ +------------------------------------------------------------------ + Bra + \b + Assert + \w + Ket + red + \b + AssertB + Reverse + \w + Ket + Ket + End +------------------------------------------------------------------ + little red riding hood + 0: red + a /red/ thing + 0: red + red is a colour + 0: red + put it all on red + 0: red + ** Failers +No match + no reduction +No match + Alfred Winifred +No match + +/[a[:<:]] should give error/ +Failed: unknown POSIX class name at offset 4 + /-- End of testinput2 --/ diff --git a/pcre/testdata/testoutput20 b/pcre/testdata/testoutput20 index 7753be2db6a..c1b20ee804a 100644 --- a/pcre/testdata/testoutput20 +++ b/pcre/testdata/testoutput20 @@ -8,12 +8,10 @@ /^\x{ffff}?/i \x{ffff} 0: \x{ffff} - 1: /^\x{ffff}*/i \x{ffff} 0: \x{ffff} - 1: /^\x{ffff}{3}/i \x{ffff}\x{ffff}\x{ffff} @@ -22,6 +20,5 @@ /^\x{ffff}{0,3}/i \x{ffff} 0: \x{ffff} - 1: /-- End of testinput20 --/ diff --git a/pcre/testdata/testoutput21-16 b/pcre/testdata/testoutput21-16 index e831888a9e4..0e21350f891 100644 --- a/pcre/testdata/testoutput21-16 +++ b/pcre/testdata/testoutput21-16 @@ -8,7 +8,11 @@ No study data Error -28 from pcre16_fullinfo(0) Running in 16-bit mode but pattern was compiled in 8-bit mode -%-- Generated from: ^[aL](?P<name>(?:[AaLl]+)[^xX-]*?)(?P<other>[\x{150}-\x{250}\x{300}]|[^\x{800}aAs-uS-U\x{d800}-\x{dfff}])++[^#\b\x{500}\x{1000}]{3,5}$ +%-- Generated from: + /^[aL](?P<name>(?:[AaLl]+)[^xX-]*?)(?P<other>[\x{150}-\x{250}\x{300}]| + [^\x{800}aAs-uS-U\x{d800}-\x{dfff}])++[^#\b\x{500}\x{1000}]{3,5}$ + /x + In 16-bit mode with options: S>testdata/saved16LE-1 FS>testdata/saved16BE-1 In 32-bit mode with options: S>testdata/saved32LE-1 @@ -42,7 +46,7 @@ Capturing subpattern count = 2 Named capturing subpatterns: name 1 other 2 -Options: anchored +Options: anchored extended No first char No need char Subject length lower bound = 6 @@ -75,7 +79,7 @@ Capturing subpattern count = 2 Named capturing subpatterns: name 1 other 2 -Options: anchored +Options: anchored extended No first char No need char Subject length lower bound = 6 diff --git a/pcre/testdata/testoutput21-32 b/pcre/testdata/testoutput21-32 index c6e8f6ca0ca..183487aca13 100644 --- a/pcre/testdata/testoutput21-32 +++ b/pcre/testdata/testoutput21-32 @@ -8,7 +8,11 @@ No study data Error -28 from pcre32_fullinfo(0) Running in 32-bit mode but pattern was compiled in 8-bit mode -%-- Generated from: ^[aL](?P<name>(?:[AaLl]+)[^xX-]*?)(?P<other>[\x{150}-\x{250}\x{300}]|[^\x{800}aAs-uS-U\x{d800}-\x{dfff}])++[^#\b\x{500}\x{1000}]{3,5}$ +%-- Generated from: + /^[aL](?P<name>(?:[AaLl]+)[^xX-]*?)(?P<other>[\x{150}-\x{250}\x{300}]| + [^\x{800}aAs-uS-U\x{d800}-\x{dfff}])++[^#\b\x{500}\x{1000}]{3,5}$ + /x + In 16-bit mode with options: S>testdata/saved16LE-1 FS>testdata/saved16BE-1 In 32-bit mode with options: S>testdata/saved32LE-1 @@ -54,7 +58,7 @@ Capturing subpattern count = 2 Named capturing subpatterns: name 1 other 2 -Options: anchored +Options: anchored extended No first char No need char Subject length lower bound = 6 @@ -87,7 +91,7 @@ Capturing subpattern count = 2 Named capturing subpatterns: name 1 other 2 -Options: anchored +Options: anchored extended No first char No need char Subject length lower bound = 6 diff --git a/pcre/testdata/testoutput22-16 b/pcre/testdata/testoutput22-16 index b2c673d43a0..f896b13e18a 100644 --- a/pcre/testdata/testoutput22-16 +++ b/pcre/testdata/testoutput22-16 @@ -1,10 +1,15 @@ /-- Tests for reloading pre-compile patterns with UTF-16 or UTF-32 support. */ -%-- Generated from: (?P<cbra1>[aZ\x{400}-\x{10ffff}]{4,}[\x{f123}\x{10039}\x{20000}-\x{21234}]?|[A-Cx-z\x{100000}-\x{1000a7}\x{101234}])(?<cb2>[^az]) - In 16-bit mode with options: S8>testdata/saved16LE-1 - FS8>testdata/saved16BE-1 - In 32-bit mode with options: S8>testdata/saved32LE-1 - FS8testdata/saved32BE-1 +%-- Generated from: + /(?P<cbra1>[aZ\x{400}-\x{10ffff}]{4,} + [\x{f123}\x{10039}\x{20000}-\x{21234}]?| + [A-Cx-z\x{100000}-\x{1000a7}\x{101234}]) + (?<cb2>[^az])/x + + In 16-bit mode with options: S8>testdata/saved16LE-2 + FS8>testdata/saved16BE-2 + In 32-bit mode with options: S8>testdata/saved32LE-2 + FS8>testdata/saved32BE-2 --%8x <!testsaved16LE-2 @@ -28,7 +33,7 @@ Capturing subpattern count = 2 Named capturing subpatterns: cb2 2 cbra1 1 -Options: utf +Options: extended utf No first char No need char Subject length lower bound = 2 @@ -55,7 +60,7 @@ Capturing subpattern count = 2 Named capturing subpatterns: cb2 2 cbra1 1 -Options: utf +Options: extended utf No first char No need char Subject length lower bound = 2 diff --git a/pcre/testdata/testoutput22-32 b/pcre/testdata/testoutput22-32 index 5a1d0dac3ec..783926b8210 100644 --- a/pcre/testdata/testoutput22-32 +++ b/pcre/testdata/testoutput22-32 @@ -1,10 +1,15 @@ /-- Tests for reloading pre-compile patterns with UTF-16 or UTF-32 support. */ -%-- Generated from: (?P<cbra1>[aZ\x{400}-\x{10ffff}]{4,}[\x{f123}\x{10039}\x{20000}-\x{21234}]?|[A-Cx-z\x{100000}-\x{1000a7}\x{101234}])(?<cb2>[^az]) - In 16-bit mode with options: S8>testdata/saved16LE-1 - FS8>testdata/saved16BE-1 - In 32-bit mode with options: S8>testdata/saved32LE-1 - FS8testdata/saved32BE-1 +%-- Generated from: + /(?P<cbra1>[aZ\x{400}-\x{10ffff}]{4,} + [\x{f123}\x{10039}\x{20000}-\x{21234}]?| + [A-Cx-z\x{100000}-\x{1000a7}\x{101234}]) + (?<cb2>[^az])/x + + In 16-bit mode with options: S8>testdata/saved16LE-2 + FS8>testdata/saved16BE-2 + In 32-bit mode with options: S8>testdata/saved32LE-2 + FS8>testdata/saved32BE-2 --%8x <!testsaved16LE-2 @@ -40,7 +45,7 @@ Capturing subpattern count = 2 Named capturing subpatterns: cb2 2 cbra1 1 -Options: utf +Options: extended utf No first char No need char Subject length lower bound = 2 @@ -67,7 +72,7 @@ Capturing subpattern count = 2 Named capturing subpatterns: cb2 2 cbra1 1 -Options: utf +Options: extended utf No first char No need char Subject length lower bound = 2 diff --git a/pcre/testdata/testoutput23 b/pcre/testdata/testoutput23 index 7b3634ca8a9..6f5384c34e8 100644 --- a/pcre/testdata/testoutput23 +++ b/pcre/testdata/testoutput23 @@ -1,5 +1,7 @@ /-- Tests for the 16-bit library only */ +< forbid 8W + /-- Check maximum non-UTF character size --/ /\x{ffff}/ @@ -7,7 +9,9 @@ 0: \x{ffff} /\x{10000}/ -Failed: character value in \x{...} sequence is too large at offset 8 +Failed: character value in \x{} or \o{} is too large at offset 8 + +/\o{20000}/ /-- Check character ranges --/ diff --git a/pcre/testdata/testoutput24 b/pcre/testdata/testoutput24 index 3f8cabe84c8..0714a0fe156 100644 --- a/pcre/testdata/testoutput24 +++ b/pcre/testdata/testoutput24 @@ -1,5 +1,7 @@ /-- Tests for the 16-bit library with UTF-16 support only */ +< forbid W + /bad/8 \x{d800} Error -10 (bad UTF-16 string) offset=0 reason=1 diff --git a/pcre/testdata/testoutput25 b/pcre/testdata/testoutput25 index 2a4066dfc48..7ad3378368f 100644 --- a/pcre/testdata/testoutput25 +++ b/pcre/testdata/testoutput25 @@ -1,5 +1,7 @@ /-- Tests for the 32-bit library only */ +< forbid 8w + /-- Check maximum character size --/ /\x{110000}/ @@ -10,6 +12,18 @@ /\x{ffffffff}/ +/\x{100000000}/ +Failed: character value in \x{} or \o{} is too large at offset 12 + +/\o{17777777777}/ + +/\o{20000000000}/ + +/\o{37777777777}/ + +/\o{40000000000}/ +Failed: character value in \x{} or \o{} is too large at offset 14 + /\x{7fffffff}\x{7fffffff}/I Capturing subpattern count = 0 No options diff --git a/pcre/testdata/testoutput26 b/pcre/testdata/testoutput26 index 0e6d0559fab..28f8d42a5ed 100644 --- a/pcre/testdata/testoutput26 +++ b/pcre/testdata/testoutput26 @@ -1,9 +1,14 @@ /-- Tests for the 32-bit library with UTF-32 support only */ +< forbid W + /-- Non-UTF characters --/ /\x{110000}/8 -Failed: character value in \x{...} sequence is too large at offset 9 +Failed: character value in \x{} or \o{} is too large at offset 9 + +/\o{4200000}/8 +Failed: character value in \x{} or \o{} is too large at offset 10 /\C/8 \x{110000} diff --git a/pcre/testdata/testoutput3 b/pcre/testdata/testoutput3 index 7b0a3e926e1..12ffc9911b6 100644 --- a/pcre/testdata/testoutput3 +++ b/pcre/testdata/testoutput3 @@ -1,6 +1,8 @@ /-- This set of tests checks local-specific features, using the fr_FR locale. It is not Perl-compatible. There is different version called wintestinput3 f or use on Windows, where the locale is called "french". --/ + +< forbid 8W /^[\w]+/ *** Failers diff --git a/pcre/testdata/testoutput4 b/pcre/testdata/testoutput4 index 6694111fb55..0dbec4eccab 100644 --- a/pcre/testdata/testoutput4 +++ b/pcre/testdata/testoutput4 @@ -1,6 +1,8 @@ /-- This set of tests is for UTF support, excluding Unicode properties. It is compatible with all versions of Perl >= 5.10 and both the 8-bit and 16-bit PCRE libraries. --/ + +< forbid 9?=ABCDEFfGILMNPTUWXZ< /a.b/8 acb @@ -1257,4 +1259,8 @@ No match \x{100}\x{100}\x{100} No match +/^a+[a\x{200}]/8 + aa + 0: aa + /-- End of testinput4 --/ diff --git a/pcre/testdata/testoutput5 b/pcre/testdata/testoutput5 index d583119dd9b..3fa581052e6 100644 --- a/pcre/testdata/testoutput5 +++ b/pcre/testdata/testoutput5 @@ -1,26 +1,47 @@ /-- This set of tests checks the API, internals, and non-Perl stuff for UTF support, excluding Unicode properties. However, tests that give different results in 8-bit and 16-bit modes are excluded (see tests 16 and 17). --/ + +< forbid W /\x{110000}/8DZ -Failed: character value in \x{...} sequence is too large at offset 9 +Failed: character value in \x{} or \o{} is too large at offset 9 + +/\o{4200000}/8DZ +Failed: character value in \x{} or \o{} is too large at offset 10 /\x{ffffffff}/8 -Failed: character value in \x{...} sequence is too large at offset 11 +Failed: character value in \x{} or \o{} is too large at offset 11 + +/\o{37777777777}/8 +Failed: character value in \x{} or \o{} is too large at offset 14 /\x{100000000}/8 -Failed: character value in \x{...} sequence is too large at offset 12 +Failed: character value in \x{} or \o{} is too large at offset 12 + +/\o{77777777777}/8 +Failed: character value in \x{} or \o{} is too large at offset 14 /\x{d800}/8 Failed: disallowed Unicode code point (>= 0xd800 && <= 0xdfff) at offset 7 +/\o{154000}/8 +Failed: disallowed Unicode code point (>= 0xd800 && <= 0xdfff) at offset 9 + /\x{dfff}/8 Failed: disallowed Unicode code point (>= 0xd800 && <= 0xdfff) at offset 7 +/\o{157777}/8 +Failed: disallowed Unicode code point (>= 0xd800 && <= 0xdfff) at offset 9 + /\x{d7ff}/8 +/\o{153777}/8 + /\x{e000}/8 +/\o{170000}/8 + /^\x{100}a\x{1234}/8 \x{100}a\x{1234}bcd 0: \x{100}a\x{1234} @@ -146,11 +167,12 @@ No match /\x{100}*/8DZ ------------------------------------------------------------------ Bra - \x{100}* + \x{100}*+ Ket End ------------------------------------------------------------------ Capturing subpattern count = 0 +May match empty string Options: utf No first char No need char @@ -159,7 +181,7 @@ No need char ------------------------------------------------------------------ Bra a - \x{100}* + \x{100}*+ Ket End ------------------------------------------------------------------ @@ -172,7 +194,7 @@ No need char ------------------------------------------------------------------ Bra ab - \x{100}* + \x{100}*+ Ket End ------------------------------------------------------------------ @@ -373,6 +395,7 @@ Need char = 'z' End ------------------------------------------------------------------ Capturing subpattern count = 2 +May match empty string Options: utf No first char No need char @@ -404,6 +427,7 @@ No need char End ------------------------------------------------------------------ Capturing subpattern count = 2 +May match empty string Options: utf No first char No need char @@ -424,6 +448,7 @@ No need char End ------------------------------------------------------------------ Capturing subpattern count = 2 +May match empty string Options: utf No first char No need char @@ -455,6 +480,7 @@ No need char End ------------------------------------------------------------------ Capturing subpattern count = 2 +May match empty string Options: utf No first char No need char @@ -768,7 +794,7 @@ No match /[\h]{3,}/8BZ ------------------------------------------------------------------ Bra - [\x09 \xa0\x{1680}\x{180e}\x{2000}-\x{200a}\x{202f}\x{205f}\x{3000}]{3,} + [\x09 \xa0\x{1680}\x{180e}\x{2000}-\x{200a}\x{202f}\x{205f}\x{3000}]{3,}+ Ket End ------------------------------------------------------------------ @@ -1572,7 +1598,7 @@ Failed: disallowed Unicode code point (>= 0xd800 && <= 0xdfff) at offset 7 /[\h\x{e000}]+/8BZ ------------------------------------------------------------------ Bra - [\x09 \xa0\x{1680}\x{180e}\x{2000}-\x{200a}\x{202f}\x{205f}\x{3000}\x{e000}]+ + [\x09 \xa0\x{1680}\x{180e}\x{2000}-\x{200a}\x{202f}\x{205f}\x{3000}\x{e000}]++ Ket End ------------------------------------------------------------------ @@ -1594,7 +1620,7 @@ Failed: disallowed Unicode code point (>= 0xd800 && <= 0xdfff) at offset 7 /[\H\x{d7ff}]+/8BZ ------------------------------------------------------------------ Bra - [\x00-\x08\x0a-\x1f!-\x9f\x{a1}-\x{167f}\x{1681}-\x{180d}\x{180f}-\x{1fff}\x{200b}-\x{202e}\x{2030}-\x{205e}\x{2060}-\x{2fff}\x{3001}-\x{10ffff}\x{d7ff}]+ + [\x00-\x08\x0a-\x1f!-\x9f\x{a1}-\x{167f}\x{1681}-\x{180d}\x{180f}-\x{1fff}\x{200b}-\x{202e}\x{2030}-\x{205e}\x{2060}-\x{2fff}\x{3001}-\x{10ffff}\x{d7ff}]++ Ket End ------------------------------------------------------------------ @@ -1616,7 +1642,7 @@ Failed: disallowed Unicode code point (>= 0xd800 && <= 0xdfff) at offset 7 /[\v\x{e000}]+/8BZ ------------------------------------------------------------------ Bra - [\x0a-\x0d\x85\x{2028}-\x{2029}\x{e000}]+ + [\x0a-\x0d\x85\x{2028}-\x{2029}\x{e000}]++ Ket End ------------------------------------------------------------------ @@ -1634,7 +1660,7 @@ Failed: disallowed Unicode code point (>= 0xd800 && <= 0xdfff) at offset 7 /[\V\x{d7ff}]+/8BZ ------------------------------------------------------------------ Bra - [\x00-\x09\x0e-\x84\x{86}-\x{2027}\x{202a}-\x{10ffff}\x{d7ff}]+ + [\x00-\x09\x0e-\x84\x{86}-\x{2027}\x{202a}-\x{10ffff}\x{d7ff}]++ Ket End ------------------------------------------------------------------ @@ -1808,10 +1834,8 @@ Partial match: \x{0d}\x{0d} /i [^\x{8000}]* /i [^\x{7fff}]{2} /i [^\x{7fff}]{0,7}? - Once /i [^\x{fffff}]{5} - /i [^\x{fffff}]? - Ket + /i [^\x{fffff}]?+ Ket End ------------------------------------------------------------------ @@ -1846,4 +1870,16 @@ No match /\ud800/<JS>8 Failed: disallowed Unicode code point (>= 0xd800 && <= 0xdfff) at offset 5 +/^a+[a\x{200}]/8BZ +------------------------------------------------------------------ + Bra + ^ + a+ + [a\x{200}] + Ket + End +------------------------------------------------------------------ + aa + 0: aa + /-- End of testinput5 --/ diff --git a/pcre/testdata/testoutput6 b/pcre/testdata/testoutput6 index b1d45799261..6c42fce1a5b 100644 --- a/pcre/testdata/testoutput6 +++ b/pcre/testdata/testoutput6 @@ -1,5 +1,7 @@ /-- This set of tests is for Unicode property support. It is compatible with Perl >= 5.15. --/ + +< forbid 9?=ABCDEFfGILMNPTUXZ< /^\pC\pL\pM\pN\pP\pS\pZ</8 \x7f\x{c0}\x{30f}\x{660}\x{66c}\x{f01}\x{1680}< @@ -543,16 +545,6 @@ No match abc No match -/\p{Lu}/8i - A - 0: A - aZ - 0: Z - ** Failers - 0: F - abc -No match - /\p{Ll}/8 a 0: a @@ -727,6 +719,8 @@ No match 0: \x{6e9} \x{060b} 0: \x{60b} + \x{061c} + 0: \x{61c} ** Failers No match X\x{06e9} @@ -1310,7 +1304,7 @@ No match /^>\s+/8W >\x{20}\x{a0}\x{1680}\x{2028}\x{2029}\x{202f}\x{9}\x{b} - 0: > \x{a0}\x{1680}\x{2028}\x{2029}\x{202f}\x{09} + 0: > \x{a0}\x{1680}\x{2028}\x{2029}\x{202f}\x{09}\x{0b} /^>\pZ+/8W >\x{20}\x{a0}\x{1680}\x{2028}\x{2029}\x{202f}\x{9}\x{b} @@ -1338,15 +1332,15 @@ No match /^[[:graph:]]*/8W A\x{a1}\x{a0} - 0: A + 0: A\x{a1} /^[[:print:]]*/8W A z\x{a0}\x{a1} - 0: A z + 0: A z\x{a0}\x{a1} /^[[:punct:]]*/8W .+\x{a1}\x{a0} - 0: .+ + 0: .+\x{a1} /\p{Zs}*?\R/ ** Failers @@ -1548,6 +1542,19 @@ No match 0: \x{1111}\x{ae4c}\x{1111}\x{ae4c}\x{1111}\x{ae4c}\x{1111}\x{ae4c}X 0+ +/\X*Z/8Y + A\x{300} +No match + +/\X*(.)/8Y + A\x{1111}\x{ae4c}\x{1169} + 0: A\x{1111} + 1: \x{1111} + +/\X?abc/8Y +\xff\x7f\x00\x00\x03\x00\x41\xcc\x80\x41\x{300}\x61\x62\x63\x00\>06\? + 0: A\x{300}abc + /-- --/ /\x{1e9e}+/8i @@ -2139,11 +2146,303 @@ No match 0: 1234 123 No match - + /^\X*\w{4}/8 1234 0: 1234 123 No match - + +/^A\s+Z/8W + A\x{2005}Z + 0: A\x{2005}Z + A\x{85}\x{180e}\x{2005}Z + 0: A\x{85}\x{180e}\x{2005}Z + +/^A[\s]+Z/8W + A\x{2005}Z + 0: A\x{2005}Z + A\x{85}\x{180e}\x{2005}Z + 0: A\x{85}\x{180e}\x{2005}Z + +/^[[:graph:]]+$/8W + Letter:ABC + 0: Letter:ABC + Mark:\x{300}\x{1d172}\x{1d17b} + 0: Mark:\x{300}\x{1d172}\x{1d17b} + Number:9\x{660} + 0: Number:9\x{660} + Punctuation:\x{66a},; + 0: Punctuation:\x{66a},; + Symbol:\x{6de}<>\x{fffc} + 0: Symbol:\x{6de}<>\x{fffc} + Cf-property:\x{ad}\x{600}\x{601}\x{602}\x{603}\x{604}\x{6dd}\x{70f} + 0: Cf-property:\x{ad}\x{600}\x{601}\x{602}\x{603}\x{604}\x{6dd}\x{70f} + \x{200b}\x{200c}\x{200d}\x{200e}\x{200f} + 0: \x{200b}\x{200c}\x{200d}\x{200e}\x{200f} + \x{202a}\x{202b}\x{202c}\x{202d}\x{202e} + 0: \x{202a}\x{202b}\x{202c}\x{202d}\x{202e} + \x{2060}\x{2061}\x{2062}\x{2063}\x{2064} + 0: \x{2060}\x{2061}\x{2062}\x{2063}\x{2064} + \x{206a}\x{206b}\x{206c}\x{206d}\x{206e}\x{206f} + 0: \x{206a}\x{206b}\x{206c}\x{206d}\x{206e}\x{206f} + \x{feff} + 0: \x{feff} + \x{fff9}\x{fffa}\x{fffb} + 0: \x{fff9}\x{fffa}\x{fffb} + \x{110bd} + 0: \x{110bd} + \x{1d173}\x{1d174}\x{1d175}\x{1d176}\x{1d177}\x{1d178}\x{1d179}\x{1d17a} + 0: \x{1d173}\x{1d174}\x{1d175}\x{1d176}\x{1d177}\x{1d178}\x{1d179}\x{1d17a} + \x{e0001} + 0: \x{e0001} + \x{e0020}\x{e0030}\x{e0040}\x{e0050}\x{e0060}\x{e0070}\x{e007f} + 0: \x{e0020}\x{e0030}\x{e0040}\x{e0050}\x{e0060}\x{e0070}\x{e007f} + ** Failers +No match + \x{09} +No match + \x{0a} +No match + \x{1D} +No match + \x{20} +No match + \x{85} +No match + \x{a0} +No match + \x{61c} +No match + \x{1680} +No match + \x{180e} +No match + \x{2028} +No match + \x{2029} +No match + \x{202f} +No match + \x{2065} +No match + \x{2066} +No match + \x{2067} +No match + \x{2068} +No match + \x{2069} +No match + \x{3000} +No match + \x{e0002} +No match + \x{e001f} +No match + \x{e0080} +No match + +/^[[:print:]]+$/8W + Space: \x{a0} + 0: Space: \x{a0} + \x{1680}\x{2000}\x{2001}\x{2002}\x{2003}\x{2004}\x{2005} + 0: \x{1680}\x{2000}\x{2001}\x{2002}\x{2003}\x{2004}\x{2005} + \x{2006}\x{2007}\x{2008}\x{2009}\x{200a} + 0: \x{2006}\x{2007}\x{2008}\x{2009}\x{200a} + \x{202f}\x{205f} + 0: \x{202f}\x{205f} + \x{3000} + 0: \x{3000} + Letter:ABC + 0: Letter:ABC + Mark:\x{300}\x{1d172}\x{1d17b} + 0: Mark:\x{300}\x{1d172}\x{1d17b} + Number:9\x{660} + 0: Number:9\x{660} + Punctuation:\x{66a},; + 0: Punctuation:\x{66a},; + Symbol:\x{6de}<>\x{fffc} + 0: Symbol:\x{6de}<>\x{fffc} + Cf-property:\x{ad}\x{600}\x{601}\x{602}\x{603}\x{604}\x{6dd}\x{70f} + 0: Cf-property:\x{ad}\x{600}\x{601}\x{602}\x{603}\x{604}\x{6dd}\x{70f} + \x{180e} + 0: \x{180e} + \x{200b}\x{200c}\x{200d}\x{200e}\x{200f} + 0: \x{200b}\x{200c}\x{200d}\x{200e}\x{200f} + \x{202a}\x{202b}\x{202c}\x{202d}\x{202e} + 0: \x{202a}\x{202b}\x{202c}\x{202d}\x{202e} + \x{202f} + 0: \x{202f} + \x{2060}\x{2061}\x{2062}\x{2063}\x{2064} + 0: \x{2060}\x{2061}\x{2062}\x{2063}\x{2064} + \x{206a}\x{206b}\x{206c}\x{206d}\x{206e}\x{206f} + 0: \x{206a}\x{206b}\x{206c}\x{206d}\x{206e}\x{206f} + \x{feff} + 0: \x{feff} + \x{fff9}\x{fffa}\x{fffb} + 0: \x{fff9}\x{fffa}\x{fffb} + \x{110bd} + 0: \x{110bd} + \x{1d173}\x{1d174}\x{1d175}\x{1d176}\x{1d177}\x{1d178}\x{1d179}\x{1d17a} + 0: \x{1d173}\x{1d174}\x{1d175}\x{1d176}\x{1d177}\x{1d178}\x{1d179}\x{1d17a} + \x{e0001} + 0: \x{e0001} + \x{e0020}\x{e0030}\x{e0040}\x{e0050}\x{e0060}\x{e0070}\x{e007f} + 0: \x{e0020}\x{e0030}\x{e0040}\x{e0050}\x{e0060}\x{e0070}\x{e007f} + ** Failers + 0: ** Failers + \x{09} +No match + \x{1D} +No match + \x{85} +No match + \x{61c} +No match + \x{2028} +No match + \x{2029} +No match + \x{2065} +No match + \x{2066} +No match + \x{2067} +No match + \x{2068} +No match + \x{2069} +No match + \x{e0002} +No match + \x{e001f} +No match + \x{e0080} +No match + +/^[[:punct:]]+$/8W + \$+<=>^`|~ + 0: $+<=>^`|~ + !\"#%&'()*,-./:;?@[\\]_{} + 0: !"#%&'()*,-./:;?@[\]_{} + \x{a1}\x{a7} + 0: \x{a1}\x{a7} + \x{37e} + 0: \x{37e} + ** Failers +No match + abcde +No match + +/^[[:^graph:]]+$/8W + \x{09}\x{0a}\x{1D}\x{20}\x{85}\x{a0}\x{61c}\x{1680}\x{180e} + 0: \x{09}\x{0a}\x{1d} \x{85}\x{a0}\x{61c}\x{1680}\x{180e} + \x{2028}\x{2029}\x{202f}\x{2065}\x{2066}\x{2067}\x{2068}\x{2069} + 0: \x{2028}\x{2029}\x{202f}\x{2065}\x{2066}\x{2067}\x{2068}\x{2069} + \x{3000}\x{e0002}\x{e001f}\x{e0080} + 0: \x{3000}\x{e0002}\x{e001f}\x{e0080} + ** Failers +No match + Letter:ABC +No match + Mark:\x{300}\x{1d172}\x{1d17b} +No match + Number:9\x{660} +No match + Punctuation:\x{66a},; +No match + Symbol:\x{6de}<>\x{fffc} +No match + Cf-property:\x{ad}\x{600}\x{601}\x{602}\x{603}\x{604}\x{6dd}\x{70f} +No match + \x{200b}\x{200c}\x{200d}\x{200e}\x{200f} +No match + \x{202a}\x{202b}\x{202c}\x{202d}\x{202e} +No match + \x{2060}\x{2061}\x{2062}\x{2063}\x{2064} +No match + \x{206a}\x{206b}\x{206c}\x{206d}\x{206e}\x{206f} +No match + \x{feff} +No match + \x{fff9}\x{fffa}\x{fffb} +No match + \x{110bd} +No match + \x{1d173}\x{1d174}\x{1d175}\x{1d176}\x{1d177}\x{1d178}\x{1d179}\x{1d17a} +No match + \x{e0001} +No match + \x{e0020}\x{e0030}\x{e0040}\x{e0050}\x{e0060}\x{e0070}\x{e007f} +No match + +/^[[:^print:]]+$/8W + \x{09}\x{1D}\x{85}\x{61c}\x{2028}\x{2029}\x{2065}\x{2066}\x{2067} + 0: \x{09}\x{1d}\x{85}\x{61c}\x{2028}\x{2029}\x{2065}\x{2066}\x{2067} + \x{2068}\x{2069}\x{e0002}\x{e001f}\x{e0080} + 0: \x{2068}\x{2069}\x{e0002}\x{e001f}\x{e0080} + ** Failers +No match + Space: \x{a0} +No match + \x{1680}\x{2000}\x{2001}\x{2002}\x{2003}\x{2004}\x{2005} +No match + \x{2006}\x{2007}\x{2008}\x{2009}\x{200a} +No match + \x{202f}\x{205f} +No match + \x{3000} +No match + Letter:ABC +No match + Mark:\x{300}\x{1d172}\x{1d17b} +No match + Number:9\x{660} +No match + Punctuation:\x{66a},; +No match + Symbol:\x{6de}<>\x{fffc} +No match + Cf-property:\x{ad}\x{600}\x{601}\x{602}\x{603}\x{604}\x{6dd}\x{70f} +No match + \x{180e} +No match + \x{200b}\x{200c}\x{200d}\x{200e}\x{200f} +No match + \x{202a}\x{202b}\x{202c}\x{202d}\x{202e} +No match + \x{202f} +No match + \x{2060}\x{2061}\x{2062}\x{2063}\x{2064} +No match + \x{206a}\x{206b}\x{206c}\x{206d}\x{206e}\x{206f} +No match + \x{feff} +No match + \x{fff9}\x{fffa}\x{fffb} +No match + \x{110bd} +No match + \x{1d173}\x{1d174}\x{1d175}\x{1d176}\x{1d177}\x{1d178}\x{1d179}\x{1d17a} +No match + \x{e0001} +No match + \x{e0020}\x{e0030}\x{e0040}\x{e0050}\x{e0060}\x{e0070}\x{e007f} +No match + +/^[[:^punct:]]+$/8W + abcde + 0: abcde + ** Failers +No match + \$+<=>^`|~ +No match + !\"#%&'()*,-./:;?@[\\]_{} +No match + \x{a1}\x{a7} +No match + \x{37e} +No match + /-- End of testinput6 --/ diff --git a/pcre/testdata/testoutput7 b/pcre/testdata/testoutput7 index ddd96fc2edc..45ac72fd8d4 100644 --- a/pcre/testdata/testoutput7 +++ b/pcre/testdata/testoutput7 @@ -78,7 +78,7 @@ No need char /[\p{Nd}+-]+/8DZ ------------------------------------------------------------------ Bra - [+\-\p{Nd}]+ + [+\-\p{Nd}]++ Ket End ------------------------------------------------------------------ @@ -270,6 +270,20 @@ No need char End ------------------------------------------------------------------ +/^\p{Cf}/8 + \x{180e} + 0: \x{180e} + \x{061c} + 0: \x{61c} + \x{2066} + 0: \x{2066} + \x{2067} + 0: \x{2067} + \x{2068} + 0: \x{2068} + \x{2069} + 0: \x{2069} + /^\p{Cs}/8 \?\x{dfff} 0: \x{dfff} @@ -278,6 +292,22 @@ No match \x{09f} No match +/^\p{Mn}/8 + \x{1a1b} + 0: \x{1a1b} + +/^\p{Pe}/8 + \x{2309} + 0: \x{2309} + \x{230b} + 0: \x{230b} + +/^\p{Ps}/8 + \x{2308} + 0: \x{2308} + \x{230a} + 0: \x{230a} + /^\p{Sc}+/8 $\x{a2}\x{a3}\x{a4}\x{a5}\x{a6} 0: $\x{a2}\x{a3}\x{a4}\x{a5} @@ -297,8 +327,6 @@ No match 0: \x{a0} \x{1680} 0: \x{1680} - \x{180e} - 0: \x{180e} \x{2000} 0: \x{2000} \x{2001} @@ -310,8 +338,9 @@ No match \x{200d} No match -/-- These four are here rather than in test 6 because Perl has problems with - the negative versions of the properties. --/ +/-- These are here rather than in test 6 because Perl has problems with + the negative versions of the properties and behaves has changed how + it behaves for caseless matching. --/ /\p{^Lu}/8i 1234 @@ -351,6 +380,16 @@ No match \x{1d00} No match +/\p{Lu}/8i + A + 0: A + aZ + 0: Z + ** Failers + 0: F + abc +No match + /[\x{c0}\x{391}]/8i \x{c0} 0: \x{c0} @@ -501,7 +540,7 @@ No match /^>\p{Xsp}+/8 > \x{09}\x{0a}\x{0c}\x{0d}\x{a0}\x{1680}\x{2028}\x{0b} - 0: > \x{09}\x{0a}\x{0c}\x{0d}\x{a0}\x{1680}\x{2028} + 0: > \x{09}\x{0a}\x{0c}\x{0d}\x{a0}\x{1680}\x{2028}\x{0b} /^>\p{Xsp}+?/8 >\x{1680}\x{2028}\x{0b} @@ -509,11 +548,11 @@ No match /^>\p{Xsp}*/8 > \x{09}\x{0a}\x{0c}\x{0d}\x{a0}\x{1680}\x{2028}\x{0b} - 0: > \x{09}\x{0a}\x{0c}\x{0d}\x{a0}\x{1680}\x{2028} + 0: > \x{09}\x{0a}\x{0c}\x{0d}\x{a0}\x{1680}\x{2028}\x{0b} /^>\p{Xsp}{2,9}/8 > \x{09}\x{0a}\x{0c}\x{0d}\x{a0}\x{1680}\x{2028}\x{0b} - 0: > \x{09}\x{0a}\x{0c}\x{0d}\x{a0}\x{1680}\x{2028} + 0: > \x{09}\x{0a}\x{0c}\x{0d}\x{a0}\x{1680}\x{2028}\x{0b} /^>\p{Xsp}{2,9}?/8 > \x{09}\x{0a}\x{0c}\x{0d}\x{a0}\x{1680}\x{2028}\x{0b} @@ -525,7 +564,7 @@ No match /^>[\p{Xsp}]+/8 > \x{09}\x{0a}\x{0c}\x{0d}\x{a0}\x{1680}\x{2028}\x{0b} - 0: > \x{09}\x{0a}\x{0c}\x{0d}\x{a0}\x{1680}\x{2028} + 0: > \x{09}\x{0a}\x{0c}\x{0d}\x{a0}\x{1680}\x{2028}\x{0b} /^>\p{Xps}/8 >\x{1680}\x{2028}\x{0b} @@ -820,7 +859,7 @@ No match /[[:graph:]]/WBZ ------------------------------------------------------------------ Bra - [!-~] + [[:graph:]] Ket End ------------------------------------------------------------------ @@ -828,7 +867,7 @@ No match /[[:print:]]/WBZ ------------------------------------------------------------------ Bra - [ -~] + [[:print:]] Ket End ------------------------------------------------------------------ @@ -836,7 +875,7 @@ No match /[[:punct:]]/WBZ ------------------------------------------------------------------ Bra - [!-/:-@[-`{-~] + [[:punct:]] Ket End ------------------------------------------------------------------ @@ -910,7 +949,7 @@ No match /[[:^alpha:][:^cntrl:]]+/8WBZ ------------------------------------------------------------------ Bra - [ -~\x80-\xff\P{L}]+ + [ -~\x80-\xff\P{L}]++ Ket End ------------------------------------------------------------------ @@ -922,7 +961,7 @@ No match /[[:^cntrl:][:^alpha:]]+/8WBZ ------------------------------------------------------------------ Bra - [ -~\x80-\xff\P{L}]+ + [ -~\x80-\xff\P{L}]++ Ket End ------------------------------------------------------------------ @@ -934,7 +973,7 @@ No match /[[:alpha:]]+/8WBZ ------------------------------------------------------------------ Bra - [\p{L}]+ + [\p{L}]++ Ket End ------------------------------------------------------------------ @@ -944,7 +983,7 @@ No match /[[:^alpha:]\S]+/8WBZ ------------------------------------------------------------------ Bra - [\P{L}\P{Xsp}]+ + [\P{L}\P{Xsp}]++ Ket End ------------------------------------------------------------------ @@ -956,7 +995,7 @@ No match /[^\d]+/8WBZ ------------------------------------------------------------------ Bra - [^\p{Nd}]+ + [^\p{Nd}]++ Ket End ------------------------------------------------------------------ @@ -1070,8 +1109,8 @@ No match prop Nd B+ prop N *+ - B+ - prop Nd * + B++ + prop Nd *+ Ket End ------------------------------------------------------------------ @@ -1347,7 +1386,7 @@ Need char = 'B' (caseless) /[\x{3a3}]+/8iBZ ------------------------------------------------------------------ Bra - clist 03a3 03c2 03c3 + + clist 03a3 03c2 03c3 ++ Ket End ------------------------------------------------------------------ @@ -1355,7 +1394,7 @@ Need char = 'B' (caseless) /[^\x{3a3}]+/8iBZ ------------------------------------------------------------------ Bra - not clist 03a3 03c2 03c3 + + not clist 03a3 03c2 03c3 ++ Ket End ------------------------------------------------------------------ @@ -1577,5 +1616,651 @@ No match No match \x{1234}abc No match + +/-- Some auto-possessification tests --/ + +/\pN+\z/BZ +------------------------------------------------------------------ + Bra + prop N ++ + \z + Ket + End +------------------------------------------------------------------ + +/\PN+\z/BZ +------------------------------------------------------------------ + Bra + notprop N ++ + \z + Ket + End +------------------------------------------------------------------ + +/\pN+/BZ +------------------------------------------------------------------ + Bra + prop N ++ + Ket + End +------------------------------------------------------------------ + +/\PN+/BZ +------------------------------------------------------------------ + Bra + notprop N ++ + Ket + End +------------------------------------------------------------------ + +/\p{Any}+\p{Any} \p{Any}+\P{Any} \p{Any}+\p{L&} \p{Any}+\p{L} \p{Any}+\p{Lu} \p{Any}+\p{Han} \p{Any}+\p{Xan} \p{Any}+\p{Xsp} \p{Any}+\p{Xps} \p{Xwd}+\p{Any} \p{Any}+\p{Xuc}/BWZx +------------------------------------------------------------------ + Bra + prop Any + + prop Any + prop Any + + notprop Any + prop Any + + prop L& + prop Any + + prop L + prop Any + + prop Lu + prop Any + + prop Han + prop Any + + prop Xan + prop Any + + prop Xsp + prop Any + + prop Xps + prop Xwd + + prop Any + prop Any + + prop Xuc + Ket + End +------------------------------------------------------------------ + +/\p{L&}+\p{Any} \p{L&}+\p{L&} \P{L&}+\p{L&} \p{L&}+\p{L} \p{L&}+\p{Lu} \p{L&}+\p{Han} \p{L&}+\p{Xan} \p{L&}+\P{Xan} \p{L&}+\p{Xsp} \p{L&}+\p{Xps} \p{Xwd}+\p{L&} \p{L&}+\p{Xuc}/BWZx +------------------------------------------------------------------ + Bra + prop L& + + prop Any + prop L& + + prop L& + notprop L& ++ + prop L& + prop L& + + prop L + prop L& + + prop Lu + prop L& + + prop Han + prop L& + + prop Xan + prop L& ++ + notprop Xan + prop L& ++ + prop Xsp + prop L& ++ + prop Xps + prop Xwd + + prop L& + prop L& + + prop Xuc + Ket + End +------------------------------------------------------------------ + +/\p{N}+\p{Any} \p{N}+\p{L&} \p{N}+\p{L} \p{N}+\P{L} \p{N}+\P{N} \p{N}+\p{Lu} \p{N}+\p{Han} \p{N}+\p{Xan} \p{N}+\p{Xsp} \p{N}+\p{Xps} \p{Xwd}+\p{N} \p{N}+\p{Xuc}/BWZx +------------------------------------------------------------------ + Bra + prop N + + prop Any + prop N + + prop L& + prop N ++ + prop L + prop N + + notprop L + prop N ++ + notprop N + prop N ++ + prop Lu + prop N + + prop Han + prop N + + prop Xan + prop N ++ + prop Xsp + prop N ++ + prop Xps + prop Xwd + + prop N + prop N + + prop Xuc + Ket + End +------------------------------------------------------------------ + +/\p{Lu}+\p{Any} \p{Lu}+\p{L&} \p{Lu}+\p{L} \p{Lu}+\p{Lu} \P{Lu}+\p{Lu} \p{Lu}+\p{Nd} \p{Lu}+\P{Nd} \p{Lu}+\p{Han} \p{Lu}+\p{Xan} \p{Lu}+\p{Xsp} \p{Lu}+\p{Xps} \p{Xwd}+\p{Lu} \p{Lu}+\p{Xuc}/BWZx +------------------------------------------------------------------ + Bra + prop Lu + + prop Any + prop Lu + + prop L& + prop Lu + + prop L + prop Lu + + prop Lu + notprop Lu ++ + prop Lu + prop Lu ++ + prop Nd + prop Lu + + notprop Nd + prop Lu + + prop Han + prop Lu + + prop Xan + prop Lu ++ + prop Xsp + prop Lu ++ + prop Xps + prop Xwd + + prop Lu + prop Lu + + prop Xuc + Ket + End +------------------------------------------------------------------ + +/\p{Han}+\p{Lu} \p{Han}+\p{L&} \p{Han}+\p{L} \p{Han}+\p{Lu} \p{Han}+\p{Arabic} \p{Arabic}+\p{Arabic} \p{Han}+\p{Xan} \p{Han}+\p{Xsp} \p{Han}+\p{Xps} \p{Xwd}+\p{Han} \p{Han}+\p{Xuc}/BWZx +------------------------------------------------------------------ + Bra + prop Han + + prop Lu + prop Han + + prop L& + prop Han + + prop L + prop Han + + prop Lu + prop Han ++ + prop Arabic + prop Arabic + + prop Arabic + prop Han + + prop Xan + prop Han + + prop Xsp + prop Han + + prop Xps + prop Xwd + + prop Han + prop Han + + prop Xuc + Ket + End +------------------------------------------------------------------ + +/\p{Xan}+\p{Any} \p{Xan}+\p{L&} \P{Xan}+\p{L&} \p{Xan}+\p{L} \p{Xan}+\p{Lu} \p{Xan}+\p{Han} \p{Xan}+\p{Xan} \p{Xan}+\P{Xan} \p{Xan}+\p{Xsp} \p{Xan}+\p{Xps} \p{Xwd}+\p{Xan} \p{Xan}+\p{Xuc}/BWZx +------------------------------------------------------------------ + Bra + prop Xan + + prop Any + prop Xan + + prop L& + notprop Xan ++ + prop L& + prop Xan + + prop L + prop Xan + + prop Lu + prop Xan + + prop Han + prop Xan + + prop Xan + prop Xan ++ + notprop Xan + prop Xan ++ + prop Xsp + prop Xan ++ + prop Xps + prop Xwd + + prop Xan + prop Xan + + prop Xuc + Ket + End +------------------------------------------------------------------ + +/\p{Xsp}+\p{Any} \p{Xsp}+\p{L&} \p{Xsp}+\p{L} \p{Xsp}+\p{Lu} \p{Xsp}+\p{Han} \p{Xsp}+\p{Xan} \p{Xsp}+\p{Xsp} \P{Xsp}+\p{Xsp} \p{Xsp}+\p{Xps} \p{Xwd}+\p{Xsp} \p{Xsp}+\p{Xuc}/BWZx +------------------------------------------------------------------ + Bra + prop Xsp + + prop Any + prop Xsp ++ + prop L& + prop Xsp ++ + prop L + prop Xsp ++ + prop Lu + prop Xsp + + prop Han + prop Xsp ++ + prop Xan + prop Xsp + + prop Xsp + notprop Xsp ++ + prop Xsp + prop Xsp + + prop Xps + prop Xwd ++ + prop Xsp + prop Xsp + + prop Xuc + Ket + End +------------------------------------------------------------------ + +/\p{Xwd}+\p{Any} \p{Xwd}+\p{L&} \p{Xwd}+\p{L} \p{Xwd}+\p{Lu} \p{Xwd}+\p{Han} \p{Xwd}+\p{Xan} \p{Xwd}+\p{Xsp} \p{Xwd}+\p{Xps} \p{Xwd}+\p{Xwd} \p{Xwd}+\P{Xwd} \p{Xwd}+\p{Xuc}/BWZx +------------------------------------------------------------------ + Bra + prop Xwd + + prop Any + prop Xwd + + prop L& + prop Xwd + + prop L + prop Xwd + + prop Lu + prop Xwd + + prop Han + prop Xwd + + prop Xan + prop Xwd ++ + prop Xsp + prop Xwd ++ + prop Xps + prop Xwd + + prop Xwd + prop Xwd ++ + notprop Xwd + prop Xwd + + prop Xuc + Ket + End +------------------------------------------------------------------ + +/\p{Xuc}+\p{Any} \p{Xuc}+\p{L&} \p{Xuc}+\p{L} \p{Xuc}+\p{Lu} \p{Xuc}+\p{Han} \p{Xuc}+\p{Xan} \p{Xuc}+\p{Xsp} \p{Xuc}+\p{Xps} \p{Xwd}+\p{Xuc} \p{Xuc}+\p{Xuc} \p{Xuc}+\P{Xuc}/BWZx +------------------------------------------------------------------ + Bra + prop Xuc + + prop Any + prop Xuc + + prop L& + prop Xuc + + prop L + prop Xuc + + prop Lu + prop Xuc + + prop Han + prop Xuc + + prop Xan + prop Xuc + + prop Xsp + prop Xuc + + prop Xps + prop Xwd + + prop Xuc + prop Xuc + + prop Xuc + prop Xuc ++ + notprop Xuc + Ket + End +------------------------------------------------------------------ + +/\p{N}+\p{Ll} \p{N}+\p{Nd} \p{N}+\P{Nd}/BWZx +------------------------------------------------------------------ + Bra + prop N ++ + prop Ll + prop N + + prop Nd + prop N + + notprop Nd + Ket + End +------------------------------------------------------------------ + +/\p{Xan}+\p{L} \p{Xan}+\p{N} \p{Xan}+\p{C} \p{Xan}+\P{L} \P{Xan}+\p{N} \p{Xan}+\P{C}/BWZx +------------------------------------------------------------------ + Bra + prop Xan + + prop L + prop Xan + + prop N + prop Xan ++ + prop C + prop Xan + + notprop L + notprop Xan ++ + prop N + prop Xan + + notprop C + Ket + End +------------------------------------------------------------------ + +/\p{L}+\p{Xan} \p{N}+\p{Xan} \p{C}+\p{Xan} \P{L}+\p{Xan} \p{N}+\p{Xan} \P{C}+\p{Xan} \p{L}+\P{Xan}/BWZx +------------------------------------------------------------------ + Bra + prop L + + prop Xan + prop N + + prop Xan + prop C ++ + prop Xan + notprop L + + prop Xan + prop N + + prop Xan + notprop C + + prop Xan + prop L ++ + notprop Xan + Ket + End +------------------------------------------------------------------ + +/\p{Xan}+\p{Lu} \p{Xan}+\p{Nd} \p{Xan}+\p{Cc} \p{Xan}+\P{Ll} \P{Xan}+\p{No} \p{Xan}+\P{Cf}/BWZx +------------------------------------------------------------------ + Bra + prop Xan + + prop Lu + prop Xan + + prop Nd + prop Xan ++ + prop Cc + prop Xan + + notprop Ll + notprop Xan ++ + prop No + prop Xan + + notprop Cf + Ket + End +------------------------------------------------------------------ + +/\p{Lu}+\p{Xan} \p{Nd}+\p{Xan} \p{Cs}+\p{Xan} \P{Lt}+\p{Xan} \p{Nl}+\p{Xan} \P{Cc}+\p{Xan} \p{Lt}+\P{Xan}/BWZx +------------------------------------------------------------------ + Bra + prop Lu + + prop Xan + prop Nd + + prop Xan + prop Cs ++ + prop Xan + notprop Lt + + prop Xan + prop Nl + + prop Xan + notprop Cc + + prop Xan + prop Lt ++ + notprop Xan + Ket + End +------------------------------------------------------------------ + +/\w+\p{P} \w+\p{Po} \w+\s \p{Xan}+\s \s+\p{Xan} \s+\w/BWZx +------------------------------------------------------------------ + Bra + prop Xwd + + prop P + prop Xwd + + prop Po + prop Xwd ++ + prop Xsp + prop Xan ++ + prop Xsp + prop Xsp ++ + prop Xan + prop Xsp ++ + prop Xwd + Ket + End +------------------------------------------------------------------ + +/\w+\P{P} \W+\p{Po} \w+\S \P{Xan}+\s \s+\P{Xan} \s+\W/BWZx +------------------------------------------------------------------ + Bra + prop Xwd + + notprop P + notprop Xwd + + prop Po + prop Xwd + + notprop Xsp + notprop Xan + + prop Xsp + prop Xsp + + notprop Xan + prop Xsp + + notprop Xwd + Ket + End +------------------------------------------------------------------ + +/\w+\p{Po} \w+\p{Pc} \W+\p{Po} \W+\p{Pc} \w+\P{Po} \w+\P{Pc}/BWZx +------------------------------------------------------------------ + Bra + prop Xwd + + prop Po + prop Xwd ++ + prop Pc + notprop Xwd + + prop Po + notprop Xwd + + prop Pc + prop Xwd + + notprop Po + prop Xwd + + notprop Pc + Ket + End +------------------------------------------------------------------ + +/\p{Nl}+\p{Xan} \P{Nl}+\p{Xan} \p{Nl}+\P{Xan} \P{Nl}+\P{Xan}/BWZx +------------------------------------------------------------------ + Bra + prop Nl + + prop Xan + notprop Nl + + prop Xan + prop Nl ++ + notprop Xan + notprop Nl + + notprop Xan + Ket + End +------------------------------------------------------------------ + +/\p{Xan}+\p{Nl} \P{Xan}+\p{Nl} \p{Xan}+\P{Nl} \P{Xan}+\P{Nl}/BWZx +------------------------------------------------------------------ + Bra + prop Xan + + prop Nl + notprop Xan ++ + prop Nl + prop Xan + + notprop Nl + notprop Xan + + notprop Nl + Ket + End +------------------------------------------------------------------ + +/\p{Xan}+\p{Nd} \P{Xan}+\p{Nd} \p{Xan}+\P{Nd} \P{Xan}+\P{Nd}/BWZx +------------------------------------------------------------------ + Bra + prop Xan + + prop Nd + notprop Xan ++ + prop Nd + prop Xan + + notprop Nd + notprop Xan + + notprop Nd + Ket + End +------------------------------------------------------------------ + +/-- End auto-possessification tests --/ + +/\w+/8CWBZ +------------------------------------------------------------------ + Bra + Callout 255 0 3 + prop Xwd ++ + Callout 255 3 0 + Ket + End +------------------------------------------------------------------ + abcd +--->abcd + +0 ^ \w+ + +3 ^ ^ + 0: abcd + +/[\p{N}]?+/BZO +------------------------------------------------------------------ + Bra + [\p{N}]?+ + Ket + End +------------------------------------------------------------------ + +/[\p{L}ab]{2,3}+/BZO +------------------------------------------------------------------ + Bra + [ab\p{L}]{2,3}+ + Ket + End +------------------------------------------------------------------ + +/\D+\X \d+\X \S+\X \s+\X \W+\X \w+\X \C+\X \R+\X \H+\X \h+\X \V+\X \v+\X a+\X \n+\X .+\X/BZx +------------------------------------------------------------------ + Bra + \D+ + extuni + \d+ + extuni + \S+ + extuni + \s+ + extuni + \W+ + extuni + \w+ + extuni + AllAny+ + extuni + \R+ + extuni + \H+ + extuni + \h+ + extuni + \V+ + extuni + \v+ + extuni + a+ + extuni + \x0a+ + extuni + Any+ + extuni + Ket + End +------------------------------------------------------------------ + +/.+\X/BZxs +------------------------------------------------------------------ + Bra + AllAny+ + extuni + Ket + End +------------------------------------------------------------------ + +/\X+$/BZxm +------------------------------------------------------------------ + Bra + extuni+ + /m $ + Ket + End +------------------------------------------------------------------ + +/\X+\D \X+\d \X+\S \X+\s \X+\W \X+\w \X+. \X+\C \X+\R \X+\H \X+\h \X+\V \X+\v \X+\X \X+\Z \X+\z \X+$/BZx +------------------------------------------------------------------ + Bra + extuni+ + \D + extuni+ + \d + extuni+ + \S + extuni+ + \s + extuni+ + \W + extuni+ + \w + extuni+ + Any + extuni+ + AllAny + extuni+ + \R + extuni+ + \H + extuni+ + \h + extuni+ + \V + extuni+ + \v + extuni+ + extuni + extuni+ + \Z + extuni++ + \z + extuni+ + $ + Ket + End +------------------------------------------------------------------ + +/\d+\s{0,5}=\s*\S?=\w{0,4}\W*/8WBZ +------------------------------------------------------------------ + Bra + prop Nd ++ + prop Xsp {0,5}+ + = + prop Xsp *+ + notprop Xsp ? + = + prop Xwd {0,4}+ + notprop Xwd *+ + Ket + End +------------------------------------------------------------------ /-- End of testinput7 --/ diff --git a/pcre/testdata/testoutput8 b/pcre/testdata/testoutput8 index 75affbe2d4c..bb68d3e6452 100644 --- a/pcre/testdata/testoutput8 +++ b/pcre/testdata/testoutput8 @@ -1,5 +1,8 @@ -/-- This set of tests check the DFA matching functionality of pcre_dfa_exec(). - The -dfa flag must be used with pcretest when running it. --/ +/-- This set of tests check the DFA matching functionality of pcre_dfa_exec(), + excluding UTF and Unicode property support. The -dfa flag must be used with + pcretest when running it. --/ + +< forbid 8W /abc/ abc @@ -25,7 +28,7 @@ No match ab No match -/a*/ +/a*/O a 0: a 1: @@ -341,7 +344,7 @@ No match axyzq No match -/[^a]+/ +/[^a]+/O bac 0: b bcdefax @@ -359,7 +362,7 @@ No match aaaaa No match -/[^a]*/ +/[^a]*/O bac 0: b 1: @@ -380,7 +383,7 @@ No match aaaaa 0: -/[^a]{3,5}/ +/[^a]{3,5}/O xyz 0: xyz awxyza @@ -408,29 +411,18 @@ No match /\d*/ 1234b567 0: 1234 - 1: 123 - 2: 12 - 3: 1 - 4: xyz 0: /\D*/ a1234b567 0: a - 1: xyz 0: xyz - 1: xy - 2: x - 3: /\d+/ ab1234c56 0: 1234 - 1: 123 - 2: 12 - 3: 1 *** Failers No match xyz @@ -439,19 +431,8 @@ No match /\D+/ ab123c56 0: ab - 1: a *** Failers 0: *** Failers - 1: *** Failer - 2: *** Faile - 3: *** Fail - 4: *** Fai - 5: *** Fa - 6: *** F - 7: *** - 8: *** - 9: ** -10: * 789 No match @@ -478,9 +459,6 @@ No match /a+/ aaaa 0: aaaa - 1: aaa - 2: aa - 3: a /^.*xyz/ xyz @@ -886,9 +864,6 @@ No match 0: aaabcd 0: aaa - 1: aa - 2: a - 3: xyz 0: xyz 1: @@ -1577,18 +1552,6 @@ No match /^[.^$|()*+?{,}]+/ .^\$(*+)|{?,?} 0: .^$(*+)|{?,?} - 1: .^$(*+)|{?,? - 2: .^$(*+)|{?, - 3: .^$(*+)|{? - 4: .^$(*+)|{ - 5: .^$(*+)| - 6: .^$(*+) - 7: .^$(*+ - 8: .^$(* - 9: .^$( -10: .^$ -11: .^ -12: . /^a*\w/ z @@ -1744,38 +1707,16 @@ No match /foo(?!bar)(.*)/ foobar is foolish see? 0: foolish see? - 1: foolish see - 2: foolish se - 3: foolish s - 4: foolish - 5: foolish - 6: foolis - 7: fooli - 8: fool - 9: foo /(?:(?!foo)...|^.{0,2})bar(.*)/ foobar crowbar etc 0: rowbar etc - 1: rowbar et - 2: rowbar e - 3: rowbar - 4: rowbar barrel 0: barrel - 1: barre - 2: barr - 3: bar 2barrel 0: 2barrel - 1: 2barre - 2: 2barr - 3: 2bar A barrel 0: A barrel - 1: A barre - 2: A barr - 3: A bar /^(\D*)(?=\d)(?!123)/ abc456 @@ -1820,7 +1761,7 @@ No match the abc No match -/^[ab]{1,3}(ab*|b)/ +/^[ab]{1,3}(ab*|b)/O aabbbbb 0: aabbbbb 1: aabbbb @@ -1829,7 +1770,7 @@ No match 4: aab 5: aa -/^[ab]{1,3}?(ab*|b)/ +/^[ab]{1,3}?(ab*|b)/O aabbbbb 0: aabbbbb 1: aabbbb @@ -1838,7 +1779,7 @@ No match 4: aab 5: aa -/^[ab]{1,3}?(ab*?|b)/ +/^[ab]{1,3}?(ab*?|b)/O aabbbbb 0: aabbbbb 1: aabbbb @@ -1847,7 +1788,7 @@ No match 4: aab 5: aa -/^[ab]{1,3}(ab*?|b)/ +/^[ab]{1,3}(ab*?|b)/O aabbbbb 0: aabbbbb 1: aabbbb @@ -2705,10 +2646,6 @@ No match /\0*/ \0\0\0\0 0: \x00\x00\x00\x00 - 1: \x00\x00\x00 - 2: \x00\x00 - 3: \x00 - 4: /A\x0{2,3}Z/ The A\x0\x0Z @@ -2760,56 +2697,14 @@ No match /([^.]*)\.([^:]*):[T ]+(.*)/ track1.title:TBlah blah blah 0: track1.title:TBlah blah blah - 1: track1.title:TBlah blah bla - 2: track1.title:TBlah blah bl - 3: track1.title:TBlah blah b - 4: track1.title:TBlah blah - 5: track1.title:TBlah blah - 6: track1.title:TBlah bla - 7: track1.title:TBlah bl - 8: track1.title:TBlah b - 9: track1.title:TBlah -10: track1.title:TBlah -11: track1.title:TBla -12: track1.title:TBl -13: track1.title:TB -14: track1.title:T /([^.]*)\.([^:]*):[T ]+(.*)/i track1.title:TBlah blah blah 0: track1.title:TBlah blah blah - 1: track1.title:TBlah blah bla - 2: track1.title:TBlah blah bl - 3: track1.title:TBlah blah b - 4: track1.title:TBlah blah - 5: track1.title:TBlah blah - 6: track1.title:TBlah bla - 7: track1.title:TBlah bl - 8: track1.title:TBlah b - 9: track1.title:TBlah -10: track1.title:TBlah -11: track1.title:TBla -12: track1.title:TBl -13: track1.title:TB -14: track1.title:T /([^.]*)\.([^:]*):[t ]+(.*)/i track1.title:TBlah blah blah 0: track1.title:TBlah blah blah - 1: track1.title:TBlah blah bla - 2: track1.title:TBlah blah bl - 3: track1.title:TBlah blah b - 4: track1.title:TBlah blah - 5: track1.title:TBlah blah - 6: track1.title:TBlah bla - 7: track1.title:TBlah bl - 8: track1.title:TBlah b - 9: track1.title:TBlah -10: track1.title:TBlah -11: track1.title:TBla -12: track1.title:TBl -13: track1.title:TB -14: track1.title:T /^[W-c]+$/ WXY_^abc @@ -2882,13 +2777,10 @@ No match 0: b c::b 0: :: - 1: : /[-az]+/ az- 0: az- - 1: az - 2: a *** Failers 0: a b @@ -2897,8 +2789,6 @@ No match /[az-]+/ za- 0: za- - 1: za - 2: z *** Failers 0: a b @@ -2907,8 +2797,6 @@ No match /[a\-z]+/ a-z 0: a-z - 1: a- - 2: a *** Failers 0: a b @@ -2917,20 +2805,10 @@ No match /[a-z]+/ abcdxyz 0: abcdxyz - 1: abcdxy - 2: abcdx - 3: abcd - 4: abc - 5: ab - 6: a /[\d-]+/ 12-34 0: 12-34 - 1: 12-3 - 2: 12- - 3: 12 - 4: 1 *** Failers No match aaa @@ -2939,11 +2817,6 @@ No match /[\d-z]+/ 12-34z 0: 12-34z - 1: 12-34 - 2: 12-3 - 3: 12- - 4: 12 - 5: 1 *** Failers No match aaa @@ -3027,18 +2900,22 @@ No match abc\100\60 0: abc@0 -/abc\81/ - abc\081 - 0: abc\x0081 - abc\0\x38\x31 - 0: abc\x0081 - -/abc\91/ - abc\091 - 0: abc\x0091 - abc\0\x39\x31 - 0: abc\x0091 - +/^A\8B\9C$/ + A8B9C + 0: A8B9C + *** Failers +No match + A\08B\09C +No match + +/^[A\8B\9C]+$/ + A8B9C + 0: A8B9C + *** Failers +No match + A8B9C\x00 +No match + /(a)(b)(c)(d)(e)(f)(g)(h)(i)(j)(k)\12\123/ abcdefghijk\12S 0: abcdefghijk\x0aS @@ -3077,16 +2954,13 @@ No match 1: baNOTccc 2: baNOTcc 3: baNOTc - 4: baNOT baNOTcccd 0: baNOTccc 1: baNOTcc 2: baNOTc - 3: baNOT baNOTccd 0: baNOTcc 1: baNOTc - 2: baNOT bacccd 0: baccc *** Failers @@ -3096,7 +2970,6 @@ No match 3: *** Fail 4: *** Fai 5: *** Fa - 6: *** F anything No match b\bc @@ -3115,23 +2988,14 @@ No match /[^a]+/ AAAaAbc 0: AAA - 1: AA - 2: A /[^a]+/i AAAaAbc 0: bc - 1: b /[^a]+/ bbb\nccc 0: bbb\x0accc - 1: bbb\x0acc - 2: bbb\x0ac - 3: bbb\x0a - 4: bbb - 5: bb - 6: b /[^k]$/ abc @@ -3208,20 +3072,8 @@ No match /(\.\d\d[1-9]?)\d+/ 1.230003938 0: .230003938 - 1: .23000393 - 2: .2300039 - 3: .230003 - 4: .23000 - 5: .2300 - 6: .230 1.875000282 0: .875000282 - 1: .87500028 - 2: .8750002 - 3: .875000 - 4: .87500 - 5: .8750 - 6: .875 1.235 0: .235 @@ -3243,10 +3095,6 @@ No match /\b(foo)\s+(\w+)/i Food is on the foo table 0: foo table - 1: foo tabl - 2: foo tab - 3: foo ta - 4: foo t /foo(.*)bar/ The food is under the bar in the barn. @@ -3258,7 +3106,7 @@ No match 0: food is under the bar in the bar 1: food is under the bar -/(.*)(\d*)/ +/(.*)(\d*)/O I have 2 numbers: 53147 Matched, but offsets vector is too small to show all matches 0: I have 2 numbers: 53147 @@ -3287,13 +3135,9 @@ Matched, but offsets vector is too small to show all matches /(.*)(\d+)/ I have 2 numbers: 53147 0: I have 2 numbers: 53147 - 1: I have 2 numbers: 5314 - 2: I have 2 numbers: 531 - 3: I have 2 numbers: 53 - 4: I have 2 numbers: 5 - 5: I have 2 + 1: I have 2 -/(.*?)(\d*)/ +/(.*?)(\d*)/O I have 2 numbers: 53147 Matched, but offsets vector is too small to show all matches 0: I have 2 numbers: 53147 @@ -3322,11 +3166,7 @@ Matched, but offsets vector is too small to show all matches /(.*?)(\d+)/ I have 2 numbers: 53147 0: I have 2 numbers: 53147 - 1: I have 2 numbers: 5314 - 2: I have 2 numbers: 531 - 3: I have 2 numbers: 53 - 4: I have 2 numbers: 5 - 5: I have 2 + 1: I have 2 /(.*)(\d+)$/ I have 2 numbers: 53147 @@ -3738,13 +3578,8 @@ No match 0: a ab 0: ab - 1: a abbbb 0: abbbb - 1: abbb - 2: abb - 3: ab - 4: a *** Failers 0: a bbbbb @@ -3930,19 +3765,8 @@ No match /(?>(\.\d\d[1-9]?))\d+/ 1.230003938 0: .230003938 - 1: .23000393 - 2: .2300039 - 3: .230003 - 4: .23000 - 5: .2300 - 6: .230 1.875000282 0: .875000282 - 1: .87500028 - 2: .8750002 - 3: .875000 - 4: .87500 - 5: .8750 *** Failers No match 1.235 @@ -4561,7 +4385,6 @@ No match /.{3,4}/ abbbbc 0: abbb - 1: abb /ab{0,}bc/ abbbbc @@ -4929,9 +4752,6 @@ No match /[^ab]*/ cde 0: cde - 1: cd - 2: c - 3: /abc/ *** Failers @@ -4966,7 +4786,6 @@ No match /ab*/ xabyabbbz 0: ab - 1: a xayabbbz 0: a @@ -4995,8 +4814,7 @@ No match /a([bc]*)c*/ abc 0: abc - 1: ab - 2: a + 1: a /a([bc]*)(c*d)/ abcd @@ -5033,10 +4851,6 @@ No match /[a-zA-Z_][a-zA-Z0-9_]*/ alpha 0: alpha - 1: alph - 2: alp - 3: al - 4: a /^a(bc+|b[eh])g|.h$/ abh @@ -5079,8 +4893,6 @@ No match /(.*)c(.*)/ abcde 0: abcde - 1: abcd - 2: abc /\((.*), (.*)\)/ (a, b) @@ -5395,9 +5207,6 @@ No match /[^ab]*/i CDE 0: CDE - 1: CD - 2: C - 3: /abc/i @@ -5427,7 +5236,6 @@ No match /ab*/i XABYABBBZ 0: AB - 1: A XAYABBBZ 0: A @@ -5458,8 +5266,7 @@ No match /a([bc]*)c*/i ABC 0: ABC - 1: AB - 2: A + 1: A /a([bc]*)(c*d)/i ABCD @@ -5490,10 +5297,6 @@ No match /[a-zA-Z_][a-zA-Z0-9_]*/i ALPHA 0: ALPHA - 1: ALPH - 2: ALP - 3: AL - 4: A /^a(bc+|b[eh])g|.h$/i ABH @@ -5546,8 +5349,6 @@ No match /(.*)c(.*)/i ABCDE 0: ABCDE - 1: ABCD - 2: ABC /\((.*), (.*)\)/i (A, B) @@ -6052,17 +5853,14 @@ No match /([[:]+)/ a:[b]: 0: :[ - 1: : /([[=]+)/ a=[b]= 0: =[ - 1: = /([[.]+)/ a.[b]. 0: .[ - 1: . /((?>a+)b)/ aaab @@ -6196,26 +5994,12 @@ No match /a*/g abbab 0: a - 1: 0: 0: 0: a - 1: 0: 0: -/^[a-\d]/ - abcde - 0: a - -things - 0: - - 0digit - 0: 0 - *** Failers -No match - bcdef -No match - /^[\d-a]/ abcde 0: a @@ -6231,36 +6015,22 @@ No match /[[:space:]]+/ > \x09\x0a\x0c\x0d\x0b< 0: \x09\x0a\x0c\x0d\x0b - 1: \x09\x0a\x0c\x0d - 2: \x09\x0a\x0c - 3: \x09\x0a - 4: \x09 - 5: /[[:blank:]]+/ > \x09\x0a\x0c\x0d\x0b< 0: \x09 - 1: /[\s]+/ > \x09\x0a\x0c\x0d\x0b< - 0: \x09\x0a\x0c\x0d - 1: \x09\x0a\x0c - 2: \x09\x0a - 3: \x09 - 4: + 0: \x09\x0a\x0c\x0d\x0b /\s+/ > \x09\x0a\x0c\x0d\x0b< - 0: \x09\x0a\x0c\x0d - 1: \x09\x0a\x0c - 2: \x09\x0a - 3: \x09 - 4: + 0: \x09\x0a\x0c\x0d\x0b /ab/x ab -No match + 0: ab /(?!\A)x/m a\nxb\n @@ -6563,8 +6333,6 @@ Partial match: 123 /Content-Type\x3A[^\r\n]{6,}/ Content-Type:xxxxxyyy 0: Content-Type:xxxxxyyy - 1: Content-Type:xxxxxyy - 2: Content-Type:xxxxxy /Content-Type\x3A[^\r\n]{6,}z/ Content-Type:xxxxxyyyz @@ -6661,66 +6429,22 @@ No match /.*/<lf> abc\ndef 0: abc - 1: ab - 2: a - 3: abc\rdef 0: abc\x0ddef - 1: abc\x0dde - 2: abc\x0dd - 3: abc\x0d - 4: abc - 5: ab - 6: a - 7: abc\r\ndef 0: abc\x0d - 1: abc - 2: ab - 3: a - 4: \<cr>abc\ndef 0: abc\x0adef - 1: abc\x0ade - 2: abc\x0ad - 3: abc\x0a - 4: abc - 5: ab - 6: a - 7: \<cr>abc\rdef 0: abc - 1: ab - 2: a - 3: \<cr>abc\r\ndef 0: abc - 1: ab - 2: a - 3: \<crlf>abc\ndef 0: abc\x0adef - 1: abc\x0ade - 2: abc\x0ad - 3: abc\x0a - 4: abc - 5: ab - 6: a - 7: \<crlf>abc\rdef 0: abc\x0ddef - 1: abc\x0dde - 2: abc\x0dd - 3: abc\x0d - 4: abc - 5: ab - 6: a - 7: \<crlf>abc\r\ndef 0: abc - 1: ab - 2: a - 3: /\w+(.)(.)?def/s abc\ndef @@ -7033,10 +6757,8 @@ No match /\H*\h+\V?\v{3,4}/ \x09\x20\xa0X\x0a\x0b\x0c\x0d\x0a 0: \x09 \xa0X\x0a\x0b\x0c\x0d - 1: \x09 \xa0X\x0a\x0b\x0c \x09\x20\xa0\x0a\x0b\x0c\x0d\x0a 0: \x09 \xa0\x0a\x0b\x0c\x0d - 1: \x09 \xa0\x0a\x0b\x0c \x09\x20\xa0\x0a\x0b\x0c 0: \x09 \xa0\x0a\x0b\x0c ** Failers @@ -7047,7 +6769,6 @@ No match /\H{3,4}/ XY ABCDE 0: ABCD - 1: ABC XY PQR ST 0: PQR @@ -7531,15 +7252,11 @@ No match xxxxabcd\P 0: abcd 0+ - 1: abc xxxxabcd\P\P Partial match: abcd dddxxx\R 0: ddd 0+ xxx - 1: dd - 2: d - 3: xxxxabcd\P\P Partial match: abcd xxx\R @@ -7549,27 +7266,22 @@ Partial match: abcd /abcd*/i xxxxabcd\P 0: abcd - 1: abc xxxxabcd\P\P Partial match: abcd XXXXABCD\P 0: ABCD - 1: ABC XXXXABCD\P\P Partial match: ABCD /abc\d*/ xxxxabc1\P 0: abc1 - 1: abc xxxxabc1\P\P Partial match: abc1 /abc[de]*/ xxxxabcde\P 0: abcde - 1: abcd - 2: abc xxxxabcde\P\P Partial match: abcde @@ -7684,11 +7396,8 @@ Partial match: abc /.+/ abc\>0 0: abc - 1: ab - 2: a abc\>1 0: bc - 1: b abc\>2 0: c abc\>3 @@ -7811,10 +7520,6 @@ No match /^(?!a){0}\w+/ aaaaa 0: aaaaa - 1: aaaa - 2: aaa - 3: aa - 4: a /(?<=(abc))?xyz/ abcxyz @@ -7846,7 +7551,7 @@ Error -17 (backreference condition or recursion test not supported for DFA match aaaabcde Error -26 (nested recursion at the same subject position) -/(a+)/ +/(a+)/O \O6aaaa Matched, but offsets vector is too small to show all matches 0: aaaa @@ -7971,7 +7676,6 @@ Partial match: \x0d Partial match: \x0d\x0d \r\r\r\P 0: \x0d\x0d\x0d - 1: \x0d\x0d \r\r\r\P\P Partial match: \x0d\x0d\x0d @@ -8020,4 +7724,57 @@ Error -30 (invalid data in workspace for DFA restart) abcd\O0 Matched, but offsets vector is too small to show all matches +/-- These tests show up auto-possessification --/ + +/[ab]*/ + aaaa + 0: aaaa + +/[ab]*?/ + aaaa + 0: aaaa + 1: aaa + 2: aa + 3: a + 4: + +/[ab]?/ + aaaa + 0: a + +/[ab]??/ + aaaa + 0: a + 1: + +/[ab]+/ + aaaa + 0: aaaa + +/[ab]+?/ + aaaa + 0: aaaa + 1: aaa + 2: aa + 3: a + +/[ab]{2,3}/ + aaaa + 0: aaa + +/[ab]{2,3}?/ + aaaa + 0: aaa + 1: aa + +/[ab]{2,}/ + aaaa + 0: aaaa + +/[ab]{2,}?/ + aaaa + 0: aaaa + 1: aaa + 2: aa + /-- End of testinput8 --/ diff --git a/pcre/testdata/testoutput9 b/pcre/testdata/testoutput9 index 0bb101ad614..efbbf180106 100644 --- a/pcre/testdata/testoutput9 +++ b/pcre/testdata/testoutput9 @@ -1,6 +1,8 @@ /-- This set of tests checks UTF-8 support with the DFA matching functionality - of pcre_dfa_exec(). The -dfa flag must be used with pcretest when running - it. --/ + of pcre_dfa_exec(), excluding Unicode property support. The -dfa flag must + be used with pcretest when running it. --/ + +< forbid W /\x{100}ab/8 \x{100}ab @@ -313,13 +315,9 @@ No match /[^a]+/8g bcd 0: bcd - 1: bc - 2: b \x{100}aY\x{256}Z 0: \x{100} 0: Y\x{256}Z - 1: Y\x{256} - 2: Y /^[^a]{2}/8 \x{100}bc @@ -328,8 +326,6 @@ No match /^[^a]{2,}/8 \x{100}bcAa 0: \x{100}bcA - 1: \x{100}bc - 2: \x{100}b /^[^a]{2,}?/8 \x{100}bca @@ -339,13 +335,9 @@ No match /[^a]+/8ig bcd 0: bcd - 1: bc - 2: b \x{100}aY\x{256}Z 0: \x{100} 0: Y\x{256}Z - 1: Y\x{256} - 2: Y /^[^a]{2}/8i \x{100}bc @@ -354,7 +346,6 @@ No match /^[^a]{2,}/8i \x{100}bcAa 0: \x{100}bc - 1: \x{100}b /^[^a]{2,}?/8i \x{100}bca @@ -370,28 +361,18 @@ No match 0: \x{100}\x{100} 0: \x{100} - 1: /\x{100}{0,3}/8 \x{100}\x{100} 0: \x{100}\x{100} - 1: \x{100} - 2: \x{100}\x{100}\x{100}\x{100} 0: \x{100}\x{100}\x{100} - 1: \x{100}\x{100} - 2: \x{100} - 3: /\x{100}*/8 abce 0: \x{100}\x{100}\x{100}\x{100} 0: \x{100}\x{100}\x{100}\x{100} - 1: \x{100}\x{100}\x{100} - 2: \x{100}\x{100} - 3: \x{100} - 4: /\x{100}{1,1}/8 abcd\x{100}\x{100}\x{100}\x{100} @@ -400,15 +381,10 @@ No match /\x{100}{1,3}/8 abcd\x{100}\x{100}\x{100}\x{100} 0: \x{100}\x{100}\x{100} - 1: \x{100}\x{100} - 2: \x{100} /\x{100}+/8 abcd\x{100}\x{100}\x{100}\x{100} 0: \x{100}\x{100}\x{100}\x{100} - 1: \x{100}\x{100}\x{100} - 2: \x{100}\x{100} - 3: \x{100} /\x{100}{3}/8 abcd\x{100}\x{100}\x{100}XX @@ -417,10 +393,8 @@ No match /\x{100}{3,5}/8 abcd\x{100}\x{100}\x{100}\x{100}\x{100}\x{100}\x{100}XX 0: \x{100}\x{100}\x{100}\x{100}\x{100} - 1: \x{100}\x{100}\x{100}\x{100} - 2: \x{100}\x{100}\x{100} -/\x{100}{3,}/8 +/\x{100}{3,}/8O abcd\x{100}\x{100}\x{100}\x{100}\x{100}\x{100}\x{100}XX 0: \x{100}\x{100}\x{100}\x{100}\x{100}\x{100}\x{100} 1: \x{100}\x{100}\x{100}\x{100}\x{100}\x{100} @@ -432,7 +406,7 @@ No match Xyyya\x{100}\x{100}bXzzz 0: X -/\D*/8 +/\D*/8O aaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaa Matched, but offsets vector is too small to show all matches 0: aaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaa @@ -458,7 +432,7 @@ Matched, but offsets vector is too small to show all matches 20: aaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaa 21: aaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaa -/\D*/8 +/\D*/8O \x{100}\x{100}\x{100}\x{100}\x{100}\x{100}\x{100}\x{100}\x{100}\x{100}\x{100}\x{100}\x{100}\x{100}\x{100}\x{100}\x{100}\x{100}\x{100}\x{100}\x{100}\x{100}\x{100}\x{100}\x{100}\x{100}\x{100}\x{100}\x{100}\x{100}\x{100}\x{100}\x{100}\x{100}\x{100}\x{100}\x{100}\x{100}\x{100}\x{100}\x{100}\x{100}\x{100}\x{100}\x{100}\x{100}\x{100}\x{100}\x{100}\x{100}\x{100}\x{100}\x{100}\x{100}\x{100}\x{100}\x{100}\x{100}\x{100}\x{100}\x{100}\x{100}\x{100}\x{100}\x{100}\x{100}\x{100}\x{100}\x{100}\x{100}\x{100}\x{100}\x{100}\x{100}\x{100}\x{100}\x{100}\x{100}\x{100}\x{100}\x{100}\x{100}\x{100}\x{100}\x{100}\x{100}\x{100}\x{100}\x{100}\x{100}\x{100}\x{100}\x{100}\x{100}\x{100}\x{100}\x{100}\x{100}\x{100}\x{100}\x{100}\x{100}\x{100}\x{100}\x{100}\x{100}\x{100}\x{100}\x{100}\x{100}\x{100}\x{100}\x{100}\x{100}\x{100}\x{100}\x{100}\x{100}\x{100}\x{100}\x{100}\x{100}\x{100}\x{100}\x{100}\x{100}\x{100}\x{100}\x{100}\x{100}\x{100}\x{100}\x{100}\x{100}\x{100}\x{100}\x{100}\x{100}\x{100}\x{100}\x{100}\x{100}\x{100}\x{100}\x{100}\x{100}\x{100}\x{100}\x{100}\x{100}\x{100}\x{100}\x{100}\x{100}\x{100}\x{100}\x{100}\x{100}\x{100}\x{100}\x{100}\x{100}\x{100}\x{100}\x{100}\x{100}\x{100}\x{100}\x{100}\x{100}\x{100}\x{100}\x{100}\x{100}\x{100}\x{100}\x{100}\x{100}\x{100}\x{100}\x{100}\x{100}\x{100}\x{100}\x{100}\x{100}\x{100}\x{100}\x{100}\x{100}\x{100}\x{100}\x{100}\x{100}\x{100}\x{100}\x{100}\x{100}\x{100}\x{100}\x{100}\x{100}\x{100}\x{100}\x{100}\x{100}\x{100}\x{100}\x{100}\x{100}\x{100}\x{100}\x{100}\x{100}\x{100}\x{100}\x{100}\x{100}\x{100}\x{100}\x{100}\x{100} Matched, but offsets vector is too small to show all matches 0: \x{100}\x{100}\x{100}\x{100}\x{100}\x{100}\x{100}\x{100}\x{100}\x{100}\x{100}\x{100}\x{100}\x{100}\x{100}\x{100}\x{100}\x{100}\x{100}\x{100}\x{100}\x{100}\x{100}\x{100}\x{100}\x{100}\x{100}\x{100}\x{100}\x{100}\x{100}\x{100}\x{100}\x{100}\x{100}\x{100}\x{100}\x{100}\x{100}\x{100}\x{100}\x{100}\x{100}\x{100}\x{100}\x{100}\x{100}\x{100}\x{100}\x{100}\x{100}\x{100}\x{100}\x{100}\x{100}\x{100}\x{100}\x{100}\x{100}\x{100}\x{100}\x{100}\x{100}\x{100}\x{100}\x{100}\x{100}\x{100}\x{100}\x{100}\x{100}\x{100}\x{100}\x{100}\x{100}\x{100}\x{100}\x{100}\x{100}\x{100}\x{100}\x{100}\x{100}\x{100}\x{100}\x{100}\x{100}\x{100}\x{100}\x{100}\x{100}\x{100}\x{100}\x{100}\x{100}\x{100}\x{100}\x{100}\x{100}\x{100}\x{100}\x{100}\x{100}\x{100}\x{100}\x{100}\x{100}\x{100}\x{100}\x{100}\x{100}\x{100}\x{100}\x{100}\x{100}\x{100}\x{100}\x{100}\x{100}\x{100}\x{100}\x{100}\x{100}\x{100}\x{100}\x{100}\x{100}\x{100}\x{100}\x{100}\x{100}\x{100}\x{100}\x{100}\x{100}\x{100}\x{100}\x{100}\x{100}\x{100}\x{100}\x{100}\x{100}\x{100}\x{100}\x{100}\x{100}\x{100}\x{100}\x{100}\x{100}\x{100}\x{100}\x{100}\x{100}\x{100}\x{100}\x{100}\x{100}\x{100}\x{100}\x{100}\x{100}\x{100}\x{100}\x{100}\x{100}\x{100}\x{100}\x{100}\x{100}\x{100}\x{100}\x{100}\x{100}\x{100}\x{100}\x{100}\x{100}\x{100}\x{100}\x{100}\x{100}\x{100}\x{100}\x{100}\x{100}\x{100}\x{100}\x{100}\x{100}\x{100}\x{100}\x{100}\x{100}\x{100}\x{100}\x{100}\x{100}\x{100}\x{100}\x{100}\x{100}\x{100}\x{100}\x{100}\x{100}\x{100}\x{100}\x{100}\x{100}\x{100}\x{100}\x{100}\x{100}\x{100}\x{100}\x{100}\x{100}\x{100}\x{100}\x{100} @@ -507,33 +481,18 @@ Matched, but offsets vector is too small to show all matches /\D+/8 12abcd34 0: abcd - 1: abc - 2: ab - 3: a *** Failers 0: *** Failers - 1: *** Failer - 2: *** Faile - 3: *** Fail - 4: *** Fai - 5: *** Fa - 6: *** F - 7: *** - 8: *** - 9: ** -10: * 1234 No match /\D{2,3}/8 12abcd34 0: abc - 1: ab 12ab34 0: ab *** Failers 0: *** - 1: ** 1234 No match 12a34 @@ -556,7 +515,6 @@ No match /\d+/8 12abcd34 0: 12 - 1: 1 *** Failers No match @@ -565,7 +523,6 @@ No match 0: 12 1234abcd 0: 123 - 1: 12 *** Failers No match 1.4 @@ -585,30 +542,18 @@ No match /\S+/8 12abcd34 0: 12abcd34 - 1: 12abcd3 - 2: 12abcd - 3: 12abc - 4: 12ab - 5: 12a - 6: 12 - 7: 1 *** Failers 0: *** - 1: ** - 2: * \ \ No match /\S{2,3}/8 12abcd34 0: 12a - 1: 12 1234abcd 0: 123 - 1: 12 *** Failers 0: *** - 1: ** \ \ No match @@ -654,15 +599,8 @@ No match /\w+/8 12 34 0: 12 - 1: 1 *** Failers 0: Failers - 1: Failer - 2: Faile - 3: Fail - 4: Fai - 5: Fa - 6: F +++=*! No match @@ -671,10 +609,8 @@ No match 0: ab abcd ce 0: abc - 1: ab *** Failers 0: Fai - 1: Fa a.b.c No match @@ -693,26 +629,18 @@ No match /\W+/8 12====34 0: ==== - 1: === - 2: == - 3: = *** Failers 0: *** - 1: *** - 2: ** - 3: * abcd No match /\W{2,3}/8 ab====cd 0: === - 1: == ab==cd 0: == *** Failers 0: *** - 1: ** a.b.c No match @@ -825,8 +753,6 @@ No match 0: \x{200} ab\x{200}\x{100}\x{200}\x{100}cd 0: \x{200}\x{100}\x{200} - 1: \x{200}\x{100} - 2: \x{200} *** Failers No match @@ -849,8 +775,6 @@ No match 0: \x{200} ab\x{200}\x{100}\x{200}\x{100}cd 0: \x{200}\x{100}\x{200} - 1: \x{200}\x{100} - 2: \x{200} *** Failers No match @@ -1126,21 +1050,21 @@ No match a\r No match -/\h+\V?\v{3,4}/8 +/\h+\V?\v{3,4}/8O \x09\x20\x{a0}X\x0a\x0b\x0c\x0d\x0a 0: \x{09} \x{a0}X\x{0a}\x{0b}\x{0c}\x{0d} 1: \x{09} \x{a0}X\x{0a}\x{0b}\x{0c} -/\V?\v{3,4}/8 +/\V?\v{3,4}/8O \x20\x{a0}X\x0a\x0b\x0c\x0d\x0a 0: X\x{0a}\x{0b}\x{0c}\x{0d} 1: X\x{0a}\x{0b}\x{0c} -/\h+\V?\v{3,4}/8 +/\h+\V?\v{3,4}/8O >\x09\x20\x{a0}X\x0a\x0a\x0a< 0: \x{09} \x{a0}X\x{0a}\x{0a}\x{0a} -/\V?\v{3,4}/8 +/\V?\v{3,4}/8O >\x09\x20\x{a0}X\x0a\x0a\x0a< 0: X\x{0a}\x{0a}\x{0a} @@ -1154,7 +1078,7 @@ No match \x{a0} X\x0a No match -/\H*\h+\V?\v{3,4}/8 +/\H*\h+\V?\v{3,4}/8O \x09\x20\x{a0}X\x0a\x0b\x0c\x0d\x0a 0: \x{09} \x{a0}X\x{0a}\x{0b}\x{0c}\x{0d} 1: \x{09} \x{a0}X\x{0a}\x{0b}\x{0c} @@ -1178,7 +1102,7 @@ No match \x{2009} X\x0a No match -/\H*\h+\V?\v{3,4}/8 +/\H*\h+\V?\v{3,4}/8O \x{1680}\x{180e}\x{2007}X\x{2028}\x{2029}\x0c\x0d\x0a 0: \x{1680}\x{180e}\x{2007}X\x{2028}\x{2029}\x{0c}\x{0d} 1: \x{1680}\x{180e}\x{2007}X\x{2028}\x{2029}\x{0c} @@ -1279,34 +1203,28 @@ No match /abcd*/8 xxxxabcd\P 0: abcd - 1: abc xxxxabcd\P\P Partial match: abcd /abcd*/i8 xxxxabcd\P 0: abcd - 1: abc xxxxabcd\P\P Partial match: abcd XXXXABCD\P 0: ABCD - 1: ABC XXXXABCD\P\P Partial match: ABCD /abc\d*/8 xxxxabc1\P 0: abc1 - 1: abc xxxxabc1\P\P Partial match: abc1 /abc[de]*/8 xxxxabcde\P 0: abcde - 1: abcd - 2: abc xxxxabcde\P\P Partial match: abcde @@ -1340,7 +1258,6 @@ Partial match: \x{0d} Partial match: \x{0d}\x{0d} \r\r\r\P 0: \x{0d}\x{0d}\x{0d} - 1: \x{0d}\x{0d} \r\r\r\P\P Partial match: \x{0d}\x{0d}\x{0d} @@ -1366,6 +1283,5 @@ Partial match: \x{0d}\x{0d}\x{0d} /[^\x{100}]+/8 \x{100}\x{101}X 0: \x{101}X - 1: \x{101} /-- End of testinput9 --/ |