bug report

David R Bacon dbacon@const.ml.org
Thu Apr 30 20:13:00 GMT 1998


Hello:
	I am not sure what I am supposed to do here, so.. here's what I
did:

	I attempted to do "C" stuff with a C++ compiler..
Inside a class, I have a function pointer that was meant to point to
either one of two other member functions(pointless I know).  This object
compiled ok, but when I make a reference to this function, the compiler
crashes with:

bash-2.01$ make
g++ -Wall -O4 -g -DDEBUG -include debug.h -c Pipe.cpp
g++ -Wall -O4 -g -DDEBUG -include debug.h -c Board.cpp
Board.cpp: In method `void Board::paintBoard()':
Board.cpp:46: Internal compiler error.
Board.cpp:46: Please submit a full bug report to `egcs-bugs@cygnus.com'.
make: *** [Board.o] Error 1
bash-2.01$ 


	- class Pipe contains the function pointer, Board::paintBoard uses
the function.

I fixed the problem by making another class APipe extend Pipe, overloading
the virtual function Pipe::paint.  This is the correct way to implement it
in C++ anyway, but I thought you might want this bug report(if it's indeed
a bug) at least to make the compiler exit giving the correct error
message.

Hope I am not wasting your time,
Thanks for the awesome free software,

	Dave Bacon
	drb6545@ksu.edu




More information about the Gcc-bugs mailing list