From: Gurusamy Sarathy Date: Thu, 9 Jul 1998 11:07:42 +0000 (+0000) Subject: undo problematic change#1367 X-Git-Url: http://git.shadowcat.co.uk/gitweb/gitweb.cgi?a=commitdiff_plain;h=aafb16c143b5a73b46307523883bd0548ff26277;p=p5sagit%2Fp5-mst-13.2.git undo problematic change#1367 p4raw-link: @1367 on //depot/perl: d426b052dee31c20224ef2893d5c969ad5a2c617 p4raw-id: //depot/perl@1398 --- diff --git a/pp_ctl.c b/pp_ctl.c index 3002412..9cf422f 100644 --- a/pp_ctl.c +++ b/pp_ctl.c @@ -1388,7 +1388,6 @@ PP(pp_enteriter) croak("Range iterator outside integer range"); cx->blk_loop.iterix = SvIV(sv); cx->blk_loop.itermax = SvIV((SV*)cx->blk_loop.iterary); - sv_setiv(*svp, 0); /* make sure index SV is IV capable */ } else cx->blk_loop.iterlval = newSVsv(sv); diff --git a/pp_hot.c b/pp_hot.c index dc8935b..9de5ece 100644 --- a/pp_hot.c +++ b/pp_hot.c @@ -1459,14 +1459,7 @@ PP(pp_iter) /* integer increment */ if (cx->blk_loop.iterix > cx->blk_loop.itermax) RETPUSHNO; - - /* we know that the loop index SV is IV capable, so we can save - * some time by doing the essential work of sv_setiv() ourself. - */ - sv = *cx->blk_loop.itervar; - (void)SvIOK_only(sv); - SvIVX(sv) = cx->blk_loop.iterix++; - + sv_setiv(*cx->blk_loop.itervar, cx->blk_loop.iterix++); RETPUSHYES; }