This is the mail archive of the gcc@gcc.gnu.org mailing list for the GCC project.


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]
Other format: [Raw text]

Re: Double constructors in C++?


Ian Lance Taylor wrote:
Samuel Tardieu <sam@rfc1149.net> writes:

Why are constructors included twice in object code?

This is required by the C++ ABI.


It is, in my opinion, a real bug that gcc does not simply merge
identical constructors.

I agree.


Up until now, I think all of the patches have introduced additional thunks of some kind. Actually giving both names to the same entry point would avoid the ABI problems, and thus be non-controversial. (The ABI explicitly endorses multiple entry points as a solution.)

--
Mark Mitchell
CodeSourcery
mark@codesourcery.com
(650) 331-3385 x713


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]