lua-users home
lua-l archive

[Date Prev][Date Next][Thread Prev][Thread Next] [Date Index] [Thread Index]


Hallo,

On 8/5/06, Stefan Brantschen <sbr@acm.org> wrote:

=> Is this done by 'loader' in 'require' in listing 15.1 in PIL II
(page 139), ie. are all (local) vars in the module 'mod' defined and
initialized after 'require "mod"'?


    When one requires a module, it is run like a function with a
different global environment. So yes, locals are initialised during
require.

--
-alex
http://www.ventonegro.org/