lua-users home
lua-l archive

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


> Why not switch the implementations?  lua_absindex is the low-level
> function and lua_gettop is #defined as lua_absindex(L, -1).

When the stack is empty, the index -1 is invalid. But as long as
lua_absindex doen't mind about invalid indices, that definition is fine.

-- Roberto