In Lua, how can you print the name of the current function, like the C99 __func__ identifier?
snippet in lua

In Lua, how can you print the name of the current function, like the C99 __func__ identifier?

user1214

#!/usr/bin/lua

local function myFunc()
 print(debug.getinfo(1, "n").name);
end
myFunc()