[Date Prev][Date Next][Thread Prev][Thread Next]
[Date Index]
[Thread Index]
- Subject: Re: [ANN] Lua 5.2.0 (alpha) now available
- From: Ted Unangst <ted.unangst@...>
- Date: Tue, 16 Nov 2010 09:53:33 -0500
On Tue, Nov 16, 2010 at 8:15 AM, Luiz Henrique de Figueiredo
<lhf@tecgraf.puc-rio.br> wrote:
> Lua 5.2.0 (alpha) is now available at
> http://www.lua.org/work/lua-5.2.0-alpha-rc1.tar.gz
Consider the following code. I expect it to print "bad" once, but it
does so many times. The manual is a little unclear, but seems to
imply that xpcall(f, err) only puts f in protected mode. It shouldn't
catch errors in err. Does that make sense? This may be a semantic
change from 5.1, but is it still fixable in 5.2?
function t()
error("oops")
end
function c()
print("bad")
error("again")
end
xpcall(t, c)