Originally Posted by Naisz
But i guess, that ns.<functionname> then refers to the name of the function inside the namespace rather than a function inside the namespace.
|
No,
function tbl:func() is just syntactic sugar for
tbl.func = function(self). Just like calling
tbl:func() is syntactic sugar for
tbl.func(tbl). You can read more about Lua's function definitions
here.
Originally Posted by Kanegasi
Code:
function ns["UpdateAuraIcon"](ns, button)
|
That's not valid Lua, unless you meant to call the function. In that case you have to remove
function from the line.