lua-users home
lua-l archive

Re: Lua API Help

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


> int lua_iterator_next(lua_State* L)
> {
> int max = (int) lua_tonumber(L, lua_upvalueindex(1));
> int cur = (int) lua_tonumber(L, lua_upvalueindex(2));
> [...]
Have you tried to keep the numbers as "lua_Number"s? The cast from
float/double to int is slow in some machines...
-- Roberto

AltStyle によって変換されたページ (->オリジナル) /