Maurizio Cimadamore d951098c65 7154127: Inference cleanup: remove bound check analysis from visitors in Types.java
Remove bound checking rules from recursive subtype visitors in Types.java and replace with centralized bound-checking logic

Reviewed-by: jjg, dlsmith
2012-04-11 10:50:11 +01:00

22 lines
521 B
Java

/**
* @test /nodynamiccopyright/
* @bug 7154127
* @summary Inference cleanup: remove bound check analysis from visitors in Types.java
* @compile/fail/ref=T7154127.out -XDrawDiagnostics T7154127.java
*/
class T7154127 {
static class B<V> {}
static class D extends B<E> {}
static class E extends B<D> {}
static class Triple<U,V,W> { }
static <T, Y extends B<U>, U extends B<Y>> Triple<T, Y, U> m() { return null; }
void test() {
Triple<B, ? extends D, ? extends E> t = m();
}
}