Files
kotlin-fork/compiler/testData/diagnostics/tests/smartCasts/varnotnull/setNullInTryFinally.kt
T
2021-01-29 16:55:26 +03:00

17 lines
249 B
Kotlin
Vendored

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