[Date Prev][Date Next][Thread Prev][Thread Next]
[Date Index]
[Thread Index]
- Subject: Re: Predefined labels (Inspired by discussion on: Why do we have ipairs?)
- From: Sean Conner <sean@...>
- Date: Fri, 27 Jun 2014 05:18:59 -0400
It was thus said that the Great Sean Conner once stated:
>
> for v1,... in <iterator()> do <block> end
>
> do
> local f,s,var = <iterator()>
> ::L1::
> local v1,... = f(s,var)
> if not v1 == nil then goto L2 end
> <block>
> goto L1
> end
> ::L2::
Sorry, a mistake. This sould read:
do
local f,s,var = <iterator()>
::L1::
local v1,... = f(s,var)
if not v1 ~= nil then goto L2 end
<block>
goto L1
end
::L2::
-spc (There's a reason why I used 'if not' instead of just 'if' ... )