Files
kotlin-fork/compiler/testData/diagnostics/tests/dataFlowInfoTraversal/Throw.kt
T
2019-02-14 12:31:42 +03:00

9 lines
289 B
Kotlin
Vendored

fun bar(x: Int): RuntimeException = RuntimeException(x.toString())
fun foo() {
val x: Int? = null
if (x == null) throw bar(<!DEBUG_INFO_CONSTANT, TYPE_MISMATCH!>x<!>)
throw bar(<!DEBUG_INFO_SMARTCAST!>x<!>)
<!UNREACHABLE_CODE!>throw bar(<!DEBUG_INFO_SMARTCAST!>x<!>)<!>
}