This is the mail archive of the
gcc@gcc.gnu.org
mailing list for the GCC project.
Re: class and member function with same names
- To: Kumar Neelakantan <kneelaka at PaineWebber dot COM>
- Subject: Re: class and member function with same names
- From: Alexandre Oliva <oliva at dcc dot unicamp dot br>
- Date: 23 Jun 1998 19:44:41 -0300
- Cc: egcs at cygnus dot com
- References: <3585A361.D88F7096@painewebber.com>
Kumar Neelakantan <kneelaka@PaineWebber.COM> writes:
> class reset { public: reset() {} ~reset() {} };
> class A { public: A() {} ~A() {} int reset() const { return 0; } };
> main() { reset r; A a; a.reset(); }
> test.cc:20: calling type `reset' like a method
> I am using egcs snapshot 19980608.
It seems to be fixed in the 19980621 snapshot.
--
Alexandre Oliva
mailto:oliva@dcc.unicamp.br mailto:aoliva@acm.org
http://www.dcc.unicamp.br/~oliva
Universidade Estadual de Campinas, SP, Brasil