Skip to content

Commit c480f10

Browse files
committed
Add support for newer JDK versions
1 parent b85eee7 commit c480f10

File tree

3 files changed

+7
-4
lines changed

3 files changed

+7
-4
lines changed

README.md

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -102,7 +102,7 @@ load("@rules_kotlin//kotlin:core.bzl", "define_kt_toolchain")
102102
define_kt_toolchain(
103103
name = "kotlin_toolchain",
104104
api_version = KOTLIN_LANGUAGE_LEVEL, # "1.9", "2.0", "2.1", "2.2", or "2.3"
105-
jvm_target = JAVA_LANGUAGE_LEVEL, # "1.8", "9", "10", "11", "12", "13", "15", "16", "17", "18", "19", "20", "21", or "22"
105+
jvm_target = JAVA_LANGUAGE_LEVEL, # "1.8", "9", "10", "11", "12", "13", "14", "15", "16", "17", "18", "19", "20", "21", "22", "23", "24", or "25"
106106
language_version = KOTLIN_LANGUAGE_LEVEL, # "1.9", "2.0", "2.1", "2.2", or "2.3"
107107
)
108108
```

kotlin/internal/toolchains.bzl

Lines changed: 3 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -236,6 +236,9 @@ _kt_toolchain = rule(
236236
"19",
237237
"20",
238238
"21",
239+
"22",
240+
"23",
241+
"24",
239242
],
240243
),
241244
"kotlin_home": attr.label(

src/main/starlark/core/options/opts.kotlinc.bzl

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -100,7 +100,7 @@ Options:
100100
args = dict(
101101
default = "",
102102
doc = "The target version of the generated JVM bytecode",
103-
values = ["1.6", "1.8", "9", "10", "11", "12", "13", "15", "16", "17", "21"],
103+
values = ["1.6", "1.8", "9", "10", "11", "12", "13", "14", "15", "16", "17", "18", "19", "20", "21", "22", "23", "24", "25"],
104104
),
105105
type = attr.string,
106106
value_to_flag = None,
@@ -254,9 +254,9 @@ default: 'first-only-warn' in language version 2.2+, 'first-only' in version 2.1
254254
args = dict(
255255
default = "",
256256
doc = """Compile against the specified JDK API version, similarly to javac's '-release'. This requires JDK 9 or newer.
257-
The supported versions depend on the JDK used; for JDK 17+, the supported versions are 1.8 and 9-21.
257+
The supported versions depend on the JDK used; for JDK 25+, the supported versions are 1.8 and 9-25.
258258
This also sets the value of '-jvm-target' to be equal to the selected JDK version.""",
259-
values = ["1.6", "1.8", "9", "10", "11", "12", "13", "15", "16", "17", "21"],
259+
values = ["1.6", "1.8", "9", "10", "11", "12", "13", "14", "15", "16", "17", "18", "19", "20", "21", "22", "23", "24", "25"],
260260
),
261261
type = attr.string,
262262
value_to_flag = None,

0 commit comments

Comments
 (0)