lua-users home
lua-l archive

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


Em ter., 27 de out. de 2020 às 14:26, Ranier Vilela <ranier.vf@gmail.com> escreveu:

Em ter., 27 de out. de 2020 às 10:29, Sergey Kovalev <kovserg33@gmail.com> escreveu:
Try to write: attest.lua
function dump(x) for k,v in pairs(x) do print(k,v) end end
dump(_G);
Thanks for the hint.

Added the line require "libtest", I don't know if it made a difference.
The dump suggested, show my module functions:
testfuncs  table: 000001A9740D72A0
like
io      table: 000001A9740D1780

Why Lua 5.4, do not find it in "testfuncs table"?
Solved. In Lua program, with functions stored in table, need the namespace:
table.function

Thank you Sergey Kovalev.

Ranier Vilela