This is the mail archive of the gcc@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]

Re: class and member function with same names


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



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