The Future of Kotlin Programming, According to an Expert

 The Future of Kotlin Programming, According to an Expert

“The Future of Kotlin Programming, According to an Expert” is the title of an article written by Mike Gouline of Jet Brains. 

In the article, Gouline describes Kotlin as a general-purpose language focused on interoperability and tooling support. Although its focus is currently android it can be used elsewhere. He uses this to predict what we should expect from the language in the future: since those parts which are not very interesting for mobile development will be backed off, other domains where Kotlin thrives should benefit more and become even stronger than before: web development and other things like scripting languages could gain importance thanks to Intellisense available by default, compile time verification of UI layout files, and so on.

Most other features that were built into the compiler or into IntelliJ IDEA (like automatic generation of property getters/setter) will

Below are some excerpts.

Mike starts off by discussing a tweet from a couple years back:

Kotlin is now Open Sourced: “In November 2017 we announced that we’re going to release the complete source code of Kotlin under Apache 2.0 with a dual license (the developer tools will be available under the BSD 3-clause license). We wanted to make it as easy as possible for everyone to use Kotlin, and opening up the source code is a good step towards that goal. Now anyone can not only read through our implementation, but also suggest improvements and even contribute their own changes.”

Two years later, Mike feels that Kotlin has been “a huge success story” with ~3 billion+ “kotlin” searches per month on Google, proving to be more popular than Swift or Go. Both of those were released by major companies as open source from day one.

Mike states:

Today I am going to share my thoughts on some of the current features, functionalities and capabilities of Kotlin, and how we expect it to evolve in the future.

Kotlin continues to be a replacement for Java: “When I recently polled members of my online developer communities about how they use Kotlin, one common theme became clear: Kotlin is mostly replacing Java. This is not surprising given that this was one of our main focuses while designing the language. Other than Gradle scripts, most people seem to treat Kotlin as a better Java.”

Mike gives some examples such as null ability analysis tools based on the Nullness Checker (I wrote an article about this ), Mocking/Simulating objects with Mockito, Unit testing support via Spek or Spock, and lambda syntax enabling easy parallelization.

Mike continues by pointing out that some people think it’s a replacement for Scala, but he believes they are two very different languages catering to two distinct audiences: “Scala is heavily focused on functional programming and targets mainly the kinds of developers who write compilers for a living. You can consult with the RemoteDBA administrators.Kotlin has a lot more in common with Java than with Scala.” He also notes that there’s no need to rewrite existing code as both languages interoperate smoothly.

Kotlin is very popular in the Android ecosystem, but companies from other domains have been using Kotlin too: “In January 2018 we started seeing around 20% of pull requests submitted to the most popular open-source projects written in Kotlin coming from outside mobile development” e.g. tools like Gradle, static code analysis and linters.

Mike says: “We expect this trend to continue.” and he lists several reasons why:

Kotlin is a general-purpose language that has been designed from the ground up with tooling support in mind. This makes it appealing for writing all kinds of applications, but especially those that can benefit from having great tooling e.g. IDE support right out of the box (and not just an add-on). Since Kotlin focuses on interoperability, we don’t have to cast everything as Any or do type conversions at runtime — we can take advantage of generics and extension functions instead. The same things apply when working with collections: since Kotlin treats them as any other data type, we can easily iterate through them without any additional overhead. This is why you’ll feel right at home when writing Kotlin code in IntelliJ IDEA! It’s also worth noting that many of the tooling features such as automatic refactorings and intentions are language agnostic — they work equally well for Java and Kotlin since both languages have been designed to interoperate relatively seamlessly.

Conclusion:

As far as I’ve seen so far, the future looks bright for Kotlin. Companies from different industries are picking up on it at an increasingly faster rate and seeing results quickly.

Lisa James

https://magazinebee.com/

Lisa is a 24-year old, passionate writer, and a keen observer. She loves fashion and is always looking for new trends and styles. Not just that, but she’s also the boss lady who is always hustling and trying to get everything done perfectly!

Related post