[Date Prev][Date Next][Thread Prev][Thread Next]
- Subject: Re: Explanation needed for setfenv replacement for Lua 5.2
- From: Lorenzo Donati <lorenzodonatibz@...>
- Date: Sat, 07 May 2011 18:50:15 +0200
On 07/05/2011 9.26, steve donovan wrote:
On Fri, May 6, 2011 at 10:05 PM, Lorenzo Donati
in the end? Or am I missing something?
You are missing nothing here. The notation just seemed very cute.
Always good to know! :-P :-)
(the env() function could also ensure that we also look up in the
enclosing environment, so it would not be necessary to use print=print
in the table.)
Note also that this kind of one-shot iterator could do something
interesting on the start of the second iteration before returning nil,
Interesting points. thanks!