[Date Prev][Date Next][Thread Prev][Thread Next]
[Date Index]
[Thread Index]
- Subject: Re: About ifstat
- From: roberto@... (Roberto Ierusalimschy)
- Date: Mon, 5 Jun 2006 10:18:24 -0300
> lua_assert(!bl->isbreakable || !bl->upval); /* loops have no body */
> According to the assert, it seems for statement and while statement
> cannot have upvalue.Would you give me more information about this?
I am afraid the comment is not exactly clear. 'Blocks' in the
implementation has two purposes: scope control and break control.
A given block is never working for both purposes. (The break control
creates a "block" around the loop; those blocks do not define a new
scope. That is wat the comment was trying [and failing] to say.)
-- Roberto