mirror of
https://github.com/lua/lua
synced 2026-09-29 04:35:58 +03:00
Bug: Active-lines for stripped vararg functions
Lua seg. faults when asked to create the 'activelines' table for a vararg function with no debug information.
This commit is contained in:
parent
de794a6527
commit
dfbde4c7d5
3 changed files with 34 additions and 23 deletions
|
|
@ -49,6 +49,15 @@ do
|
|||
end
|
||||
|
||||
|
||||
-- bug in 5.4.4-5.4.6: activelines in vararg functions
|
||||
-- without debug information
|
||||
do
|
||||
local func = load(string.dump(load("print(10)"), true))
|
||||
local actl = debug.getinfo(func, "L").activelines
|
||||
assert(#actl == 0) -- no line info
|
||||
end
|
||||
|
||||
|
||||
-- test file and string names truncation
|
||||
local a = "function f () end"
|
||||
local function dostring (s, x) return load(s, x)() end
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue