lua-users home
lua-l archive

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


On 29 Oct 2007, at 13:32, Jose Marin wrote:
One solution that allow us to run Lua code step by step, inspect/ modify variables, look at the stack, etc.

If you don't mind using a command-line debugging console then take a look at

http://loop.luaforge.net/docs_Inspector.html

This provides a console that executes code emulating some point in your code, so you can access local variables, variables of the current environment, etc. You can also navigate to functions on the current call stack, to inactive functions (e.g. to access upvalues) or to suspended coroutines.

In the current version you define the place where to open the inspection console using a method call (inspector:stop()). However, the next version will also offer step[in|out] and definition of break points. You can try the next version from the last OiL working package at: http://luaforge.net/frs/?group_id=116. If you get interested I can send you a draft of the new documentation.

For other similar debugging tools to take a look at:

  RemDebug: http://www.keplerproject.org/remdebug/
  CLI debugger: http://luaforge.net/projects/clidebugger/

--
Renato Maia
PhD student at PUC-Rio
__________________________
http://www.inf.puc-rio.br/~maia/