mirror of
https://github.com/lua/lua
synced 2024-11-22 04:41:23 +03:00
Avoids a warning when lua_Number is 'float'
This commit is contained in:
parent
e288c5a918
commit
8b83417de9
@ -352,7 +352,7 @@ static lua_Number I2d (Rand64 x) {
|
||||
SRand64 sx = (SRand64)(trim64(x) >> shift64_FIG);
|
||||
lua_Number res = (lua_Number)(sx) * scaleFIG;
|
||||
if (sx < 0)
|
||||
res += 1.0; /* correct the two's complement if negative */
|
||||
res += l_mathop(1.0); /* correct the two's complement if negative */
|
||||
lua_assert(0 <= res && res < 1);
|
||||
return res;
|
||||
}
|
||||
|
Loading…
Reference in New Issue
Block a user