On 27.08.19 18:12, berni wrote:
import std.stdio;

void main()
    real[int] a;
    a[0] += 100;

results (independed of the used compiler) in


I was a little bit surprised, because a[0] += 100 should be the same as a[0] = a[0]+100, which leads to a range violation error. Furthermore, as we work with real, I'd expected the result to be NaN...

Is this a bug? I ask, because it would be quite convenient to use it the way it works now.

For what it's worth, it's in Bugzilla:

Reply via email to