This is the mail archive of the
gcc-bugs@gcc.gnu.org
mailing list for the GCC project.
Possible bug, or at least a severe inconvience.
- To: egcs-bugs at cygnus dot com
- Subject: Possible bug, or at least a severe inconvience.
- From: Scott A Crosby <crosby at qwes dot math dot cmu dot edu>
- Date: Sun, 8 Nov 1998 14:08:05 -0500 (EST)
- Reply-To: Scott A Crosby <crosby at qwes dot math dot cmu dot edu>
Hello, I have some code which I wish to have inlined automatically, thus I
am defining it within the class declaration. To make it look pretty, I
wish to have all of the function declarations listed first, and then do
the actual defintions later within the class. Anyways,
If this is non-standard, I think that it still would be a useful
extension. It certainly was keeping my files easier to read.. Other than
this, you have a great compiler, keep up the good work!
class foo {
public:
int bar();
int bar() { return 10;};
};
[crosby@hypercube indep_study]# g++ -c -o /tmp/foo /tmp/foo.cpp
/tmp/foo.cpp:4: `foo::bar()' is already defined in class foo
[crosby@hypercube indep_study]# g++ --version
egcs-2.91.57