summaryrefslogtreecommitdiff
path: root/pp_hot.c
diff options
context:
space:
mode:
authorChip Salzenberg <chip@atlantic.net>1996-12-31 09:34:20 +1200
committerChip Salzenberg <chip@atlantic.net>1997-01-01 08:59:00 +1200
commit0c8c7a0553bc4fb5d18712a0ed968981d85f1767 (patch)
treec5f35763343fc724bc1c37ea07f06ce74a1f1089 /pp_hot.c
parent02b32252cb5781c70cbc96b7697e4796f3e60cd9 (diff)
downloadperl-0c8c7a0553bc4fb5d18712a0ed968981d85f1767.tar.gz
Don't forget $c in C<(($a,$b,$c)=(1,2))=(3,4,5)>
Diffstat (limited to 'pp_hot.c')
-rw-r--r--pp_hot.c5
1 files changed, 3 insertions, 2 deletions
diff --git a/pp_hot.c b/pp_hot.c
index 9633d54e88..f957deb956 100644
--- a/pp_hot.c
+++ b/pp_hot.c
@@ -725,8 +725,9 @@ PP(pp_aassign)
SP = lastrelem;
else
SP = firstrelem + (lastlelem - firstlelem);
+ lelem = firstlelem + (relem - firstrelem);
while (relem <= SP)
- *relem++ = &sv_undef;
+ *relem++ = (lelem <= lastlelem) ? *lelem++ : &sv_undef;
RETURN;
}
else {
@@ -1905,7 +1906,7 @@ PP(pp_entersub)
}
cx->blk_sub.savearray = GvAV(defgv);
cx->blk_sub.argarray = av;
- GvAV(defgv) = cx->blk_sub.argarray;
+ GvAV(defgv) = (AV*)SvREFCNT_inc(av);
++MARK;
if (items > AvMAX(av) + 1) {