Change 34746 by [EMAIL PROTECTED] on 2008/11/06 10:44:13

        Resolve perl #60344: Regex lookbehind failure after an (if)then|else in 
perl 5.10
        
        During the de-recursivization it looks like Dave M forgot to reset the 
'logical'
        flag after using it, which in turn causes UNLESSM/IFTHEN when used 
after a LOGICAL operator to
        be incorrectly intrepreted. This change resets the logical flag after 
each time it is stored
        in ST.logical.

Affected files ...

... //depot/perl/regexec.c#576 edit
... //depot/perl/t/op/re_tests#135 edit

Differences ...

==== //depot/perl/regexec.c#576 (text) ====
Index: perl/regexec.c
--- perl/regexec.c#575~34698~   2008-11-02 13:12:59.000000000 -0800
+++ perl/regexec.c      2008-11-06 02:44:13.000000000 -0800
@@ -4983,6 +4983,7 @@
          do_ifmatch:
            ST.me = scan;
            ST.logical = logical;
+           logical = 0;
            /* execute body of (?...A) */
            PUSH_YES_STATE_GOTO(IFMATCH_A, NEXTOPER(NEXTOPER(scan)));
            /* NOTREACHED */

==== //depot/perl/t/op/re_tests#135 (text) ====
Index: perl/t/op/re_tests
--- perl/t/op/re_tests#134~34697~       2008-11-02 10:31:19.000000000 -0800
+++ perl/t/op/re_tests  2008-11-06 02:44:13.000000000 -0800
@@ -1358,3 +1358,5 @@
 /^\s*i.*?o\s*$/s       io\n io y       -       -
 # As reported in #59168 by Father Chrysostomos:
 /(.*?)a(?!(a+)b\2c)/   baaabaac        y       $&-$1   baa-ba
+# [perl #60344] Regex lookbehind failure after an (if)then|else in perl 5.10
+/\A(?(?=db2)db2|\D+)(?<!processed)\.csv\z/xms  sql_processed.csv       n       
-       -
End of Patch.

Reply via email to