This is the mail archive of the
gcc-bugs@gcc.gnu.org
mailing list for the GCC project.
Bug: "using" doesn't work
- To: "egcs-bugs at cygnus dot com" <egcs-bugs at cygnus dot com>
- Subject: Bug: "using" doesn't work
- From: Bernd Eggink <eggink at uni-hamburg dot de>
- Date: Tue, 03 Nov 1998 16:16:47 +0100
- Organization: Regionales Rechenzentrum der Uni Hamburg
This should compile:
------------------------
class A
{ public:
void f(int) { }
};
class B: public A
{
public:
using A::f;
void f(char*) { }
};
int main()
{
B b;
b.f(4711);
return 0;
}
------------------------
But I get:
tst.cpp:10: cannot adjust access to `void A::f(int)' in `class B'
tst.cpp:9: because of local method `void B::f(char *)' with same name
tst.cpp: In function `int main()':
tst.cpp:15: no matching function for call to `B::f (int)'
tst.cpp:9: candidates are: B::f(char *)
Version:
Reading specs from
/usr/local/lib/gcc-lib/i586-pc-linux-gnulibc1/egcs-2.91.57/specs
gcc version egcs-2.91.57 19980901 (egcs-1.1 release)
BTW, is there something like a bug list (I'm new to the list)?
Regards,
Bernd
--
Bernd Eggink
Regionales Rechenzentrum der Uni Hamburg
eggink@uni-hamburg.de
http://www.rrz.uni-hamburg.de/eggink/BEggink.html