How can I stop IntelliJ IDEA from turning methods into properties when Kotlinizing a Java file?

Viewed 50

In IntelliJ IDEA I can right-click on a Java file and convert it to Kotlin.

It mostly goes well, but this irks me: When the method name starts with is, in Kotlin it comes out as a property instead of a function.

Is there a setting I can change to get Kotlin to convert these methods to functions like all the other methods?

1 Answers

As of Kotlin IDEA plugin 1.4.0, every getter-like method that starts with get or is is always converted into a Kotlin property. This behavior cannot be overridden.

The problem is described in the issue https://youtrack.jetbrains.com/issue/KT-36826, you can vote for it and discuss further on YouTrack.

Related