Skip to content

Commit

Permalink
Bump version to 0.3.0
Browse files Browse the repository at this point in the history
  • Loading branch information
Gregory Lureau committed Feb 15, 2022
1 parent 31545dd commit 4adda31
Show file tree
Hide file tree
Showing 2 changed files with 1 addition and 24 deletions.
2 changes: 1 addition & 1 deletion build.gradle.kts
Original file line number Diff line number Diff line change
Expand Up @@ -28,7 +28,7 @@ plugins {

allprojects {
group = "deezer.kustomexport"
version = "0.2.0"
version = "0.3.0"

repositories {
mavenLocal()
Expand Down
23 changes: 0 additions & 23 deletions samples/src/commonMain/kotlin/sample/coroutines/Coroutines.kt
Original file line number Diff line number Diff line change
Expand Up @@ -18,16 +18,11 @@
package sample.coroutines

import deezer.kustomexport.KustomExport
import kotlinx.coroutines.CoroutineScope
import kotlinx.coroutines.Dispatchers
import kotlinx.coroutines.SupervisorJob
import kotlinx.coroutines.async
import kotlinx.coroutines.delay
import kotlinx.coroutines.job
import kotlinx.coroutines.launch
import kotlinx.coroutines.withContext
import kotlinx.coroutines.withTimeout
import kotlin.coroutines.coroutineContext

@KustomExport
interface IComputer {
Expand Down Expand Up @@ -62,22 +57,4 @@ class ComputerTester(private val computer: IComputer) {
}
}
}

suspend fun startCancellable(): Cancellable {
val coroutineScope = CoroutineScope(Dispatchers.Unconfined + SupervisorJob())
val job = coroutineScope.launch {
computer.longCompute()
}

return object : Cancellable {
override fun cancel() {
job.cancel()
}
}
}
}

@KustomExport
interface Cancellable {
fun cancel()
}

0 comments on commit 4adda31

Please sign in to comment.