Bug in ^^
bachmeier
no at spam.net
Tue Sep 17 17:05:33 UTC 2019
On Tuesday, 17 September 2019 at 16:50:29 UTC, Brett wrote:
> Wrong:
> import std.stdio;
> enum x = 100000000000000000;
> enum y = 10^^17;
>
> void main()
> {
> ulong xx = x;
> ulong yy = y;
> writeln(x);
> writeln(y);
> writeln(xx);
> writeln(yy);
> }
>
> 100000000000000000
> 1569325056
> 100000000000000000
> 1569325056
>
> I gave code to prove that I was right, why is it so difficult
> for people to accept? All I see is people trying to justify the
> compilers current behavior rather than think for themselves and
> realize something wrong!
>
> This not a difficult issue.
That output looks correct to me.
More information about the Digitalmars-d
mailing list