lua-users home
lua-l archive

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

On Sat, Dec 6, 2008 at 9:04 AM, Stevo <> wrote:
> Thanks for pointing me to this book. i think the method shown in the
> book is not exactly what i need. the tracing of variables should be as
> transparent as possible to the writer of the lua code. tracing the
> global variables of the script would be enough and it should be as easy
> as one call like "tracevars(varname1, varname2)" and everything else is
> handled in the background.
> as the lua-code in my projekt is input in a textfield i could of course
> preprocess the code before sending it to lua.
> is this possible?

Looks to me like test/trace-globals.lua shows how to do what you
describe, like Pan said.

Its not prebuilt to do "exactly" what you want, because it logs all
globals. You'd have to rework it to do only the ones you want. And
replace log().