Files
kotlin-fork/compiler/testData/diagnostics/tests/inference/kt28654.fir.kt
T
Denis.Zharkov 00821bbc63 FIR: Update test data (repeated diagnostics)
They are a bit redundant, but it needs additional work to be done
to avoid them
2021-05-20 17:24:33 +03:00

11 lines
220 B
Kotlin
Vendored

// !WITH_NEW_INFERENCE
// !DIAGNOSTICS: -UNUSED_VARIABLE
// Related issue: KT-28654
fun <K> select(): K = <!RETURN_TYPE_MISMATCH, TYPE_MISMATCH!>run { }<!>
fun test() {
val x: Int = select()
val t = select()
}