I'm a JavaScript developer who's learning Lua. I'm stuck with a problem of getting a function's arity in the Lua language.
In JavaScript, it's simple:
function test (a, b) {}
console.log(test.length) // 2
How is it possible to do it this easily in Lua?
function test (a, b) end
print(#test) -- gives an error..