3 ms·
C doesn't have a standardized ABI, either, and yet it's the most widely used ABI in the world anyway. Just because it isn't standardized doesn't mean it isn't
by kllrnohj 5y ago
C doesn't have a standardized ABI, either, and yet it's the most widely used ABI in the world anyway.
Just because it isn't standardized doesn't mean it isn't stable & relied upon anyway. Clang & G++ are ABI compatible with each other, for example, and more importantly (and relevantly) both libstd++ & libcxx strive to maintain ABI compatibility ( https://gcc.gnu.org/onlinedocs/libstdc++/manual/abi.html https://gcc.gnu.org/onlinedocs/libstdc++/manual/abi.html & https://libcxx.llvm.org/DesignDocs/ABIVersioning.html https://libcxx.llvm.org/DesignDocs/ABIVersioning.html )
- tambre 5y ago> both libstd++ & libcxx strive to maintain ABI compatibility They don't, but they do keep it stable.
- mst 5y agoAlternative phrasing: they strive to maintain "backwards compatibility" rather than "compatibility with each other".
- kllrnohj 5y agoFor libcxx & libstdc++ yes correct. Clang, however, does strive to maintain compatibility with G++. So you can build a library with clang & use it from g++. It strives, and for the most part achieves, to be a drop-in replacement for GCC, which includes ABI compatibility.