Add regression tests

KT-32358
This commit is contained in:
Pavel Kirpichenkov
2020-01-15 11:25:26 +03:00
parent d36dd12f58
commit 3fcf3d6fea
12 changed files with 172 additions and 0 deletions
@@ -0,0 +1,17 @@
// !LANGUAGE: +NewInference
class MyChild {
val nullableString: String? = null
val notNull = ""
}
class MyParent {
val child: MyChild? = MyChild()
}
fun myFun() {
val myParent = MyParent()
myParent.child?.nullableString ?: run { return }
<!DEBUG_INFO_SMARTCAST!>myParent.child<!>.notNull // <- No smart cast in plugin
}