develooper Front page | perl.perl5.porters | Postings from December 1999

Re: [ID 19991216.002] do-while bug

From:
Ronald J Kimball
Date:
December 16, 1999 11:23
Subject:
Re: [ID 19991216.002] do-while bug
Message ID:
19991216142114.H851320@linguist.dartmouth.edu
On Thu, Dec 16, 1999 at 02:06:38PM -0600, Craig Lewis wrote:
> I did a quick search of the PerlBug Database, but I didn't find anything
> that seems
> related.
> 
> I found a bug, or at least unexpected operation, from the last operator
> inside a
> do-while loop.
> 

As documented.  perldoc -f last

    last cannot be used to exit a block which returns a value such as
    eval {}, sub {} or do {}, and should not be used to exit
    a grep() or map() operation.


Ronald



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