Solution for KT-7838: now data flow information at the end of when expression is determined correctly.

#KT-7838  Fixed.
This commit is contained in:
Mikhail Glukhikh
2015-05-26 17:37:53 +03:00
parent 9e69b74a15
commit 4fb331ecd3
10 changed files with 142 additions and 0 deletions
@@ -0,0 +1,11 @@
class A
fun test(a: Any) {
var q: String? = null
when (a) {
is A -> q = "1"
}
// When is not exhaustive
return <!TYPE_MISMATCH!>q<!>
}