www.digitalmars.com         C & C++   DMDScript  

digitalmars.D.bugs - [Issue 10271] New: override const message is not helpful

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

           Summary: override const message is not helpful
           Product: D
           Version: D2
          Platform: All
        OS/Version: All
            Status: NEW
          Severity: enhancement
          Priority: P2
         Component: DMD
        AssignedTo: nobody puremagic.com
        ReportedBy: ellery-newcomer utulsa.edu


--- Comment #0 from Ellery Newcomer <ellery-newcomer utulsa.edu> 2013-06-04
18:29:03 PDT ---
class A {
    string filename() const { return "1";}
}

class B : A {
    override string filename() { return "2";}
}

void main(){
}

yields

tink.d(6): Error: function tink.B.filename does not override any function, did
you mean to override 'tink.A.filename'?

There should probably be some mention of const in there.

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