Adrian M. Enache [Fri, 21 Feb 2003 17:50:14 +0000 (19:50 +0200)]
Message-ID: <
20030221155014.GB793@ratsnest.hole>
p4raw-id: //depot/perl@18776
if (curop->op_type == OP_GV) {
GV *gv = cGVOPx_gv(curop);
repl_has_vars = 1;
- if (strchr("&`'123456789+", *GvENAME(gv)))
+ if (strchr("&`'123456789+-", *GvENAME(gv)))
break;
}
else if (curop->op_type == OP_RV2CV)
}
require './test.pl';
-plan( tests => 127 );
+plan( tests => 128 );
$x = 'foo';
$_ = "x";
$_ = "1111";
is(s/(??{1})/2/eg, 4, '#20684 s/// with (??{..}) inside');
+# [perl #20682] @- not visible in replacement
+$_ = "123";
+/(2)/; # seed @- with something else
+s/(1)(2)(3)/$#- (@-)/;
+is($_, "3 (0 0 1 2)", '#20682 @- not visible in replacement');
+