lua-users home
lua-l archive

Overflow handling in lua

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


Hi,
lua is based on C and in the according headers
there are the following defines:
stdint.h:# define INT8_MAX		(127)
stdint.h:# define INT16_MAX		(32767)
stdint.h:# define INT32_MAX		(2147483647)
stdint.h:# define INT64_MAX		(__INT64_C(9223372036854775807))
stdint.h:# define UINT8_MAX		(255)
stdint.h:# define UINT16_MAX		(65535)
stdint.h:# define UINT32_MAX		(4294967295U)
stdint.h:# define UINT64_MAX		(__UINT64_C(18446744073709551615))
In which way does this apply to Lua and what happens if
an overflow happens when doing something like this
a=0
while a == a do
 a=a+1
end
Best regards,
mcc

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