From: Hugo van der Sanden Date: Fri, 30 Apr 1999 09:26:18 +0000 (+0100) Subject: fix overeager [:foo:] parsing X-Git-Url: http://git.shadowcat.co.uk/gitweb/gitweb.cgi?a=commitdiff_plain;h=767d463e9a7ba83b304a4002716436d480285abb;p=p5sagit%2Fp5-mst-13.2.git fix overeager [:foo:] parsing Message-Id: <199904300826.JAA01257@crypt.compulink.co.uk> Subject: [PATCH 5.005_{56,03}] Re: Regular expression difference b/n 5.004 & 5.005 p4raw-id: //depot/perl@3364 --- diff --git a/regcomp.c b/regcomp.c index 018249c..cbb9447 100644 --- a/regcomp.c +++ b/regcomp.c @@ -2149,6 +2149,10 @@ regpposixcc(I32 value) PL_regcomp_parse++; /* skip over the ending ] */ posixcc = s + 1; } + else { + /* maternal grandfather */ + PL_regcomp_parse = s; + } } } diff --git a/t/op/re_tests b/t/op/re_tests index 5abe217..ba824ae 100644 --- a/t/op/re_tests +++ b/t/op/re_tests @@ -475,6 +475,7 @@ $(?<=^(a)) a y $1 a ([[.]+) a.[b]. y $1 .[ [a[:xyz: - c - /[a[:xyz:/: unmatched [] in regexp [a[:xyz:] - c - /[a[:xyz:]/: unmatched [] in regexp +[a[:]b[:c] abc y $& abc ([a[:xyz:]b]+) pbaq y $1 ba ((?>a+)b) aaab y $1 aaab (?>(a+))b aaab y $1 aaa