summaryrefslogtreecommitdiff
path: root/pp.c
diff options
context:
space:
mode:
authorRobin Houston <robin@cpan.org>2001-08-10 15:42:02 +0100
committerJarkko Hietaniemi <jhi@iki.fi>2001-08-11 15:14:48 +0000
commite30acc166b495a49a868bf2a7185d1f8b5454de7 (patch)
tree3daf84a61958f7504d3721a28a5a4bcc3ed537c0 /pp.c
parent89de29047dd63c42d0e0d6b1cab1eea82aeda08d (diff)
downloadperl-e30acc166b495a49a868bf2a7185d1f8b5454de7.tar.gz
(retracted by 13077)
Subject: [PATCH] Re: [ID 20010809.028] x operator not copying elements in 'for' list? Message-ID: <20010810144202.A32754@puffinry.freeserve.co.uk> p4raw-id: //depot/perl@11635
Diffstat (limited to 'pp.c')
-rw-r--r--pp.c6
1 files changed, 4 insertions, 2 deletions
diff --git a/pp.c b/pp.c
index 1cb3a44882..a051268126 100644
--- a/pp.c
+++ b/pp.c
@@ -1139,8 +1139,10 @@ PP(pp_repeat)
MEXTEND(MARK, max);
if (count > 1) {
while (SP > MARK) {
- if (*SP)
- SvTEMP_off((*SP));
+ if (*SP) {
+ *SP = sv_2mortal(newSVsv(*SP));
+ SvREADONLY_on(*SP);
+ }
SP--;
}
MARK++;