Skip to content

Commit

Permalink
Update Kotlin to 2.1.0-dev-2499
Browse files Browse the repository at this point in the history
With [1], the CONTEXT_RECEIVERS_DEPRECATED warning can now be suppressed
via a single CLI flag instead of an annotation in every file.

[1] https://youtrack.jetbrains.com/issue/KT-8087
  • Loading branch information
lukellmann committed Jul 26, 2024
1 parent ecb1d40 commit ee94ad3
Show file tree
Hide file tree
Showing 14 changed files with 5 additions and 26 deletions.
2 changes: 1 addition & 1 deletion gradle/libs.versions.toml
Original file line number Diff line number Diff line change
@@ -1,7 +1,7 @@
[versions]

# api dependencies
kotlin = "2.1.0-dev-1329" # https://github.com/JetBrains/kotlin
kotlin = "2.1.0-dev-2499" # https://github.com/JetBrains/kotlin
ktor = "2.3.12" # https://github.com/ktorio/ktor
kotlinx-coroutines = "1.8.1" # https://github.com/Kotlin/kotlinx.coroutines
kotlinx-serialization = "1.7.1" # https://github.com/Kotlin/kotlinx.serialization
Expand Down
5 changes: 4 additions & 1 deletion ksp-processors/build.gradle.kts
Original file line number Diff line number Diff line change
Expand Up @@ -4,7 +4,10 @@ plugins {

kotlin {
compilerOptions {
freeCompilerArgs.add("-Xcontext-receivers")
freeCompilerArgs.addAll(
"-Xcontext-receivers",
"-Xsuppress-warning=CONTEXT_RECEIVERS_DEPRECATED",
)
}
}

Expand Down
Original file line number Diff line number Diff line change
@@ -1,5 +1,3 @@
@file:Suppress("CONTEXT_RECEIVERS_DEPRECATED")

package dev.kord.ksp.generation.bitflags

import com.google.devtools.ksp.symbol.KSFile
Expand Down
2 changes: 0 additions & 2 deletions ksp-processors/src/main/kotlin/generation/bitflags/Builder.kt
Original file line number Diff line number Diff line change
@@ -1,5 +1,3 @@
@file:Suppress("CONTEXT_RECEIVERS_DEPRECATED")

package dev.kord.ksp.generation.bitflags

import com.squareup.kotlinpoet.ClassName
Expand Down
Original file line number Diff line number Diff line change
@@ -1,5 +1,3 @@
@file:Suppress("CONTEXT_RECEIVERS_DEPRECATED")

package dev.kord.ksp.generation.bitflags

import com.squareup.kotlinpoet.*
Expand Down
Original file line number Diff line number Diff line change
@@ -1,5 +1,3 @@
@file:Suppress("CONTEXT_RECEIVERS_DEPRECATED")

package dev.kord.ksp.generation.bitflags

import com.squareup.kotlinpoet.DelicateKotlinPoetApi
Expand Down
Original file line number Diff line number Diff line change
@@ -1,5 +1,3 @@
@file:Suppress("CONTEXT_RECEIVERS_DEPRECATED")

package dev.kord.ksp.generation.bitflags

import com.squareup.kotlinpoet.CodeBlock
Expand Down
Original file line number Diff line number Diff line change
@@ -1,5 +1,3 @@
@file:Suppress("CONTEXT_RECEIVERS_DEPRECATED")

package dev.kord.ksp.generation.bitflags

import com.squareup.kotlinpoet.*
Expand Down
Original file line number Diff line number Diff line change
@@ -1,5 +1,3 @@
@file:Suppress("CONTEXT_RECEIVERS_DEPRECATED")

package dev.kord.ksp.generation.bitflags

import com.squareup.kotlinpoet.KModifier.OVERRIDE
Expand Down
Original file line number Diff line number Diff line change
@@ -1,5 +1,3 @@
@file:Suppress("CONTEXT_RECEIVERS_DEPRECATED")

package dev.kord.ksp.generation.kordenum

import com.squareup.kotlinpoet.KModifier.OVERRIDE
Expand Down
Original file line number Diff line number Diff line change
@@ -1,5 +1,3 @@
@file:Suppress("CONTEXT_RECEIVERS_DEPRECATED")

package dev.kord.ksp.generation.shared

import com.squareup.kotlinpoet.ClassName
Expand Down
Original file line number Diff line number Diff line change
@@ -1,5 +1,3 @@
@file:Suppress("CONTEXT_RECEIVERS_DEPRECATED")

package dev.kord.ksp.generation.shared

import com.google.devtools.ksp.symbol.KSFile
Expand Down
2 changes: 0 additions & 2 deletions ksp-processors/src/main/kotlin/generation/shared/OptIns.kt
Original file line number Diff line number Diff line change
@@ -1,5 +1,3 @@
@file:Suppress("CONTEXT_RECEIVERS_DEPRECATED")

package dev.kord.ksp.generation.shared

import com.squareup.kotlinpoet.Annotatable
Expand Down
Original file line number Diff line number Diff line change
@@ -1,5 +1,3 @@
@file:Suppress("CONTEXT_RECEIVERS_DEPRECATED")

package dev.kord.ksp.generation.shared

import com.squareup.kotlinpoet.*
Expand Down

0 comments on commit ee94ad3

Please sign in to comment.