From 7237eb3f1c480d6bc7fe2832ddd36f2137fb69d9 Mon Sep 17 00:00:00 2001 From: Roberto Ierusalimschy Date: Thu, 15 Feb 2024 11:18:34 -0300 Subject: Fixed warnings from different compilers --- lmathlib.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) (limited to 'lmathlib.c') diff --git a/lmathlib.c b/lmathlib.c index c0a75f06..c1041f37 100644 --- a/lmathlib.c +++ b/lmathlib.c @@ -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; } -- cgit v1.2.3-55-g6feb