Movement against float.init being nan
bachmeier
no at spam.net
Fri Aug 19 18:04:46 UTC 2022
On Friday, 19 August 2022 at 17:14:35 UTC, Steven Schveighoffer
wrote:
> I also would prefer that all floats/doubles default to 0
> instead of NaN.
It would be awful to choose an arbitrary, often incorrect value
in order to give the appearance that your program is running.
It would be absurd to silently set the value of `z` to 1.0 in
this code:
```
double w;
double z = w*2.5 + 1;
```
Defaulting to 0 is no better than defaulting to a random number.
More information about the Digitalmars-d
mailing list