From dfbde4c7d540f81f2cc539741a2c1f4c00f91c10 Mon Sep 17 00:00:00 2001 From: Roberto Ierusalimschy Date: Mon, 13 May 2024 13:10:35 -0300 Subject: 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. --- manual/manual.of | 12 ++++++------ 1 file changed, 6 insertions(+), 6 deletions(-) (limited to 'manual') diff --git a/manual/manual.of b/manual/manual.of index b68d41c9..c5c74696 100644 --- a/manual/manual.of +++ b/manual/manual.of @@ -8773,13 +8773,13 @@ The returned table can contain all the fields returned by @Lid{lua_getinfo}, with the string @id{what} describing which fields to fill in. The default for @id{what} is to get all information available, except the table of valid lines. -If present, -the option @Char{f} +The option @Char{f} adds a field named @id{func} with the function itself. -If present, -the option @Char{L} -adds a field named @id{activelines} with the table of -valid lines. +The option @Char{L} adds a field named @id{activelines} +with the table of valid lines, +provided the function is a Lua function. +If the function has no debug information, +the table is empty. For instance, the expression @T{debug.getinfo(1,"n").name} returns a name for the current function, -- cgit v1.2.3-55-g6feb