Dealing with C++98/11 ABI incompatibilities

Michael Matz matz@suse.de
Wed Jul 4 13:41:00 GMT 2012


Hi,

On Wed, 4 Jul 2012, Richard Guenther wrote:

> > [... mangling change ...]
> 
> That would not address the issue of interoperability of a C++03 library 
> with a C++11 program or vice versa if they are using any of the changed 
> interfaces for interoperability.  Passing pointers to such objects still 
> would work and break unnoticed.

But it's the best we can possibly do _if_ we want to conform to c++11 in 
the v6 ABI.  IMHO we want to, so we have to at least make 98/11 code 
coexist in the same process image, which means mangling changes.  That the 
code can't interoperate is understood.

It will by the way not break unnoticed: interfaces using the problematic 
types would be mangled differently, and hence c++98 code would silently be 
resolved to a c++11 variant expecting a different layout.


Ciao,
Michael.



More information about the Libstdc++ mailing list