register CONTEXT *cx;
POPBLOCK(cx,newpm);
- POPSUB(cx);
+ /* Delay POPSUB until stack values are safe */
if (gimme == G_SCALAR) {
MARK = newsp + 1;
/* in case LEAVE wipes old return values */
}
+ /* Now that stack values are safe, release CV and @_ */
+ POPSUB(cx);
+
curpm = newpm; /* Don't pop $1 et al till now */
LEAVE;
map {#this newline here tickles the bug
$s += $_} (1,2,4);
print "eat flaming death\n" unless ($s == 7);
+########
+sub foo { local $_ = shift; split; @_ }
+@x = foo(' x y z ');
+print "you die joe!\n" unless "@x" eq 'x y z';