Files
kotlin-fork/compiler/testData/diagnostics/tests/smartCasts/varnotnull/initialization.fir.kt
T
Dmitriy Novozhilov 6735cc8937 [FIR] Implement new bound smartcast algorithm
#KT-36055 Fixed
2020-02-12 10:17:45 +03:00

8 lines
222 B
Kotlin
Vendored

// !WITH_NEW_INFERENCE
fun foo() {
var v: String? = "xyz"
// It is possible in principle to provide smart cast here
v.<!INAPPLICABLE_CANDIDATE!>length<!>
v = null
v.<!INAPPLICABLE_CANDIDATE!>length<!>
}