Answers for "lua metatable assignment"

Lua
1

lua metatable assignment

t = {}
print(getmetatable(t))   --> nil

t1 = {}
setmetatable(t, t1)
assert(getmetatable(t) == t1)   --> true
Posted by: Guest on November-01-2020

Browse Popular Code Answers by Language