develooper Front page | perl.perl5.porters | Postings from July 2012

[perl #73618] no-iteration until loop incorrectly optimised away

From:
Jesse Luehrs via RT
Date:
July 2, 2012 22:57
Subject:
[perl #73618] no-iteration until loop incorrectly optimised away
Message ID:
rt-3.6.HEAD-28836-1341295063-1773.73618-15-0@perl.org
Fixed in 317f3b6, but only for the case of 'while', not the case of
'until'. Fixing 'until' is harder because the parser itself rewrites
"until (1)" to "while (!1)" directly, and so "!1" is constant-folded to
'' before the while loop is even constructed. I'll leave this open (with
an updated title) in the hopes that someone else feels like fixing that
aspect of it (I left a TODO test in t/op/loopctl.t).

-doy

---
via perlbug:  queue: perl5 status: open
https://rt.perl.org:443/rt3/Ticket/Display.html?id=73618



nntp.perl.org: Perl Programming lists via nntp and http.
Comments to Ask Bjørn Hansen at ask@perl.org | Group listing | About