lua-users home
lua-l archive

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


>> Well, why not just do require("debug") then? "Moral" considerations
>> should be the same.

> Firstly because it would not be accompanied by the other baggage associated with "debug", and secondly because it would recognize a voluntary decision by the person administering the Lua environment to make those functions available to code within that environment.

> This decision seems to indicate a philosophy of encapsulation by default, while still allowing users and embeddors to choose to expose or bridge information into other environments to the degree they wish and no more.

Well, yes, but isn't the existance such module would be a "hack
against the Lua 5.2 language"? Almost the same as if one would create
a module which would allow people to bypass the __metatable
protection.

Note that I'm not advocating the removal of get/setfenv, but merely
discussing the "what if" Lua 5.2 final *is* released without them.

Alexander.