Guest Post - Opa and Swift: A Review of Up-and-Coming Languages Vying for Their Place in Your Toolbox (Part 2 of 2)
By Guest Author: Joe EllegoodIn my last post, we looked at how software development work (TIOBE) is being done on a few staid languages and asked the question of their being enough room for improvement to justify more programming languages being added to the mix. When you work in programming, you can expect plenty of improvements to existing languages that you already have in your toolbox – all while new languages emerge on the market that seek to “revolutionize” with new features and syntax that older languages cannot match (yet).For any developer, keeping up with all of the updates and additions to the market can be time-consuming and overwhelming. It can be hard to determine which languages are worth learning and contributing to (if that’s an option or interest) and which you can take a pass on. Bottom line: We all want solid tools that will allow us to do our work with greater ease and be maintainable in the future.Previously, I examined the languages of Dart, Scala, Ceylon and Ceylon. All new(er) languages to the market. In this post, we’re going to look at Opa, language that touts itself to be “javascript on steroids,” and Swift, which was announced and released at the World Wide Developer’s Conf

erence in 2014. (Which, as a disclosure, I’ve since learned!)
Opa
Opa is an open-source programming language developed by MLstate that first appeared in 2011 with its 1.0 in June of 2012. Opa is more of a framework on top of JavaScript (described by its developers as “JavaScript on Steroids”) in much the same way as jQuery, but is different enough to warrant the “language” moniker all its own. Opa’s focus is on rapid and secure web development. This is achieved through many novel concepts that build on the foundation of JavaScript.In Opa, one can simultaneously do client-side and server-side scripting within the same module (JavaScript on the client, Node.js (or others) on the server). One of Opa’s biggest features is its emphasis on strong, static typing (uncommon in scripting languages), which makes it more secure and helps prevent against SQL injections. Building off static typing is the concept of Power Rows, which is a statically-typed extension of JavaScript objects, and is an interesting combination of dynamic and static programming. Opa’s full compatibility with JavaScript code helps make the transition almost seamless.My Take: Whereas Dart tries to replace JavaScript, Opa is building on JavaScript in meaningful ways. The fact that it only adds capabilities and niceties on top of JavaScript with no extra effort makes Opa easy to pick up. For web programming I think this language will do very well in the years to come.
Swift
Swift is the newest of t

he programming languages discussed in this article. Swift was announced by Apple at WWDC in June 2014 and its 1.0 version was released in September of 2014. Swift is Apple’s next programming language, their “Objective-C without the baggage of C”. Compared to Objective-C, Swift is a massive change in terms of syntax and features. Swift supports playgrounds (an interactive development environment, also known as a REPL), optionals (either “x has a value and it is _” or “x has no value”), type inference, extensions, protocols, and many others. Swift is scalable in some respects as it can be a scripting or application development language (the main purpose).Even though Swift is a replacement for Objective-C, it also is fully compatible with Objective-C libraries and runs in the same runtime as C and Objective-C code. As of right now Swift is solely in development at Apple and there are no current plans to open-source it (however the creator of Swift, Chris Lattner, has also worked on LLVM and Clang at Apple and that has since been open sourced). With that in mind, Swift is currently limited in use to products running Mac OS X or iOS. The main draw of Swift is providing an alternative to the polarizing Objective-C to the millions of developers currently creating applications for iOS devices and Mac OS X devices.My Take: Swift seems to have drawn from the right inspirations as it has a simple, clean syntax that has a lot of capabilities. As an Apple-only language I think it will flourish with iOS developers as it is much easier to code in than Objective-C. I appreciate Apple’s strict control over the language right now in order to build a solid foundation, though I will be interested to see how it develops over time (especially if it is open sourced).In the future, I see these languages doing very well for themselves. Opa adds smart, secure features to the ubiquitous JavaScript platform while maintaining compatibility that will allow for immediate growth. Swift provides iOS and Mac OS X developers with a lot of modern programming language features in a beautiful, concise syntax. Bottom line, no matter what language, it’s worth doing some research on and where the tool can benefit your work or add to your knowledge base, I say, “why not?”
About Guest Author Joe Ellegood:
[caption id="attachment_504" align="alignleft" width="150"]

Guest Author Joe Ellegood-Software Engineer[/caption]Joe Ellegood is a Software Engineer based in St. Louis, MO. A graduate of Missouri University of Science and Technology, Joe spends his free time researching and learning new programming languages, working on small hardware side projects, and gaming. He has worked with such notable companies as Garmin International, The Boeing Company, and Thompson Reuters.