inline operator delete redefinition and in-charge deleting destructor
llewelly@xmission.com
llewelly@xmission.com
Wed May 12 04:08:00 GMT 2004
Christian BRUEL <christian.bruel@st.com> writes:
> I have the following problem with gcc3.3.3 on Solaris:
>
> If providing the definition of a destructor outside the module where
> "delete" is called, the compiler instantiates a function call to delete
> to the standard library, thus missing my definition.
>
> See the following program:
>
> Of course, I comment out the "#include "new"" in ddef.cxx the
> program
'new' is a standard C++ library header. if you re-define it, the
behavior is undefined.
If you aren't trying to re-implemtn part of the C++ standard library,
you have no business naming a header file 'new'.
Otherwise, investigate -nostdinc++, see: http://xrl.us/b2qw
[snip]
More information about the Gcc-help
mailing list