lua-users home
lua-l archive

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


> what I'm asking about is how to identify which gobal functions and 
> variables were added by a specific chunk, so I'd be able to remove them.

No need for that. Just set the environment to an empty table with
a __index metamethod pointing to the actual environment. This will
allow the chunk to read anything you have in the actual original but
changes will be made to the new environment, leaving the original
environment intact. You can also add your own versions of some functions
and variables to the new environment, to mask those in the original
environment. --lhf