|
related. I suspect this stems from a double to int32_t conversion. Since 0x0000ffffffff is outside the range of int32_t the conversion is returning an "integer NaN." In other words, the conversion is assumed to be signed, whereas the value you "want" is unsigned.
Conversions from float, double, or long double values to unsigned long are not accurate if the value being converted is larger than the maximum positive long value.