KT-10460: use unsubstituted descriptors

while comparing overloaded generic functions  for specificity.
This commit is contained in:
Dmitry Petrov
2016-01-14 19:02:56 +03:00
parent d21ce08548
commit a073f29006
14 changed files with 111 additions and 26 deletions
@@ -17,8 +17,8 @@ val y2: B<Int> = B("")
val y3: B<Int> = B<Int>(1)
val y4: B<Int> = B<Int>("")
val y5: B<String> = <!NONE_APPLICABLE!>B<!><String>(1)
val y6: B<String> = <!OVERLOAD_RESOLUTION_AMBIGUITY!>B<!><String>("") // TODO: doesn't work here but ok on y8
val y5: B<String> = B<String>(<!CONSTANT_EXPECTED_TYPE_MISMATCH!>1<!>)
val y6: B<String> = B<String>("")
val y7: B<String> = <!TYPE_INFERENCE_EXPECTED_TYPE_MISMATCH!>B(1)<!>
val y8: B<String> = B("")
@@ -6,9 +6,9 @@ class A0<T1, T2> {
constructor(x: T1, y: T2, z: T2): this(x, 1) // ok, delegates to constructor(x: T1, y: Int)
constructor(x: T1, y: Int): <!NONE_APPLICABLE!>this<!>(x, "")
constructor(x: T1, y: Int): this(x, <!TYPE_MISMATCH!>""<!>)
constructor(x: T1): this(x, 1)
constructor(x: T1, y: T2, z: String): <!NONE_APPLICABLE!>this<!>(y, x)
constructor(x: T1, y: T2, z: String): this(<!TYPE_MISMATCH!>y<!>, <!TYPE_MISMATCH!>x<!>)
}
class A1<T1, T2> : B<T1, T2> {