Files
kotlin-fork/compiler/testData/diagnostics/tests/controlStructures/ForbidStatementAsDirectFunctionBody.fir.kt
T
2020-02-10 10:54:04 +03:00

11 lines
212 B
Kotlin
Vendored

fun foo1() = while (b()) {}
fun foo2() = <!UNRESOLVED_REFERENCE, UNRESOLVED_REFERENCE, UNRESOLVED_REFERENCE!>for (i in 10) {}<!>
fun foo3() = when (b()) {
true -> 1
else -> 0
}
fun b(): Boolean = true