Commit b2a102fb authored by Vicențiu Ciorbaru's avatar Vicențiu Ciorbaru Committed by Vicențiu Ciorbaru

Fix double floating point error in dtoa.c

When running an optimized build, compiler optimizations cause loss of
precision unless we force the expression to use a double type.
parent f9f976b2
......@@ -1290,7 +1290,7 @@ static double ratio(Bigint *a, Bigint *b)
dval(&db)= b2d(b, &kb);
k= ka - kb + 32*(a->wds - b->wds);
if (k > 0)
word0(&da)+= k*Exp_msk1;
word0(&da)+= k*Exp_msk1 * 1.0;
else
{
k= -k;
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment