Bug 5554 – [qtd] Covariance detection failure

Status
RESOLVED
Resolution
FIXED
Severity
normal
Priority
P2
Component
dmd
Product
D
Version
D2
Platform
All
OS
All
Creation time
2011-02-09T01:44:00Z
Last change time
2012-02-20T23:09:27Z
Keywords
pull, rejects-valid
Assigned to
yebblies
Creator
samukha

Comments

Comment #0 by samukha — 2011-02-09T01:44:07Z
class MA { } class MB : MA { } class MC : MB { } class A { MA foo() { return null; } } interface I { MB foo(); } class B : A { override MC foo() { return null; } } class C : B, I { override MC foo() { return null; } } void main() { } ---- Error: function test.C.foo incompatible covariant types MA() and MB()
Comment #1 by yebblies — 2012-02-20T03:18:50Z
Comment #2 by github-bugzilla — 2012-02-20T22:06:00Z
Commit pushed to master at https://github.com/D-Programming-Language/dmd https://github.com/D-Programming-Language/dmd/commit/027fdbc892d7d2bd89e1d1b88accb53ca733f8de Merge pull request #746 from yebblies/issue5554 Issue 5554 - [qtd] Covariance detection failure
Comment #3 by github-bugzilla — 2012-02-20T23:09:07Z