lua-users home
lua-l archive

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


> As you mention Lua 5.3: I haven't look too much into it, but if all
> double to in conversions go through "luaV_numtointeger" it seem to
> be safe for this problem.

Currently, there is only one exception, but that it is safe too:
conversions to lua_Unsigned, done only at the API (see lua_tounsignedx
in lapi.c), go through a more complicated process, to ensure that
all numbers are properly converted "mod 2^n". (Like the case for
luaV_numtointeger, in 5.3 these conversions should be rare.) We are
not sure we will keep this feature or make the conversion behave as
for regular integers.

-- Roberto