[Date Prev][Date Next][Thread Prev][Thread Next]
- Subject: Re: No-globals patch proposal. (Was: Re: Another take on locals by default)
- From: Peng Zhicheng <pengzhicheng1986@...>
- Date: Sun, 27 May 2012 11:33:23 +0800
于 2012-5-27 1:22, Xavier Wang 写道:
Maybe you can do this by simply:
after this point, all global access are not allowed.
or the following idiom (looks a little cluttered though):
-- your code here
you may change the actual environment easily by passing it as a parameter.
if Lua has some clearer lambda syntax, this would look better.