lua-users home
lua-l archive

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

> ¶1 When a finite value of real floating type is converted to an integer type
> other than _Bool, the fractional part is discarded (i.e., the value is
> truncated toward zero). If the value of the integral part cannot be
> represented by the integer type, the behavior is undefined.)
> [...]
> Therefore, casting (double)0xFFFFFFFF to an unsigned int is valid, [...]

But it seems that casting (double)-1 to an unsigned int will result in
daemons flying out of our noses.

-- Roberto