[Issue 10699] New: override inconsistently allowed for abstract functions

d-bugmail at puremagic.com d-bugmail at puremagic.com
Mon Jul 22 18:33:23 PDT 2013


http://d.puremagic.com/issues/show_bug.cgi?id=10699

           Summary: override inconsistently allowed for abstract functions
           Product: D
           Version: D2
          Platform: All
        OS/Version: All
            Status: NEW
          Severity: normal
          Priority: P2
         Component: DMD
        AssignedTo: nobody at puremagic.com
        ReportedBy: andrej.mitrovich at gmail.com


--- Comment #0 from Andrej Mitrovic <andrej.mitrovich at gmail.com> 2013-07-22 18:33:22 PDT ---
-----
interface IC
{
    abstract void foo();

    abstract void bar();
}

class AC : IC
{
    override void foo() { }
}

class CC : AC
{
    override void bar() { }
}
-----

$ Error: function test.CC.bar does not override any function, did you mean to
override 'test.IC.bar'?

If we're allowed to use 'override' for implementing abstract methods in AC, why
is it not allowed in CC?

Also related: http://d.puremagic.com/issues/show_bug.cgi?id=9978

-- 
Configure issuemail: http://d.puremagic.com/issues/userprefs.cgi?tab=email
------- You are receiving this mail because: -------


More information about the Digitalmars-d-bugs mailing list