[FE] Support reporting INFERRED_TYPE_VARIABLE_INTO_EMPTY_INTERSECTION for empty intersection types with type parameters

This commit is contained in:
Victor Petukhov
2022-02-11 14:20:28 +03:00
committed by teamcity
parent c16ae81a48
commit b96708c3e2
26 changed files with 307 additions and 19 deletions
@@ -1,12 +1,12 @@
/selectFromCovariantAndContravariantTypes.kt:12:22: warning: parameter 'y' is never used
/selectFromCovariantAndContravariantTypes.kt:11:22: warning: parameter 'y' is never used
fun <K> select(x: K, y: K): K = x
^
/selectFromCovariantAndContravariantTypes.kt:13:19: warning: parameter 'x' is never used
/selectFromCovariantAndContravariantTypes.kt:12:19: warning: parameter 'x' is never used
fun <V> genericIn(x: In<V>) {}
^
/selectFromCovariantAndContravariantTypes.kt:14:20: warning: parameter 'x' is never used
/selectFromCovariantAndContravariantTypes.kt:13:20: warning: parameter 'x' is never used
fun <V> genericOut(x: Out<V>) {}
^
/selectFromCovariantAndContravariantTypes.kt:17:5: warning: type argument for a type parameter V can't be inferred because it's upper bounded by incompatible types: A, B. This will become an error in Kotlin 1.8
/selectFromCovariantAndContravariantTypes.kt:16:5: warning: type argument for a type parameter V can't be inferred because it's upper bounded by incompatible types: A, B. This will become an error in Kotlin 1.8
genericIn(select(a, b))
^