Open Source JVM Language Kotlin Reaches Milestone 8
Software development toolmaker JetBrains has announced a new milestone release of Kotlin, the open-source, Java Virtual Machine (JVM)-targeted programming language developed by the company.
According to the company, the Milestone Release 8 (M8) amps up the language's reflective capabilities, enhances its inlining functions, adds error reporting for platform signature clashes and expands the standard library with new functions.
If there's a spotlight improvement in Kotlin M8, it's probably the reflection for properties capability. The term "reflection" refers to the ability of code to "inspect" other code (or itself) in the same system. (Oracle's Java tutorials site offers some useful examples of reflection in action). Properties are now first-class objects in Kotlin. The "::propertyName" syntax allows coders to get or set an object's value, so they can also access the name of the property. And Kotlin's reflection is interoperable with Java's reflection.
"We will develop reflection capabilities further in the next few months," said JetBrains evangelist Hadi Hariri wrote in a Project Kotlin blog post. "The ultimate goal is to provide framework writers with really powerful tools for their needs. Things on the agenda include proper Kotlin class introspection, making types available through reflection, bringing reflection capabilities to callable references (::functionName) and more."
This release includes several breaking changes in the language. Among those changes, "private" in a package now means private to the current package inside the module. Packages with the same name in other modules won't see these definitions, Hariri explained, noting that packages are nested, which means that privates are also visible to subpackages in the same module. Also, extension Properties can no longer have backing fields (which, Hariri points out, "was never recommended anyway"). And Kotlin no longer allows "@" and "@@" as label names. Other breaking changes are highlighted in Hariri's blog post.
JetBrains began developing Kotlin in 2010 and released it in July 2011 for distribution under Apache 2 Open Source License. "We know that Java is going to stand long, but we believe that the community can benefit from a new statically typed JVM-targeted language free of the legacy trouble and having the features so desperately wanted by the developers," project lead Andrey Breslav said at the time. The company released the first Kotlin milestone (M1) in April 2012 with a plugin for the JetBrains IntelliJ IDEA dev tool suite.
In a separate announcement, JetBrains unveiled a new Web site and domain for the Kotlin project. "It would make no sense to be developing a language that is Open Source and not having an Open Source Web site and documentation," Hariri said. The new website is written entirely in Markdown and it's hosted on GitHub. A key improvement: lots of Edit Page features for easy contribution. Also, new tutorials and documentation.