Feeling Swift today

I feel enthused by the recent announcement that Swift is now open source. This gesture by Apple opens the Swift programming language for use on other platforms, most notably on Linux.

Over the years I have used a bunch of languages. But, in the last 6 years I have been fortunate to program mostly in dynamical languages (Python and JavaScript). Though, I recently had to write a project in C, to achieve the higher performance you get with a compiled language. It suffice to say that I didn’t enjoy revisiting the particulars of that language.

A few months ago I dabbled with Rust, but found the ownership model difficult to wrap my head around when trying to write any real code (beyond toy examples). About the same time I had a brief rendezvous with Go, which was nice, but I never found a compelling reason to switch from Python to Go.

Some weeks ago I started reading up on Swift, driven by an impulse to write “something” for iOS or Mac. I found that Swift is a really nice language, and I love that it isn’t garbage collected and that it compiles to native code. If Swift had been open sourced a month ago, I would definitely have used it on my recent project, instead of C.

Swift provides a great balance between many tradeoffs, it is both very expressive and easy to learn, much like Python. Which is why I think it will gain wide adoption outside the Apple ecosystem, e.g., on Linux servers running web apps and APIs. Swift fits perfectly as a companion language to a dynamic language. I am convinced that, if you become fluent in Swift and JavaScript, you will have a great base to build on for years to come.