Logo Questions Linux Laravel Mysql Ubuntu Git Menu
 

How can I change the Kotlin compiler version on IntelliJ?

In IntelliJ you can set the target Java version like this:

enter image description here

Unfortunately I don't see a place where I can do the same for Kotlin. This makes it not possible for me to use Quasar-Kotlin. I want to switch to M14 even though I have 1.0 beta installed. How can I change back?

After changing the build.gradle file back to M14 I am greeted with compilation errors in my project.

enter image description here

My build.gradle: https://gist.github.com/Jire/5b517fd767ad498bc18f

like image 471
Jire Avatar asked Oct 22 '15 17:10

Jire


People also ask

How do I change the compiler in IntelliJ?

Press Ctrl+Alt+S to open the IDE settings and select Build, Execution, Deployment| Compiler. On the Compiler page, configure settings that are related to any compilation and build process. For example, you can set the automatic compilation for your project.


2 Answers

Go to Intellij Preferences -> Build, Execution, Deployment -> Kotlin Compiler. Update Language version and Api version to the one you wish.

(You can also use cmd + shift + A and type Kotlin Compiler to get to this preference)

enter image description here

like image 59
Defuera Avatar answered Sep 23 '22 06:09

Defuera


You can't do this at the moment. Building your project in IntelliJ IDEA always uses the version of the Kotlin compiler bundled with the plugin, regardless of what your build.gradle file says. If you need to downgrade to M14, you need to install the M14 version of the plugin.

like image 34
yole Avatar answered Sep 23 '22 06:09

yole