Don't fix a type variable into the intersection type if there is an explicit expected type

^KT-43303 Fixed
^KT-42396 Fixed
^KT-42472 Fixed
This commit is contained in:
Victor Petukhov
2021-03-03 16:02:10 +03:00
parent e06bacafad
commit 7f7bb70596
18 changed files with 220 additions and 6 deletions
@@ -8,5 +8,5 @@ fun test1(l: List<Number>) {
val i: Int = l.firstTyped()
val s: String = l.<!TYPE_INFERENCE_EXPECTED_TYPE_MISMATCH{OI}!>firstTyped()<!>
val s: String = <!TYPE_MISMATCH!>l.<!TYPE_INFERENCE_EXPECTED_TYPE_MISMATCH{OI}!><!TYPE_MISMATCH!>firstTyped<!>()<!><!>
}