🚀 go-pugleaf

RetroBBS NetNews Server

Inspired by RockSolid Light RIP Retro Guy

1 total messages Started by bilmes Fri, 31 Jul 1992 15:05
Nested Class bug in g++ 2.2.2
#213
Author: bilmes
Date: Fri, 31 Jul 1992 15:05
29 lines
2095 bytes
- ----------------------------------------------

class X {
public:
  struct M2 { int m; };
  M2 g(int);
};


X::M2 X::g(int i) { X::M2 m2; return m2; } // line 9

main() {
}
- ----------------------------------------------


Reading specs from /usr/local/lib/gcc-lib/mips-dec-ultrix4.2/2.2.2/specs
gcc version 2.2.2
 /usr/local/lib/gcc-lib/mips-dec-ultrix4.2/2.2.2/cpp -lang-c++ -v -undef -D__GNUC__=2 -D__GNUG__=2 -D__cplusplus -D__ANSI_COMPAT -DMIPSEL -DR3000 -DSYSTYPE_BSD -D_SYSTYPE_BSD -Dbsd4_2 -Dhost_mips -Dmips -Dultrix -Dunix -D__ANSI_COMPAT -D__MIPSEL__ -D__R3000__ -D__SYSTYPE_BSD__ -D___SYSTYPE_BSD__ -D__bsd4_2__ -D__host_mips__ -D__mips__ -D__ultrix__ -D__unix__ -D__ANSI_COMPAT -D__MIPSEL -D__R3000 -D__SYSTYPE_BSD -D___SYSTYPE_BSD -D__bsd4_2 -D__host_mips -D__mips -D__ultrix -D__unix -I/usr/local/lib/gcc-lib/m
ips-dec-ultrix4.2/2.2.2/lib/g++-include -D__LANGUAGE_C_PLUS_PLUS__ -D__LANGUAGE_C_PLUS_PLUS -D__LANGUAGE_C__ -D__LANGUAGE_C -DLANGUAGE_C test.cc /usr/tmp/cca09905.i
GNU CPP version 2.2.2 [AL 1.1, MM 19] DECstation running ultrix
 /usr/local/lib/gcc-lib/mips-dec-ultrix4.2/2.2.2/cc1plus /usr/tmp/cca09905.i -quiet -dumpbase test.cc -version -o /usr/tmp/cca09905.s
GNU C++ version 2.2.2 [AL 1.1, MM 19] DECstation running ultrix compiled by GNU C version 2.2.2.
test.cc:9: semicolon missing after declaration of `M2'
test.cc: In method `int  X::g (class X*, int)':
test.cc:9: conflicting types for `int  X::g (class X*, int)'
test.cc:5: previous declaration of `struct X::M2 X::g (int)'
test.cc: In method `struct X::M2 X::g (int)':
test.cc:9: aggregate value used where an integer was expected
Thread Navigation

This is a paginated view of messages in the thread with full content displayed inline.

Messages are displayed in chronological order, with the original post highlighted in green.

Use pagination controls to navigate through all messages in large threads.

Back to All Threads