Kotlin Release news: Kotlin 1.2.60, Kotlin 1.3 M1, Kotlin Native 0.8

Some good news coming from Jetbrains, who have been tirelessly working on expanding and improving Kotlin and the tools provided with it. In this post I’ll provide an overview of the latest news.

Kotlin 1.2.60 Released

Kotlin 1.2.60 was released on august 1st, a bugfix and tooling release for Kotlin. The update focuses primarily on tooling support adding new features to the various plugins available for your favorite IDE’s.

Some of the features:

  • Adds optional expected annotations to multiplatform projects
  • Allows building multiplatform projects with IntelliJ IDEA
  • Introduces experimental kapt mode aimed to speed up Gradle builds
  • Adds new refactorings, inspections, and intentions to the IntelliJ IDEA plugin
  • Fixes a lot of known issues in the compiler and the IDE plugin and provides performance improvements

All-in-all a good set of new features which should make the decision of upgrading an easy one. For more information on what’s included in the package, have a look here: https://blog.jetbrains.com/kotlin/2018/08/kotlin-1-2-60-is-out/

Kotlin 1.3 Milestone 1

More good news: Kotlin version 1.3 has reached its first major milestone, which means a release should not be too far away. We can already check out and play around with the new features that will be officially released once Kotlin 1.3 hits GA status.

Some highlights:

  • Coroutines will be classified stable. As they are currently still marked experimental this could be a long-awaited release for those of you who have used coroutines in the wild but were struggling to sell the idea to those who do not yet trust experimental technology 😉
    You will need to make some changes to your existing coroutine code, which is highlighted in the link below.
  • We will also be able to capture the ‘when’  subject in a variable. This is a feature that was requested a lot and allows logic to flow more cleanly in a when statement:
    when(val status = executeRequest().status) {
        ACCEPTED -> println("Request successful")
        else -> println("Unexpected status: ${status.value()}")
  • @JvmField and @JvmStatic can now be used for fields in companion objects for interfaces;
  • Nested declaration in annotations classes are now allowed (as seen in the previous point, by allowing them in interfaces, they are also allowed in annotation classes);
  • Functional types can now have the maximum number of parameters — 255 –, a limit imposed by the JVM, as opposed to ‘just’ 22. An impressive feature, not sure if you want to push this particular limit, though…
  • API consistency improved with isNullOrEmpty and orEmpty extension functions, that are now consistently available for collections, maps and arrays;
  • Companion object for the Boolean type. Unlike for instance Int, Byte and Double, Boolean did not have a companion object. In release 1.3 it will have one with useful features, as highlighted in the link below.

In addition to all this goodness, some experimental features have been added too:

  • Support for inlined classes;
  • Unsigned integer types for unsigned arithmetic;
  • Annotations marking experimental API’s and allowing opt-ins for them;

Lots of good stuff to get properly excited about — find more about the release and how to start using it here: https://blog.jetbrains.com/kotlin/2018/07/see-whats-coming-in-kotlin-1-3-m1/

Kotlin/Native 0.8

And finally, last but not least Kotlin/Native 0.8 has been released. Among the features:

  • safer concurrent programming
  • extending the stdlib functionality
  • better iOS development support

Read more about the release here: https://blog.jetbrains.com/kotlin/2018/07/kotlinnative-v0-8-released/

Have fun exploring these new releases, we are planning a (few) blogpost(s) on the new features introduced in the main Kotlin releases.

This entry was posted in Kotlin, News. Bookmark the permalink.

Leave a Reply

Your email address will not be published. Required fields are marked *