This is the mail archive of the
gcc@gcc.gnu.org
mailing list for the GCC project.
Re: set_new_handler change
- To: gdt at linuxppc dot org (Gary Thomas)
- Subject: Re: set_new_handler change
- From: Joe Buck <jbuck at synopsys dot com>
- Date: Wed, 26 Aug 98 8:39:05 PDT
- Cc: jason at cygnus dot com, egcs at cygnus dot com, law at cygnus dot com
> > > Did we intentionally change this behavior?
> >
> > Yes. set_new_handler is supposed to have C++ linkage.
>
> What should be done with existing apps that were built with the old
> linkage? A most useful example that comes to mind is NetScape. This
> is a case where getting the application built using the new linkage
> may be difficult or impossible.
There are two possible interpretations of this:
1) I have Netscape source (OK, Mozilla). Here, doing
#include <new>
in any files referencing set_new_handler fixes the problem (the proper
declaration of set_new_handler is provided). If the code explicitly
declares set_new_handler extern "C", that's a bug, remove the bug.
2) I have a dynamically linked Netscape binary. But set_new_handler is
in libgcc.a, which is always statically linked. Your old binary will
keep working.
So what is the problem?