Thread View: gnu.g++.lib.bug
1 messages
1 total messages
Started by Ron Sommeling
Wed, 15 Apr 1992 07:48
Rational class
Author: Ron Sommeling
Date: Wed, 15 Apr 1992 07:48
Date: Wed, 15 Apr 1992 07:48
24 lines
1392 bytes
1392 bytes
There seems to be a bug in the Rational class of libg++ 2.0.
The following program is compiled with g++ 2.1 on a SPARCstation 1 running
SunOS 4.1.1
Ron Sommeling <Ron.Sommeling@cwi.nl>
% cat t.cc
#include <iostream.h>
#include <Rational.h>
main() {
cout << Rational(2,3) << endl;
}
% g++ -v t.cc
Reading specs from /usr/local/lib/gcc-lib/sparc-sun-sunos4.1/2.1/specs
gcc version 2.1
/usr/local/lib/gcc-lib/sparc-sun-sunos4.1/2.1/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 t.cc /usr/tmp/cca02232.i
GNU CPP version 2.1 (sparc)
/usr/local/lib/gcc-lib/sparc-sun-sunos4.1/2.1/cc1plus /usr/tmp/cca02232.i -quiet -dumpbase t.cc -version -o /usr/tmp/cca02232.s
GNU C++ version 2.1 (sparc) compiled by GNU C version 2.1.
as -o t.o /usr/tmp/cca02232.s
ld -e start -dc -dp /lib/crt0.o -L/usr/local/lib/gcc-lib/sparc-sun-sunos4.1/2.1/ -L/usr/local/lib/ t.o -lg++ -lgcc -lc -lgcc
% ./a.out
Segmentation fault
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