, , ,

Swift on Android as a “1st Class Language?”


According to NextWeb, Google has blessed Apple’s Swift  (which is now open source) as a first class language for Android development. (wait.. wut?!?)

Seems odd given the lack of love between Apple and The Goog these daze.. but I can give you 8 billion and three reasons that this is a brilliant, money saving and possibly strategic move for Google.

Then first 8 billion reasons are measured in dollars — US$8B is, IIRC, the amount that Oracle is claiming in “damages” from Google for their “illegal” use of Java APIs to power its Java clone Dalvik which is the heart of Android development.  Let’s not get into the fact that APIs shouldn’t be copyrightable since they represent merely an interface rather than actual functionality. Imagine if manufacturers could copyright doors styles, the number of lug nut holes and positions on tires, and any other kind of common specifications that allow for the interoperability of every day objects. Nothing would work.  This is a poor use of Oracle’s vast resources. They need to start creating new products and innovating.  (Note: innovation is cheaper than litigation. Seriously. )

The last 3 reasons adopting swift is a great move for Google are around simple practicality:

  • Let’s be frank: Everyone (eventually) loathes Java.  Java used to be a lot of fun to write… well back in 1997. It’s become the COBOL of development languages.  Everything is so. freaking. heavy.  Oy. Vey. Its also buggy as all hell. Daily root canal is more fun prospect.
  • The world, for better or worse is moving towards very strongly typed functional languages. Java is a strongly typed language… but it’s not a functional one.. and if you try to use it as such you’re twisting yourself in knots for no great effect.  Oh, and you’re still writing in Java.  Also Swift has a benefit of looking a lot like Javascript — which makes it easier for a vast number of web developers (no picking on WebDevs – it’s not 2001 anymore, ok?) a large number of whom have never thought to touch a compiled language like Java or ObjC less reluctant to give it a try.  All wins — both for Apple and Google.
  • Apple has the greatest mind-share of any mobile platform.  There may be 3-4x as many actual Android phones out there, but 98 cents of every mobile dollar is spent on Apple platforms …iOS as a platform is just a lot easier to write for – as long as you follow the rules on how to adopt size classes, you don’t much care what device the end-user has.  Google probably rightly is betting that if they make it easier to switch than fight (to flip the script on an the old Tarrytown cigarette ad) iOS developers might be more willing to port their apps if they’re not already on a cross platform dev environment like Unity if they can literally reuse the huge majority of their existing code.

Will Google eventually drop Java for Android?  I dunno’ … but given Apple’s open sourcing of Swift — and their amazingly aggressive inclusion and adoption of outside fixes and languages enhancements —  there’s suddenly a lot more reasons for people who formerly thought of Swift as an Apple-only ‘ghetto’ who are now going to get their feet wet and see what the hoopla is about.

(Personally I come at it from the other side — I’ve been a developer on Apple platforms for decades — from 6502 assembler + Integer Basic, to 68K Assembly/Pascal/ObjPascal/MacApp/etc, to ObjC and now Swift —  and now that Swift is available on Linux I am champing at the bit to not have to write in JavaScript or Python for my server-side stuff ever, ever again. My only problem will be patience. It’s really not ready for production. …yet.)