substitute upper bounds after creating all substitutions for type parameters
(otherwise it doesn't work for forward references)
This commit is contained in:
+1
-1
@@ -4,7 +4,7 @@ fun foo<V : U, U>(<!UNUSED_PARAMETER!>v<!>: V, u: U) = u
|
||||
fun bar<U, V : U>(<!UNUSED_PARAMETER!>v<!>: V, u: U) = u
|
||||
|
||||
fun test(a: Any, s: String) {
|
||||
val <!UNUSED_VARIABLE!>b<!>: Any = <!TYPE_INFERENCE_UPPER_BOUND_VIOLATED!>foo<!>(a, s) //depends on type parameter order, will be fixed in next commit
|
||||
val <!UNUSED_VARIABLE!>b<!>: Any = foo(a, s)
|
||||
val <!UNUSED_VARIABLE!>c<!>: Any = bar(a, s)
|
||||
}
|
||||
|
||||
|
||||
Reference in New Issue
Block a user