diff options
author | Jerry D. Hedden <jdhedden@cpan.org> | 2008-01-14 14:56:48 -0500 |
---|---|---|
committer | Rafael Garcia-Suarez <rgarciasuarez@gmail.com> | 2008-01-15 11:11:07 +0000 |
commit | a2309040b8fe324ae09c064137c624b4292d93c1 (patch) | |
tree | 94472c2597f4c1ce4778668ea9af0743628a3a89 /pp_hot.c | |
parent | 3e946625bd318900adc25217434a05ce37064aba (diff) | |
download | perl-a2309040b8fe324ae09c064137c624b4292d93c1.tar.gz |
Fix range operator
From: "Jerry D. Hedden" <jdhedden@cpan.org>
Message-ID: <1ff86f510801141656i325ac69ev8a0af47f9fe72a1e@mail.gmail.com>
p4raw-id: //depot/perl@32979
Diffstat (limited to 'pp_hot.c')
-rw-r--r-- | pp_hot.c | 9 |
1 files changed, 9 insertions, 0 deletions
@@ -1961,6 +1961,15 @@ PP(pp_iter) *itersvp = newSViv(cx->blk_loop.iterix++); SvREFCNT_dec(oldsv); } + + /* Handle end of range at IV_MAX */ + if ((cx->blk_loop.iterix == IV_MIN) && + (cx->blk_loop.itermax == IV_MAX)) + { + cx->blk_loop.iterix++; + cx->blk_loop.itermax++; + } + RETPUSHYES; } |