Files
kotlin-fork/compiler/fir/analysis-tests/testData/resolve/extendedCheckers/unused/invokeKSuspendFunction.kt
T
Roman Golyshev 2c90f1327d KT-61032 [FIR] Add testData for invoke on K*Function* local variables
N.B. Method references currently also implicitly have such type
2024-01-11 09:58:04 +00:00

8 lines
204 B
Kotlin
Vendored

// WITH_STDLIB
import kotlin.reflect.KSuspendFunction1
suspend fun foo(action: KSuspendFunction1<String, Int>): Int {
val <!UNUSED_VARIABLE!>localAction<!> = action
return localAction("hello")
}