Aaron Sherman wrote:

> >     while $result.get_next() -> $next {
> >         # do something with $next...
> >         ELSE {
> >            # do something otherwise with $next
> >             }
> >         }
> >     }

> Here's the code, expanded:

Unfortunately, that code isn't even close to the Perl 6 semantics of C<while> loops.

 
> Is there any reason to do it the other way?

Yes. Good reasons. The most important of which is the notion
that there are no magic lexical scopes.

Damian

Reply via email to