new inference: don't push resolved vars in case of failed substitution

This commit is contained in:
Anna Kozlova
2015-11-24 10:30:21 +01:00
parent 138bd5a034
commit 49dfdded70
25 changed files with 240 additions and 240 deletions
@@ -2,7 +2,7 @@
class B<T>{}
class A<T extends B<? extends Runnable>> {
void bar(A<? extends B<? extends Cloneable>> a){
<error descr="Inferred type 'B<? extends java.lang.Cloneable>' for type parameter 'T' is not within its bound; should extend 'B<java.lang.Object>'">foo(a)</error>;
foo<error descr="'foo(A<? extends T>)' in 'A' cannot be applied to '(A<capture<? extends B<? extends java.lang.Cloneable>>>)'">(a)</error>;
}
<S, T extends B<S>> void foo(A<? extends T> a){}