------- Additional Comments From pinskia at gcc dot gnu dot org 2005-03-11
15:11 -------
Hmm, ICC gives:
t.cc(7): warning #654: overloaded virtual function "Foo::Func" is only
partially overridden in class "Baz"
class Baz: public Foo
^
t.cc(14): error #165: too few arguments in function call
b->Func(1);
^
compilation aborted for t.cc (code 2)
The warning is correct because Func(int) is still hidden in the supper class
and you cannot use it:
class Foo
{
public: virtual void Func(int);
virtual void Func(int, int);
};
class Baz: public Foo
{
public: virtual void Func(int, int);
};
void g(Baz *b)
{
b->Func(1);
}
Maybe we should do the warning which ICC is giving instead of the one which we
give right now.
--
What |Removed |Added
----------------------------------------------------------------------------
Severity|normal |minor
Keywords| |diagnostic
http://gcc.gnu.org/bugzilla/show_bug.cgi?id=20423