Introduce Parameter: Add suspend to lambdas with nested suspend-calls

#KT-24712 Fixed
This commit is contained in:
Alexey Sedunov
2018-06-01 21:12:48 +03:00
parent 8a838ab5bb
commit 0ea1784d33
4 changed files with 21 additions and 0 deletions
@@ -0,0 +1,6 @@
// WITH_DEFAULT_VALUE: false
suspend fun foo(n: Int) = n
suspend fun test() {
val m = <selection>foo(1)</selection>
}
@@ -0,0 +1,6 @@
// WITH_DEFAULT_VALUE: false
suspend fun foo(n: Int) = n
suspend fun test(i: suspend () -> Int) {
val m = i()
}