Files
kotlin-fork/compiler/fir/analysis-tests/testData/resolve/smartcasts/variables/delayedAssignment.kt
T
2021-01-29 16:55:26 +03:00

16 lines
193 B
Kotlin
Vendored

// !DUMP_CFG
class A {
fun foo() {}
}
fun test(b: Boolean) {
val a: A?
if (b) {
a = A()
a.foo()
} else {
a = null
}
a<!UNSAFE_CALL!>.<!>foo()
}