Upgrade to Xcode 8 without migrating to swift 3 !

We’re well into the betas of Xcode 8 which will contain the final release of Swift 3, hopefully set for release around the first couple weeks of September. With this next release of Xcode, we’re encouraged to update our Swift syntax to Swift 3 from 2.2 but – and this is unique to this major Xcode release so far – we’re not quite required to do so.

There’s a single build setting that will let you continue building your Swift projects with a Swift version that’s mostly similar in syntax to your existing projects from Xcode 7: Use Legacy Swift Language Version

Just drop into your project’s build settings and search for legacy swift to find the correct build setting, then switch the setting to YES to opt-in to Swift 2.3 rather than Swift 3 in Xcode 8.

legacy-swift

 

Swift 2.3
The primary changes in Swift 2.3 should end up being minor items such as nullability changes in core Objective-C libraries which will make moving your code from Xcode 7.3 to 8 pretty easy.

You’ll be able to get the benefits in Xcode 8 without having to move to Swift 3. These are improvements such as the Memory Debugger, Editor Extensions and my personal favorite: less unintentional changes to xib and Storyboard files!

mycodetips

Passionate about coding and software development holding 10+ Years of experience including 6+ years of experience on Mobile application Development.

More Posts