lua-users home
lua-l archive

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


It would be nice for some debugging type tasks if it was possible, using either the C or Lua Debug API, to get the arity of a function, that is its Proto's numparams and is_vararg field.

In a fevered moment I did think that #f could be the arity of the function f. Kind of appealingly hacky, but there's no obvious way to encode the varargness as well.

drj