lua-users home
lua-l archive

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

On 9/19/06, Robert Raschke <> wrote:
Jasmin Patry wrote:
> I'm wondering if anybody has had any experience modifying how Lua
> handles errors in scripts.

I just use pcall() for that kind of thing.


Not to hijack this thread, but can somebody point to any wiki articles or otherwise about using error handlers with lua_pcall().  Doing my first project with Lua and everything is going swimmingly, but would like some more robustness and feedback to the user ( e.g. reporting the actual line and some context for a syntax error).  How lua_pcall uses it's error handler isn't very clear to me from PiL nor the online docs.

cheers -- j