lua-users home
lua-l archive

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


On Fri, Feb 26, 2010 at 7:22 AM, Mark Hamburg <mark@grubmah.com> wrote:
> While I like the general tenor of the proposed change, I can see two potential problems for what Lightroom is doing. The first is that the function will now have an upvalue if it references any globals. The second is that I don't know how that upvalue will get bound when doing the load on the other side.

As I understand, every Lua function will have at least one upvalue,
_ENV.  This would be slot 0 ?

It would be convenient if that upvalue were rebound to the _ENV of the
other state when loaded, but I suppose that can also be done with
debug.setfenv.

steve d.