val commonMain by getting {
dependencies {
implementation("org.jetbrains.kotlinx:kotlinx-coroutines-core:1.6.1-native-mt")
}
}
val commonTest by getting {
dependencies {
implementation(kotlin("test"))
implementation(kotlin("test-common"))
implementation(kotlin("test-annotations-common"))
implementation("org.jetbrains.kotlinx:kotlinx-coroutines-test:1.6.1-native-mt")
}
}
g
Grégory Lureau
06/02/2022, 3:11 PM
Those are JVM methods, not accessible on other platforms afaik. EDIT: not sure about that anymore, "native" is visible here and here, so I may have run into the same issue 🤔
j
jean
06/02/2022, 3:31 PM
newSingleThreadContext
should be accessible since I can see
ThreadPoolDispatcher.kt
in my dependencies where
newSingleThreadContext
is declared. I don’t understand why the IDE complains
jean
06/02/2022, 3:42 PM
I created a new kotlin multiplatform project with the same dependencies and it does not complain about anything. I did try to invalidate the cache in the project failing but it didn’t help
jean
06/02/2022, 6:30 PM
I figured out I had other issues even though the compiler was not complaining about it. It seems to work now after fixing those problems