SwiftTNW2-1200x612

Google is said to be considering Swift as a ‘first class’ language for Android

Posted on Posted in News

About the time Swift was going open source, representatives for three major brands — Google, Facebook and Uber — were at a meeting in London discussing the new language. Sources tell The Next Web that Google is considering making Swift a “first class” language for Android, while Facebook and Uber are also looking to make Swift more central to their operations.

Google’s Android operating system currently supports Java as its first-class language, and sources say Swift is not meant to replace Java, at least initially. While the ongoing litigation with Oracle is likely cause for concern, sources say Google considers Swift to have a broader “upside” than Java.
Swift is also open source, which means Google could adopt it for Android without changing its own open source mobile structure.

Could Google do it?

Born at Apple as a replacement to Objective C, Swift quickly found favor with developers as an easy-to-write language that shed much of the verbosity and clumsy parameters other languages have. It was introduced at WWDC 2014, and has major support from IBM as well as a variety of major apps like Lyft, Pixelmator and Vimeo that have all rebuilt iOS apps with Swift.

Swift can’t be copy-pasted for any platform, though. Specifically, Android would need a runtime for Swift — and that’s just for starters.

Google would also have to make its entire standard library Swift-ready, and support the language in APIs and SDKs. Some low-level Android APIs are C++, which Swift can not currently bridge to. Those would have to be re-written.
Swift would also not be useful in bridging higher level APIs in Java; they’d have to be re-written as well.
Using Swift for Android is not impossible, though. Late last year, developer Romain Goyet toyed with Swift for Android — and had some success. While that project was completed well ahead of Swift being open source, it nonetheless proved that it can be done.

That project used the Android NDK, which allows other languages to be loosely implemented into Android. With an open source Swift and support from Google, Android apps wouldn’t require that toolkit.
All told, Google would have to effectively recreate its efforts with Java — for Swift. If the company is motivated enough, it’s very possible to do so without compromising on its open source values or ruffling any developer feathers along the way.

(All rights are reserved by respective authors)

One thought on “Google is said to be considering Swift as a ‘first class’ language for Android

Leave a Reply

Your email address will not be published. Required fields are marked *