WWDC 2014 and Swift

Apple’s Developers Conference WWDC 2014 debuted yesterday in San Francisco. They presented their latest achievements and plans for both their operating systems – OSX and iOS. The most interesting “creation” presented yesterday, for me, was the new programming language they have been developing for a while, called Swift.

Everybody was quite surprised to hear this news, as not everybody was expecting such a change. Opinions were immediately divided, some developers stating it is an incredible improvement whereas some say it’s only a change for the sake of change. Swift is supposed to replace Objective-C, a language that has been in use for 20 years. Swift can still be used in conjunction with Objective-C in all apps, and will be in beta until the release of iOS8 this fall.

Swift is integrated in the new XCode 6 Beta. It’s main advantage is that it’s claimed to be faster. Apart from that, it receives a more modern “face” by allowing closures, generics, type inference, multiple return types and namespaces. You can also access the Cocoa and Cocoa Touch frameworks with Swift and it’s also interactive, by introducing Playgrounds. Playgrounds help developers to see results in real time, without the overhead of building and running an app. This feature will be, of course, particularly useful for newbies.

So, even if now each developer has their own opinon regarding this issue, I believe only time will tell if Swift will indeed be a real alternative to Objective-C. I only learnt a few basics of Objective-C and I didn’t find it particulary hard. Now that Swift appeared and promises a simpler synatax and more modern approaches, it’s definitely a new language to consider learning. The fact that it’s only useful for iOS and OSX apps development, reduces, of course, its rate of adoption among developers. But since they say it is so similar to Objective-C and they made sure the transition is really smooth , I don’t see why it would be a bad idea. The library is now available, but not in its final version, so everybody who wants to start developing an iOS app or OSX one, can be ready to try Swift and decide if it is really a worthy change!