|
2013/10/4 Tysen Moore <tsmoore248@gmail.com>:
The hidden "arg" variable is a Lua 5.0 feature. It is only part of Lua 5.1
> I have a question regarding the usage of the ellipsis ("..."). I am seeing
> some sort of conflict with the hidden "arg" variable and the ellipsis. If I
> mix usage in a function I get bad results--arg goes nil. I have
> successfully used this operator in the past but somehow avoided this
> particular use case.
if LUA_COMPAT_VARARG is set in luaconf.h. Lua 5.1.x ships with
all compatibility options on by default, which makes one feel that the
hidden "arg" is part of Lua 5.1, but actually all that is promised is that
if you use it exactly as in Lua 5.0, you will not have problems. If you
use ellipsis in the same module, it's no longer exactly as in Lua 5.0.