This is the mail archive of the gcc-bugs@gcc.gnu.org mailing list for the GCC project.


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]
Other format: [Raw text]

[Bug c++/20710] g++ should warn when hiding non-virtual method in base class


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

--- Comment #6 from loose at astron dot nl 2010-11-01 12:54:25 UTC ---
OK, fair enough.

However, I reported this "bug", because I would like GCC to produce a warning
when hiding a non-virtual method in *existing* code; an option similar to
-Woverloaded-virtual.

New code could of course be written, using either C0x attributes or GCC
attributes. But that won't solve the issue for C98-compliant code.

I agree that it's preferable to remove duplicate bugs. However, I'm not sure
the bugs you mention are real duplicates, because at least some of them
explicitly refer to overriding (virtual) functions, whereas I'm referring to
overloading (non-virtual) functions.


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]