[C++ PATCH] Fix placement new if operator new has 2nd argument REFERENCE_TYPE (PR c++/34862)
Jason Merrill
jason@redhat.com
Tue Feb 5 17:30:00 GMT 2008
It seems to me that this (and Ian's original patch) are approaching this
problem the wrong way: we shouldn't be trying to guess whether a pointer
is changing type based on the form of the call to new; this won't handle
a user-defined placement new, or a user-defined override of the
non-placement operator new which always returns the same pointer. Can't
we attach the CHANGE_DYNAMIC_TYPE_EXPR to the value returned from
operator new, rather than mess with the arguments?
Jason
More information about the Gcc-patches
mailing list