vararg
is a Lua library for manipulation of vararg expressions.
These functions basically allow you to do things with vararg that
cannot be efficiently done in pure Lua but can be easily done through the C API.
You can install it from source using LuaRocks:
luarocks make etc/vararg-scm-1.rockspec
vararg.concat
andvararg.map
now work with functions that yield.
-
Lua 5.3 compatibility.
-
Performance improvement in 'vararg.pack'.
-
Removal of limitation of max 255 values to pack using 'vararg.pack'.
-
Function
vararg.append
requires a value to be appended. -
Function
vararg.range
and vararg packs (vararg.pack
) does not fill the resulting range withnil
values.Therefore
vararg.range(2, 4, 1,2,3)
will return2,3
instead of2,3,nil
.Likewise,
vararg.pack(1,2,3)(2, 4)
will return2,3
instead of2,3,nil
. -
Function
vararg.remove
does not raise out of bound errors. -
Function
vararg.concat
now only takes a single function which results are appended to the additional arguments. -
New function
vararg.len
. -
Reference manual.
-
No more a pure Lua alternative implementation.
- New operation
vararg.map
.
- First release.