aboutsummaryrefslogtreecommitdiff
path: root/testes
diff options
context:
space:
mode:
authorRoberto Ierusalimschy <roberto@inf.puc-rio.br>2024-05-13 13:10:35 -0300
committerRoberto Ierusalimschy <roberto@inf.puc-rio.br>2024-05-13 13:10:35 -0300
commitdfbde4c7d540f81f2cc539741a2c1f4c00f91c10 (patch)
treeafb17d64bd9d7b5e61f94f373561c2fa98d5e713 /testes
parentde794a6527058e75b674118b35f39dcbb13e88b1 (diff)
downloadlua-dfbde4c7d540f81f2cc539741a2c1f4c00f91c10.tar.gz
lua-dfbde4c7d540f81f2cc539741a2c1f4c00f91c10.tar.bz2
lua-dfbde4c7d540f81f2cc539741a2c1f4c00f91c10.zip
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.
Diffstat (limited to 'testes')
-rw-r--r--testes/db.lua9
1 files changed, 9 insertions, 0 deletions
diff --git a/testes/db.lua b/testes/db.lua
index d3758c41..49ff8e3e 100644
--- a/testes/db.lua
+++ b/testes/db.lua
@@ -49,6 +49,15 @@ do
49end 49end
50 50
51 51
52-- bug in 5.4.4-5.4.6: activelines in vararg functions
53-- without debug information
54do
55 local func = load(string.dump(load("print(10)"), true))
56 local actl = debug.getinfo(func, "L").activelines
57 assert(#actl == 0) -- no line info
58end
59
60
52-- test file and string names truncation 61-- test file and string names truncation
53local a = "function f () end" 62local a = "function f () end"
54local function dostring (s, x) return load(s, x)() end 63local function dostring (s, x) return load(s, x)() end