DMD 0.150 release

Stewart Gordon smjg_1998 at yahoo.com
Wed Mar 22 11:34:48 PST 2006


xs0 wrote:
> Stewart Gordon wrote:
>> xs0 wrote:
>>> Walter Bright wrote:
>>>> I wanted to get the interface covariant problem fixed for the 
>>>> library guys.
>>>>
>>>> http://www.digitalmars.com/d/changelog.html
>>>
>>> Out of curiosity - how did you implement it?
>>
>> The same way in which covariantly overriding a class method is 
>> implemented, surely.  Strikes me as trivial ... unless "the" interface 
>> covariant problem is something different from the two interface 
>> covariant problems I've seen....
> 
> Well, there's quite a difference between classes and interfaces in 
> handling covariance:
> 
> - all class references to the same object have the same value (i.e. they 
> point to the same address), regardless of their type
> - interface references to the same object, on the other hand, don't 
> point to the same address
<snip>

I think we are talking at cross purposes.

The two interface covariance problems I know of are:

(a) a method defined in an interface cannot be implemented with a 
covariant return type - this is a trivial matter of compile-time type 
checking and is now fixed

(b) strange things happen when you try to override a method with an 
interface return type to have a class return type - this bug is still there

http://d.puremagic.com/bugzilla/show_bug.cgi?id=65

What is this other issue you're talking about, which is also fixed?

Stewart.

-- 
-----BEGIN GEEK CODE BLOCK-----
Version: 3.1
GCS/M d- s:-@ C++@ a->--- UB@ P+ L E@ W++@ N+++ o K-@ w++@ O? M V? PS- 
PE- Y? PGP- t- 5? X? R b DI? D G e++>++++ h-- r-- !y
------END GEEK CODE BLOCK------

My e-mail is valid but not my primary mailbox.  Please keep replies on 
the 'group where everyone may benefit.



More information about the Digitalmars-d-announce mailing list