🚀 go-pugleaf

RetroBBS NetNews Server

Inspired by RockSolid Light RIP Retro Guy

1 total messages Started by Glenn P Parker Tue, 26 Jan 1993 02:29
gcc bug
#1425
Author: Glenn P Parker
Date: Tue, 26 Jan 1993 02:29
30 lines
1679 bytes
Submitted on behalf of Nickolay Yatsenko at Software Emancipation
Technology, Inc., Waltham, MA.

Reading specs from /usr/local/lib/gcc-lib/sparc-sun-sunos4.1/2.3.3/specs
gcc version 2.3.3
 /usr/local/lib/gcc-lib/sparc-sun-sunos4.1/2.3.3/cpp -lang-c++ -v -undef -D__GNUC__=2 -D__GNUG__=2 -D__cplusplus -Dsparc -Dsun -Dunix -D__sparc__ -D__sun__ -D__unix__ -D__sparc -D__sun -D__unix enum_9.C /usr/tmp/cca25966.i
GNU CPP version 2.3.3 (sparc)
 /usr/local/lib/gcc-lib/sparc-sun-sunos4.1/2.3.3/cc1plus /usr/tmp/cca25966.i -quiet -dumpbase enum_9.cc -version -o /usr/tmp/cca25966.s
GNU C++ version 2.3.3 (sparc) compiled by GNU C version 2.3.3.
enum_9.C: In method `void  X::f (enum X::S)':
enum_9.C:18: parse error before `='

// C++. From ARM 3.1c Name Spaces:
// "A name S can be declared as a type (... enum) and as a non-type (...) in
// a single scope"

// Declare a data object `E' in the same (`class  member') scope as 
// an enum type `E', and try to use it in member function.

class X {
	enum S { blue, pink };
	int S;			
public:
	void f (enum S arg) ;
};

void X::f (enum S arg)
{
	S = arg;	// g++ gives error on this line.
}
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