Skip to content

Comment on Looking back on Swift 3 and ahead to Swift 4parent

Comments

Well, how will Swift enforce that nobody outside of Apple distributes libraries that don't break ABI or API?

While a compile can't enforce APIs, the ABI generated by compiler.

The ABI is generated by the compiler in response to the code it is given. If you don't control the code, you can't guarantee an ABI. If you change the types of function arguments -- for example, adding fields to structs that are passed by value -- you will break ABI, even if the compiler doesn't change.

So, for C++, a good document about keeping ABI compatibility: https://community.kde.org/Policies/Binary_Compatibility_Issu...

AboutSource Built by g1lg1l

Hackerly is an independent reader for Hacker News, built on the public HN API. Not affiliated with Y Combinator.