dmd 1.046 and 2.031 releases
Derek Parnell
derek at psych.ward
Sun Jul 5 23:30:44 PDT 2009
On Sun, 05 Jul 2009 22:05:10 -0700, Walter Bright wrote:
> Something for everyone here.
>
> http://www.digitalmars.com/d/1.0/changelog.html
> http://ftp.digitalmars.com/dmd.1.046.zip
>
> http://www.digitalmars.com/d/2.0/changelog.html
> http://ftp.digitalmars.com/dmd.2.031.zip
One of the very much appreciated updates here is "Implicit integral
conversions that could result in loss of significant bits are no longer
allowed.". An excellent enhancement, thank you.
But I am confused as this below compiles without complaint...
-----------
import std.stdio;
void main()
{
byte iii;
ubyte uuu = 250;
iii = uuu;
writefln("%s %s", iii, uuu);
}
-----------
Output is ...
-6 250
But I expected the compiler to complain that an unsigned value cannot by
implicitly converted to a signed value as that results in loss of
*significant* bits.
--
Derek Parnell
Melbourne, Australia
skype: derek.j.parnell
More information about the Digitalmars-d-announce
mailing list