groostav
06/16/2017, 7:44 AMlog("start")
delay(30_000)
log("point 1!")
doLongRunningJobForCompletableFuture().await()
log("point 2")
callOtherRunningSuspendFunction()
log("done!")
the compiler will actually generate code akin to
log("start")
uiThread.scheduleAfter(30_000){
log("point 1!")
doLongRunningJobForCompletableFuture().addListener { ex, result ->
log("point 2!")
callOtherRunningSuspendFunction().onResume { result -> {
log("done!")
}
}
}