This is the mail archive of the
gcc-bugs@gcc.gnu.org
mailing list for the GCC project.
g++ 3.2.x prints warning, then it stops
- From: Harald Dunkel <Harri dot Dunkel at synopsys dot com>
- To: gcc-bugs at gcc dot gnu dot org
- Date: Tue, 14 Jan 2003 16:10:05 +0100
- Subject: g++ 3.2.x prints warning, then it stops
Hi folks,
On compiling the attached testcase g++ 3.2.x stops without
generating any code. Platforms affected:
RedHat 7.2, gcc 3.2.1, binutils 2.13.1
SunOS 5.8, gcc 3.2.1
HP-UX B.11.00, gcc 3.2.1, binutils 2.13.1
Debian (Sid, i.e. the current CVS version gcc 3.2.2)
This is the screen output:
% g++ -v -c testcase2.cxx
Reading specs from /usr/lib/gcc-lib/i386-linux/3.2.2/specs
Configured with: ../src/configure -v --enable-languages=c,c++,java,f77,proto,pascal,objc,ada --prefix=/usr --mandir=/usr/share/man --infodir=/usr/share/info --with-gxx-include-dir=/usr/include/c++/3.2 --enable-shared --with-system-zlib --enable-nls --without-included-gettext --enable-__cxa_atexit
--enable-clocale=gnu --enable-java-gc=boehm --enable-objc-gc i386-linux
Thread model: posix
gcc version 3.2.2 20030109 (Debian prerelease)
/usr/lib/gcc-lib/i386-linux/3.2.2/cc1plus -v -D__GNUC__=3 -D__GNUC_MINOR__=2 -D__GNUC_PATCHLEVEL__=2 -D__GXX_ABI_VERSION=102 -D__ELF__ -Dunix -D__gnu_linux__ -Dlinux -D__ELF__ -D__unix__ -D__gnu_linux__ -D__linux__ -D__unix -D__linux -Asystem=posix -D__NO_INLINE__ -D__STDC_HOSTED__=1 -D_GNU_SOURCE
-Acpu=i386 -Amachine=i386 -Di386 -D__i386 -D__i386__ -D__tune_i386__ testcase2.cxx -D__GNUG__=3 -D__DEPRECATED -D__EXCEPTIONS -quiet -dumpbase testcase2.cxx -version -o /tmp/ccyEMhbO.s
GNU CPP version 3.2.2 20030109 (Debian prerelease) (cpplib) (i386 Linux/ELF)
GNU C++ version 3.2.2 20030109 (Debian prerelease) (i386-linux)
compiled by GNU C version 3.2.2 20030109 (Debian prerelease).
ignoring nonexistent directory "/usr/i386-linux/include"
#include "..." search starts here:
#include <...> search starts here:
/usr/include/c++/3.2
/usr/include/c++/3.2/i386-linux
/usr/include/c++/3.2/backward
/usr/local/include
/usr/lib/gcc-lib/i386-linux/3.2.2/include
/usr/include
End of search list.
testcase2.cxx: In function `int testcase()':
testcase2.cxx:12: choosing `void operator+(const fix&, double)' over `operator+
'
testcase2.cxx:12: because worst conversion for the former is better than
worst conversion for the latter
Is there a chance to get this fixed for 3.2.2?
Regards
Harri
class fix
{
public:
friend void operator+(const fix&, double);
operator double() const;
};
int testcase()
{
fix a;
float b;
a+b;
return 0;
}