dmd 1.056 and 2.040 release
Andrei Alexandrescu
SeeWebsiteForEmail at erdani.org
Sat Jan 30 09:31:41 PST 2010
Ary Borenszweig wrote:
> Walter Bright wrote:
>>
>> http://www.digitalmars.com/d/1.0/changelog.html
>> http://ftp.digitalmars.com/dmd.1.056.zip
>>
>>
>> http://www.digitalmars.com/d/2.0/changelog.html
>> http://ftp.digitalmars.com/dmd.2.040.zip
>>
>> Thanks to the many people who contributed to this update!
>
> Very nice! Each release kills a lot of bugs and adds small but very
> powerful features.
>
> About the interface functions, this compiles:
>
> --
> import std.stdio;
>
> interface One {
>
> final void foo() {
> writefln("One");
> }
>
> }
>
> interface Two {
>
> final void foo() {
> writefln("Two");
> }
>
> }
>
> class X : One, Two {
> }
>
> class Y : Two, One {
> }
>
> void main() {
> X x = new X();
> x.foo(); // prints "One"
> Y y = new Y();
> y.foo(); // prints "Two"
> }
> --
>
> Is this intended behaviour? Might leads to obscure bugs...
I think this should lead to a compile-time error.
Andrei
More information about the Digitalmars-d-announce
mailing list