[Date Prev][Date Next][Thread Prev][Thread Next]
[Date Index]
[Thread Index]
- Subject: Re: [ANN] patch-lua-5.1.4-3
- From: Daurnimator <quae@...>
- Date: Fri, 18 Mar 2011 18:24:49 +1100
On 18 March 2011 09:57, Luiz Henrique de Figueiredo
<lhf@tecgraf.puc-rio.br> wrote:
> BTW, we plan to release Lua 5.1.5 with this patch "soon".
> If you have any other bugs 5.1.4 to report, please do so now.
> Thanks.
> --lhf
>
>
xpcall does not handle ERRERR how it should.
The error handler for the error handler is itself; not the upper scope
as you would imagine.
a=function() error("a") end
b=function(e) print("b",e) end
xpcall(a,b)
This bug stops you from being able to bubble up errors.
a = function() error{type="foo"} end
xpcall(a,function(err) if err.type == "bar" then else error(err) end end)
==> you'd imagine that the error in the error handler would re-throw the error.
Daurn.