[swift-evolution] SE-0151: Package Manager Swift Language Compatibility Version

Martin Waitz tali at admingilde.org
Wed Feb 8 01:19:18 CST 2017


Hello,

> The review of SE-0151 “Package Manager Swift Language Compatibility Version" begins now and runs through February 13, 2017.  The proposal is available here:
> 
> 	https://github.com/apple/swift-evolution/blob/master/proposals/0151-package-manager-swift-language-compatibility-version.md

I’ve one question regarding this proposal:
Why use the list `swiftLanguageVersions` instead of a simple `swiftLanguageVersion: Int = 3`?
What’s the advantage of being able to specify `[3,4]`?

If you already have a version 4 compiler, that one will be used anyway and if the source really is compatible with both versions,
it does not make any difference whether it will be run in version 3 or version 4 mode.
So just setting it to `3` has the same effect, right?

I think it’s enough to specify something like „this source is intended to be compiled in swift version 3 mode“.
Most of the time, that’s all you can specify anyway, because you don’t know which future versions happen to be compatible.

— 
Martin


More information about the swift-evolution mailing list