I've seen references on the web to an "override" keyword that allows the
compiler to check method signatures are the same where intended, ie. instead of
creating a new virtual function when a subclasses override method no longer
matches the superclass. (Microsoft compilers.)  This would be a very good api
enhancement.

http://msdn.microsoft.com/en-us/library/41w3sh1c.aspx

eg.:

struct I1 {
   virtual void f();
};

struct X : public I1 {
   virtual void f() override {}
};


-- 
           Summary: Support c++ override keyword
           Product: gcc
           Version: unknown
            Status: UNCONFIRMED
          Severity: normal
          Priority: P3
         Component: c++
        AssignedTo: unassigned at gcc dot gnu dot org
        ReportedBy: slime at apple dot com


http://gcc.gnu.org/bugzilla/show_bug.cgi?id=36796

Reply via email to