This is the mail archive of the
gcc-bugs@gcc.gnu.org
mailing list for the GCC project.
2.95.1: warning about exceptions with -fno-exceptions
- To: egcs-bugs at egcs dot cygnus dot com
- Subject: 2.95.1: warning about exceptions with -fno-exceptions
- From: Carlo Wood <carlo at runaway dot xs4all dot nl>
- Date: Wed, 6 Oct 1999 16:14:47 +0200 (CEST)
Hi,
is this warning justified when using -fno-exceptions?
g++ -g -Wall -Woverloaded-virtual -Wundef -Wpointer-arith -Winline -Wwrite-strings -Werror -pipe -fno-exceptions -D__LIBCW__ -fpic -fpic -I- -I../../include -c debugmalloc.cc -o debugmalloc.o
cc1plus: warnings being treated as errors
debugmalloc.cc: In function `void * operator new(unsigned int)':
debugmalloc.cc:881: warning: operator new should throw an exception, not return NULL
debugmalloc.cc: In function `void * operator new [](unsigned int)':
debugmalloc.cc:947: warning: operator new should throw an exception, not return NULL
I suppose no test case is needed...
--
Carlo Wood <carlo@runaway.xs4all.nl>
PS version 2.95.1 (release)