From 89282734a8b4e0a2b33808d96616710afa00f3ac Mon Sep 17 00:00:00 2001 From: Vsevolod Tolstopyatov Date: Mon, 27 Nov 2023 11:39:22 +0100 Subject: [PATCH 1/3] Update Kotlin to 1.9.21 --- README.md | 10 +++++----- gradle.properties | 2 +- integration-testing/gradle.properties | 2 +- 3 files changed, 7 insertions(+), 7 deletions(-) diff --git a/README.md b/README.md index 25df7aa8b5..90ec53e80b 100644 --- a/README.md +++ b/README.md @@ -4,11 +4,11 @@ [![JetBrains official project](https://jb.gg/badges/official.svg)](https://confluence.jetbrains.com/display/ALL/JetBrains+on+GitHub) [![GitHub license](https://img.shields.io/badge/license-Apache%20License%202.0-blue.svg?style=flat)](https://www.apache.org/licenses/LICENSE-2.0) [![Download](https://img.shields.io/maven-central/v/org.jetbrains.kotlinx/kotlinx-coroutines-core/1.7.2)](https://central.sonatype.com/artifact/org.jetbrains.kotlinx/kotlinx-coroutines-core/1.7.2) -[![Kotlin](https://img.shields.io/badge/kotlin-1.9.20-blue.svg?logo=kotlin)](http://kotlinlang.org) +[![Kotlin](https://img.shields.io/badge/kotlin-1.9.21-blue.svg?logo=kotlin)](http://kotlinlang.org) [![Slack channel](https://img.shields.io/badge/chat-slack-green.svg?logo=slack)](https://kotlinlang.slack.com/messages/coroutines/) Library support for Kotlin coroutines with [multiplatform](#multiplatform) support. -This is a companion version for the Kotlin `1.9.20` release. +This is a companion version for the Kotlin `1.9.21` release. ```kotlin suspend fun main() = coroutineScope { @@ -93,7 +93,7 @@ And make sure that you use the latest Kotlin version: ```xml - 1.9.20 + 1.9.21 ``` @@ -112,10 +112,10 @@ And make sure that you use the latest Kotlin version: ```kotlin plugins { // For build.gradle.kts (Kotlin DSL) - kotlin("jvm") version "1.9.20" + kotlin("jvm") version "1.9.21" // For build.gradle (Groovy DSL) - id "org.jetbrains.kotlin.jvm" version "1.9.20" + id "org.jetbrains.kotlin.jvm" version "1.9.21" } ``` diff --git a/gradle.properties b/gradle.properties index c8d0c19696..906fc4ecc7 100644 --- a/gradle.properties +++ b/gradle.properties @@ -5,7 +5,7 @@ # Kotlin version=1.7.2-SNAPSHOT group=org.jetbrains.kotlinx -kotlin_version=1.9.20 +kotlin_version=1.9.21 # Dependencies junit_version=4.12 diff --git a/integration-testing/gradle.properties b/integration-testing/gradle.properties index b662e51e15..e8e17351cf 100644 --- a/integration-testing/gradle.properties +++ b/integration-testing/gradle.properties @@ -1,4 +1,4 @@ -kotlin_version=1.9.20 +kotlin_version=1.9.21 coroutines_version=1.7.2-SNAPSHOT asm_version=9.3 From 40ee1b9ec31fdc8cbbb2b988d01496eae49b74a1 Mon Sep 17 00:00:00 2001 From: Vsevolod Tolstopyatov Date: Mon, 27 Nov 2023 11:46:14 +0100 Subject: [PATCH 2/3] Update atomicfu to version released with 1.9.21 to address KT-62515 --- gradle.properties | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/gradle.properties b/gradle.properties index 906fc4ecc7..57f73d1494 100644 --- a/gradle.properties +++ b/gradle.properties @@ -10,7 +10,7 @@ kotlin_version=1.9.21 # Dependencies junit_version=4.12 junit5_version=5.7.0 -atomicfu_version=0.22.0 +atomicfu_version=0.23.1 knit_version=0.4.0 html_version=0.7.2 lincheck_version=2.18.1 From 4b003403e8b7a9b183403907b1686c78d493cc7f Mon Sep 17 00:00:00 2001 From: Vsevolod Tolstopyatov Date: Mon, 27 Nov 2023 12:45:50 +0100 Subject: [PATCH 3/3] Enable K/N atomicfu transformations --- gradle.properties | 1 + kotlinx-coroutines-core/native/test/TestBase.kt | 4 ++-- 2 files changed, 3 insertions(+), 2 deletions(-) diff --git a/gradle.properties b/gradle.properties index 57f73d1494..2d57149b5d 100644 --- a/gradle.properties +++ b/gradle.properties @@ -46,3 +46,4 @@ kotlinx.atomicfu.enableJvmIrTransformation=true # When the flag below is set to `true`, AtomicFU cannot process # usages of `moveForward` in `ConcurrentLinkedList.kt` correctly. kotlinx.atomicfu.enableJsIrTransformation=false +kotlinx.atomicfu.enableNativeIrTransformation=true diff --git a/kotlinx-coroutines-core/native/test/TestBase.kt b/kotlinx-coroutines-core/native/test/TestBase.kt index 173bcc30ae..c25f03569a 100644 --- a/kotlinx-coroutines-core/native/test/TestBase.kt +++ b/kotlinx-coroutines-core/native/test/TestBase.kt @@ -17,8 +17,8 @@ public actual typealias TestResult = Unit public actual open class TestBase actual constructor() { public actual val isBoundByJsTestTimeout = false - private var actionIndex = atomic(0) - private var finished = atomic(false) + private val actionIndex = atomic(0) + private val finished = atomic(false) private var error: Throwable? = null /**