Files
kotlin-fork/compiler/testData/diagnostics/tests/controlFlowAnalysis/deadCode/deadCodeInIf.fir.kt
T
Andrey Zinovyev ec4cbfef59 [FIR] UNREACHABLE_CODE diagnostic (wip)
Implementation for PSI only
2021-08-04 14:42:24 +03:00

12 lines
206 B
Kotlin
Vendored

fun testIf() {
if (todo()) <!UNREACHABLE_CODE!>1<!> else <!UNREACHABLE_CODE!>2<!>
}
fun testIf1(b: Boolean) {
if (b) todo() else 1
bar()
}
fun todo(): Nothing = throw Exception()
fun bar() {}