Colton Idle
10/09/2025, 1:07 AMandroid {
compileOptions {
sourceCompatibility = JavaVersion.VERSION_17
targetCompatibility = JavaVersion.VERSION_17
}
kotlinOptions {
jvmTarget = "17"
}
}Jack Boswell
10/09/2025, 1:08 AMJack Boswell
10/09/2025, 1:09 AMJack Boswell
10/09/2025, 1:09 AMColton Idle
10/09/2025, 1:11 AMJack Boswell
10/09/2025, 1:12 AMJack Boswell
10/09/2025, 1:12 AMjvmToolchain and call it a day. If you're not using that, then you only have those 3 to seteygraber
10/09/2025, 1:59 AMColton Idle
10/09/2025, 2:20 AMcompileOptions {
sourceCompatibility = JavaVersion.VERSION_11
targetCompatibility = JavaVersion.VERSION_11
}
and
tasks.withType<KotlinCompile>().configureEach {
compilerOptions {jvmTarget.set(JvmTarget.JVM_11)}
}
and that just looks smelly hence the question. let me look into jvmToolchainJack Boswell
10/09/2025, 2:48 AMJack Boswell
10/09/2025, 2:48 AMColton Idle
10/09/2025, 2:55 AMephemient
10/09/2025, 4:17 AMephemient
10/09/2025, 4:18 AMColton Idle
10/09/2025, 4:52 AMJack Boswell
10/09/2025, 6:00 AMthere's no reason to use newer targets on androidNot true. You definitely don't get newer language features until Android as a platform adds them, but you do benefit from compile-time performance improvements
Jack Boswell
10/09/2025, 6:00 AMephemient
10/09/2025, 2:41 PMColton Idle
10/09/2025, 5:14 PMtasks.withType<KotlinCompile>().configureEach {
compilerOptions { jvmTarget.set(JvmTarget.JVM_[insert version]) }
}
seems like i should just do
android {
compileOptions {
sourceCompatibility = JavaVersion.VERSION_[insert version]
targetCompatibility = JavaVersion.VERSION_[[insert version]
}
kotlinOptions {
jvmTarget = "[insert version]"
}
}