[swift-users] Can Swift 2.3 frameworks be used with a Swift 3.0 app?

Kenny Leung kenny_leung at pobox.com
Mon Jun 27 11:05:15 CDT 2016


Hmm… This sounds like a big weakness with the Swift Package Manager.

Since it downloads and compiles sources, frameworks that might otherwise be binary compatible to link with might not build and work when you update your dev tools.

-Kenny


> On Jun 27, 2016, at 8:59 AM, zh ao via swift-users <swift-users at swift.org> wrote:
> 
> Not with current Swift 3. Currently, the developing team make efforts on releasing Swift 3 together with iOS 10 and macOS 10.12 in September.
> 
> The primary goal of this release is to solidify and mature the Swift language and development experience. While source breaking changes to the language have been the norm for Swift 1 through 3, we would like the Swift 3.x (and Swift 4+) languages to be as source compatible with Swift 3.0 as reasonably possible. However, this will still be best-effort: if there is a really good reason to make a breaking change beyond Swift 3, we will consider it and find the least invasive way to roll out that change (e.g. by having a long deprecation cycle).
> 
> https://github.com/apple/swift-evolution
> 
> Zhaoxin​
> 
> On Mon, Jun 27, 2016 at 11:39 PM, Jens Alfke via swift-users <swift-users at swift.org> wrote:
> 
>> On Jun 27, 2016, at 8:30 AM, Daniel Dunbar via swift-users <swift-users at swift.org> wrote:
>> 
>> No, this is not possible. All of the code in a single process needs to be compiled with the same version of Swift.
> 
> How long will this be the case? The product I work on is distributed primarily as a compiled framework. If we port any of it to Swift we’d  first need some assurance of binary compatibility.
> 
> (Also, if you really mean all of the code in a process, that implies that Apple can’t implement any system frameworks in Swift. So it seems that this question ties in with the earlier one of “how long do we have to copy multi-megabyte compatibility shim libraries into our apps that use Swift?”)
> 
> ((At the risk of sounding flamey: this sort of confirms my rule of thumb that Swift version numbers have their decimal points misplaced. IMHO, ABI stability is a requirement for a true 1.0 release of a language that has dynamic loading.))
> 
> —Jens
> 
> _______________________________________________
> swift-users mailing list
> swift-users at swift.org
> https://lists.swift.org/mailman/listinfo/swift-users
> 
> 
> _______________________________________________
> swift-users mailing list
> swift-users at swift.org
> https://lists.swift.org/mailman/listinfo/swift-users



More information about the swift-users mailing list