Raise the minimum supported version of Kotlin to 1.7

Closes gh-31391
pull/31400/head
Andy Wilkinson 2 years ago
parent aa71ba0fad
commit fabe0637cd

@ -30,7 +30,7 @@ import org.jetbrains.kotlin.gradle.tasks.KotlinCompile;
* <ul>
* <li>{@link KotlinCompile} tasks are configured to:
* <ul>
* <li>Use {@code apiVersion} and {@code languageVersion} 1.6.
* <li>Use {@code apiVersion} and {@code languageVersion} 1.7.
* <li>Use {@code jvmTarget} 17.
* <li>Treat all warnings as errors
* <li>Suppress version warnings
@ -50,8 +50,8 @@ class KotlinConventions {
private void configure(KotlinCompile compile) {
KotlinJvmOptions kotlinOptions = compile.getKotlinOptions();
kotlinOptions.setApiVersion("1.6");
kotlinOptions.setLanguageVersion("1.6");
kotlinOptions.setApiVersion("1.7");
kotlinOptions.setLanguageVersion("1.7");
kotlinOptions.setJvmTarget("17");
kotlinOptions.setAllWarningsAsErrors(true);
List<String> freeCompilerArgs = new ArrayList<>(compile.getKotlinOptions().getFreeCompilerArgs());

@ -13,7 +13,7 @@ Feel free to join the #spring channel of https://slack.kotlinlang.org/[Kotlin Sl
[[features.kotlin.requirements]]
=== Requirements
Spring Boot requires at least Kotlin 1.6.x and manages a suitable Kotlin version through dependency management.
Spring Boot requires at least Kotlin 1.7.x and manages a suitable Kotlin version through dependency management.
To use Kotlin, `org.jetbrains.kotlin:kotlin-stdlib` and `org.jetbrains.kotlin:kotlin-reflect` must be present on the classpath.
The `kotlin-stdlib` variants `kotlin-stdlib-jdk7` and `kotlin-stdlib-jdk8` can also be used.

Loading…
Cancel
Save