[Date Prev][Date Next][Thread Prev][Thread Next]
[Date Index]
[Thread Index]
- Subject: Re: modules, require, magic
- From: Roberto Ierusalimschy <roberto@...>
- Date: Wed, 19 Oct 2011 13:32:13 -0200
> In terms of "fixing module()", I think Fabio's implementation is right
> on the money:
>
> http://article.gmane.org/gmane.comp.lang.lua.general/84283
What exaclty is it trying to fix?
> It shows that a sane implementation of module() can be done with
> standard Lua mechanisms. Do any of the anti-module proponents see any
> problems with that design? Would you hate module() as much as you do
> now if it behaved like that instead of the way it behaves in Lua 5.1?
Isn't it even more complex/magic than the current implementation?
If you really want 'module', wouldn't be simpler to use
_ENV = module(...)
with a simplified version of 'module'?
-- Roberto
- References:
- modules, require, magic, Eduardo Ochs
- Re: modules, require, magic, Javier Guerra Giraldez
- Re: modules, require, magic, Petite Abeille
- Re: modules, require, magic, Sam Roberts
- Re: modules, require, magic, David Manura
- Re: modules, require, magic, Hisham