CURLY_B_*_fail all currently do:
if (ST.paren && ST.count)
rex->offs[ST.paren].end = -1;
but this is unnecessary. If B has just failed in the pattern /...(A)*B/,
then we will either adjust the amount of matched A, update rex->offs
(overwriting that -1) then call B again; or fail completely, do sayNO, and
backtrack to an op somewhere in the '...' before A. In this latter case,
the "somewhere else" op is the one responsible for unwinding the matched
parentheses, not us.
case CURLY_B_min_known_fail:
/* failed to find B in a non-greedy match where c1,c2 valid */
- if (ST.paren && ST.count)
- rex->offs[ST.paren].end = -1;
PL_reginput = locinput; /* Could be reset... */
REGCP_UNWIND(ST.cp);
case CURLY_B_min_fail:
/* failed to find B in a non-greedy match where c1,c2 invalid */
- if (ST.paren && ST.count)
- rex->offs[ST.paren].end = -1;
REGCP_UNWIND(ST.cp);
/* failed -- move forward one */
/* FALL THROUGH */
case CURLY_B_max_fail:
/* failed to find B in a greedy match */
- if (ST.paren && ST.count)
- rex->offs[ST.paren].end = -1;
REGCP_UNWIND(ST.cp);
/* back up. */