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

10 lines
191 B
Kotlin
Vendored

// !LANGUAGE: +SoundSmartCastsAfterTry
fun foo() {
var s: String?
s = "Test"
try {
s = null
} catch (ex: Exception) {}
s.<!INAPPLICABLE_CANDIDATE!>hashCode<!>()
}