Skip to content

Commit

Permalink
Kotlin 2.0
Browse files Browse the repository at this point in the history
  • Loading branch information
whyoleg committed May 21, 2024
1 parent 5f4ad2f commit 4cc3432
Show file tree
Hide file tree
Showing 3 changed files with 11 additions and 7 deletions.
1 change: 1 addition & 0 deletions .gitignore
Original file line number Diff line number Diff line change
Expand Up @@ -6,6 +6,7 @@ syntax: glob
!/.idea/codeStyles
*.iml

.kotlin
.gradle
classes
build/
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -32,16 +32,21 @@ plugins {
@OptIn(ExperimentalKotlinGradlePluginApi::class)
kotlin {
compilerOptions {
// because of https://youtrack.jetbrains.com/issue/KT-64115/KGP-JVM-JS-WASM-The-same-library-can-be-passed-twice-to-the-compiler
// allWarningsAsErrors.set(true)
// because of INVISIBLE_REFERENCE suppression - will be removed after migration to kotlinx.io
if (project.name != "rsocket-test") {
allWarningsAsErrors.set(true)
}
progressiveMode.set(true)
freeCompilerArgs.add("-Xrender-internal-diagnostic-names")
}

sourceSets.configureEach {
languageSettings {
if (name.contains("test", ignoreCase = true)) {
// for hex API
optIn(OptIns.ExperimentalStdlibApi)
// for channel.isClosedForSend - need to be replaced by testing via turbine or optIn in place
// and GlobalScope - need to be dropped
optIn(OptIns.DelicateCoroutinesApi)

// rsocket related
Expand All @@ -54,10 +59,8 @@ kotlin {
}

targets.withType<KotlinJvmTarget>().configureEach {
compilations.configureEach {
compilerOptions.configure {
freeCompilerArgs.add("-Xjvm-default=all")
}
compilerOptions {
freeCompilerArgs.add("-Xjvm-default=all")
}
}

Expand Down
2 changes: 1 addition & 1 deletion gradle/libs.versions.toml
Original file line number Diff line number Diff line change
@@ -1,5 +1,5 @@
[versions]
kotlin = "1.9.24"
kotlin = "2.0.0"

kotlinx-atomicfu = "0.24.0"
kotlinx-coroutines = "1.8.1"
Expand Down

0 comments on commit 4cc3432

Please sign in to comment.