0857b9c9e7
Namely, remove incorporation “otherInsideMyConstraint” to eliminate constraint system redundancy and produce a potentially very large number of constructs. Instead, introduce not so “spreadable” incorporation during variable fixation (equality constraint with result type into other constraints). ^KT-41644 Fixed ^KT-42195 Fixed ^KT-42920 Fixed ^KT-42791 Fixed ^KT-41741 Fixed
14 lines
318 B
Kotlin
Vendored
14 lines
318 B
Kotlin
Vendored
// !DIAGNOSTICS: -CAST_NEVER_SUCCEEDS
|
|
|
|
interface I
|
|
|
|
interface Inv<P>
|
|
interface Out<out T>
|
|
|
|
class Bar<U : I>(val x: Inv<Out<U>>)
|
|
|
|
fun <T> materializeFoo(): Inv<T> = null as Inv<T>
|
|
|
|
fun main() {
|
|
<!NEW_INFERENCE_NO_INFORMATION_FOR_PARAMETER!>Bar<!>(<!NEW_INFERENCE_NO_INFORMATION_FOR_PARAMETER!>materializeFoo<!>())
|
|
} |