Summary: dmd finds a proper overload as a non-covariant
           Product: D
           Version: 2.021
          Platform: PC
        OS/Version: Windows
            Status: NEW
          Keywords: rejects-valid
          Severity: normal
          Priority: P2
         Component: DMD

Here is a sample code that triggers an error:

// File I.d
module I;

import Base;

interface I

interface SubI : I

// File Base.d
module Base;

import I;

class Base
    I create() {
        return null;

class Derived : Base
    SubI create() {
        return null;

Compilation options: "dmd I.d"
Note that "dmd Base.d" compiles okay.


Reply via email to