lua-users home
lua-l archive

Re: [ANN] Lua 5.4.0 (alpha-rc1) now available

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


On Thu, May 30, 2019 at 6:31 PM Roberto Ierusalimschy
<roberto@inf.puc-rio.br> wrote:
> ...
> I could not reproduce this. I get a traceback.
Maybe my description was not clear: With the following zz.lua file:
 smt = getmetatable('a')
 function smt.__close(s) error("err closing ".. s) end
 do local <toclose> x='XX'; local <toclose> y='YY' end
./lua zz.lua outputs:
 ./lua: zz.lua:2: err closing XX
No traceback.
if the 3rd line is replaced with
 do local <toclose> x='XX' end
then "./lua zz.lua" output is
 ./lua: zz.lua:2: err closing XX
 stack traceback:
 [C]: in function 'error'
 zz.lua:2: in function <zz.lua:2>
 zz.lua:3: in main chunk
 [C]: in ?
Do you get the same result?

AltStyle によって変換されたページ (->オリジナル) /