Files
kotlin-fork/compiler/testData/diagnostics/tests/regressions/kt36222.kt
T

11 lines
232 B
Kotlin
Vendored

// FIR_IDENTICAL
// !DIAGNOSTICS: -UNUSED_PARAMETER
fun foo(f: () -> String) {}
fun <K> select(x: K, y: K): K = x
fun test() {
foo { <!TYPE_MISMATCH!>select("non-null", null)<!> } // inferred String? but String is expected
}