[Issue 24819] Optimizer changes result of float calculations on 32-bit
d-bugmail at puremagic.com
d-bugmail at puremagic.com
Tue Oct 15 13:52:29 UTC 2024
https://issues.dlang.org/show_bug.cgi?id=24819
--- Comment #1 from Dennis <dkorpel at live.nl> ---
Reduced:
```
import core.stdc.stdio;
pragma(inline, true)
double sqrt(double x)
{
static import core.math;
return core.math.sqrt(x);
}
void main()
{
double q = -1.0;
double r = q + 0.1;
double result = sqrt(-r);
printf("%f\n", result);
}
```
--
More information about the Digitalmars-d-bugs
mailing list