[Date Prev][Date Next][Thread Prev][Thread Next]
- Subject: Re: Adding debug hook for error/yield/resume
- From: Joshua Jensen <josh.jjensen@...>
- Date: Mon, 17 Mar 2014 13:34:40 -0600
----- Original Message -----
From: Paul K
Date: 3/17/2014 1:25 PM
The Tilde debugger  made by Tantalus adds an error hook to catch the
location where error() was called from. I'll just throw it out there as
an example of something that works pretty well.
I'd like to move this debug.traceback discussion from LuaJIT maillist
here . debug.traceback used to be the only mechanism to catch
run-time errors for code chunks you didn't load yourself and it
appears that this mechanism is not available in Lua 5.2+ or LuaJIT as
debug.traceback is not called anymore in those cases.
As such we are left without any alternative for catching run-time
errors from the Lua layer. Mike mentioned using a new hook as a
possible solution. Could this be considered as it would definitely
solve the issue of catching the errors?
Anyway, I'd love to see the hooks, too.