[cfe-dev] libc++ ABI stability

Howard Hinnant hhinnant at apple.com
Tue May 24 08:23:55 PDT 2011


On May 24, 2011, at 11:17 AM, David Blaikie wrote:

> Every once in a great while (e.g. maybe for the next C++ standard), we could issue a new ABI, which would then live in a different inlined namespace (e.g. std::_2).  There would be config macro to choose the ABI.
> 
> That seems fairly infrequent. I believe VS, for example, deliberately breaks ABI compatability across every crelease. Implementing things like SCARY iterators, otherwise cleaning up the footprint of collections, etc. Adding checked/debug iterators. All these would be ABI breaking, wouldn't they? (well, the ABI of the code that uses libc++, that is - you couldn't keep using a static/dynamic lib compiled with an old version of libc++ if you wanted to pick up the new version)
> 
> Or am I misunderstanding/missing something here?

I don't think you're misunderstanding.

And to be honest, my crystal ball works better on some days than others.  Our intent is to try to hold the ABI steady for awhile, and when we do break it, version it.  Inline namespaces have never been used for a large long-term project like this, so we'll see how it goes.

Howard




More information about the cfe-dev mailing list