
Swift 5 Module Stability Workaround for Binary Frameworks - charlotteswan
https://instabug.com/blog/swift-5-module-stability-workaround-for-binary-frameworks/
======
helge5
Well, that was possible since Swift 1.0, wasn't it? It is using Objective-C as
a proper ABI just like Windows people use COM to mix and match different C and
C++ versions. Except that Apple doesn't provide proper dylib sharing (which
doesn't really require an ABI in the first place, just versioning).

~~~
HeshamMegid
It wasn't possible until Swift 5 because of ABI stability. If we were to do
that before Swift 5, we would still have to create binaries for each version
of Xcode/iOS.

~~~
helge5
The ABI stability in the article is solely provided by ObjC, not by Swift. The
"Swift ABI" of 5 only helps you with not having to embed the Swift libraries
within the ObjC shielded module. (it "just" makes it smaller) The point of the
article is that you can use the stable ObjC ABI to wrap the Swift
incompatibilities. And that was technically possible since Swift v1.

------
saagarjha
The title is slightly misleading, because Swift 5 does not have module
stability, so the publicly facing code cannot use the Swift interface. It must
use Objective-C (C should be valid too, but I don't think the attribute for
this is public yet?)

~~~
sctb
Yes, we've reverted the submitted title from “Swift 5 finally makes it
possible to build binary frameworks” to that of the article.

