Fix incorrect handling of @NotNull type parameters

^KT-36770 In progress
^KT-40114 Relates
^KT-28785 Relates
This commit is contained in:
Denis Zharkov
2020-07-07 18:27:09 +03:00
parent f1c68a9080
commit 037ff2fa52
21 changed files with 311 additions and 30 deletions
@@ -22,5 +22,5 @@ interface TypePredicate : (KotlinType) -> Boolean {
fun <T : Any?> TypePredicate.expectedTypeFor(keys: Iterable<T>): Map<T, TypePredicate> =
keys.fold(SmartFMap.emptyMap<T, TypePredicate>()) { map, key ->
map.plus(key, this)
map.plus(<!NULLABLE_TYPE_PARAMETER_AGAINST_NOT_NULL_TYPE_PARAMETER!>key<!>, this)
}