diff options
author | Nicholas Clark <nick@ccl4.org> | 2010-05-02 21:04:32 +0100 |
---|---|---|
committer | Nicholas Clark <nick@ccl4.org> | 2010-05-02 21:04:32 +0100 |
commit | 4f0556e9541e0e65f0abc5f4f6caf1f16ddf2dcd (patch) | |
tree | a5200bd223c9e2ff7d76095c4ea7d95101399008 /pp_hot.c | |
parent | 61e5f455dc8214c9c23deb700f3fcf67b180afa5 (diff) | |
download | perl-4f0556e9541e0e65f0abc5f4f6caf1f16ddf2dcd.tar.gz |
Permit array assignment to steal temps and copy shared hash key scalars.
Scalar assignment to array elements already does this. (As does all other
scalar assignment, and list assignment to hashes.) Prior to 4c8f17b905f2
(change 7867) list assignment to arrays did steal temps.
Diffstat (limited to 'pp_hot.c')
-rw-r--r-- | pp_hot.c | 3 |
1 files changed, 2 insertions, 1 deletions
@@ -1037,7 +1037,8 @@ PP(pp_aassign) while (relem <= lastrelem) { /* gobble up all the rest */ SV **didstore; assert(*relem); - sv = newSVsv(*relem); + sv = newSV(0); + sv_setsv(sv, *relem); *(relem++) = sv; didstore = av_store(ary,i++,sv); if (magic) { |