Files
Denis Zharkov 944b0d058a Allow calling some pieces of the experimental coroutine API
- Calling suspend functions is allowed
- Presence of suspend function type still makes declaration
unusable unless it belongs to a value parameter as a top-level type
containing less then three parameters

Still, warning should be emitted because they will become unsupported in 1.4

 #KT-25683 In Progress
2018-08-21 13:44:02 +03:00

12 lines
299 B
Kotlin
Vendored

suspend fun callRelease() {
WithTypeParameter<suspend () -> Unit>()
returnsSuspend()
withTypeParameter<suspend () -> Unit>()
suspendFunctionNested(listOf(suspend { }))
suspendFunctionNestedInFunctionType {}
suspendFunctionType3 { x, y, z -> }
suspendVarargs({}, {})
}