|Kotlin JVM 1.0|
|Written by Kay Ewbank|
|Friday, 19 February 2016|
Jetbrains has released Kotlin 1.0, its open source general purpose programming language for JVM and Java.
If you're wondering if the world needs yet another programming language, this one might have what it takes to be worth learning. Jetbrains is best known for its Java IDE IntelliJ, and the developers there seem to have put a lot of thought into what makes a language attractive.
According to a blog post announcing the release, Kotlin has been developed to be:
"a pragmatic programming language for JVM and Android that combines OO and functional features and is focused on interoperability, safety, clarity and tooling support."
The pragmatism is perhaps the most important aspect of Kotlin; the developers wanted to make it a good tool, so the interoperability with existing code and infrastructure came top of the list. Andrey Breslav, lead language designer of Kotlin, says that:
"Kotlin would have been a whole lot easier to design and develop if not for the Java interop, Maven integration, Android compatibility! It would definitely be more elegant in many ways. But elegance, though highly appreciated, is not the primary goal here, the primary goal is being useful. And the less our users have to re-learn, re-invent, re-do from scratch, the more they can re-use, the better."
Kotlin can be used for server, desktop and mobile Android apps. It comes with its own standard library, and can interact with all Java libraries. The pragmatic approach meant the developers avoided inventing another packet manager and build system; as they point out, Maven and Gradle already exist with huge numbers of plugins. In contrast, the developers worked to make JDK-compatible collection interfaces to support the masses of Java code that work with JDK collections. Java 6 byte code support is also present to support the people who are still running Java 6.
One area where the developers of Kotlin have moved away from current practice is that of null references. These can result in null reference exceptions, or in Java in NullPointerExceptions, NPEs.
Kotlin’s type system is designed to eliminate NPEs, except if there's an explicit call to throw one; if external Java code has caused one; or if there's some data inconsistency with regard to initialization (an uninitialized this available in a constructor is used somewhere).
Kotlin has apparently been production ready for some two years, and has been used internally at JetBrains for writing their own products, including IntelliJ IDEA, JetBrains Rider, and JetBrains Account & E-Shop among others. The delay in releasing version 1.0 was apparently because the designers were:
"validating our design decisions in practice".
There's an online mini-ide that you can try alongside a set of sample problems to illustrate the basics of the language.
or email your comment to: email@example.com
|Last Updated ( Thursday, 18 February 2016 )|