Maurizio Cimadamore 4ff56b008f 8169091: Method reference T::methodName for generic type T does not compile any more
MethodReferenceLookupHelper should use original site to perform unbound subtype check

Reviewed-by: vromero
2017-01-03 11:33:18 +00:00

16 lines
368 B
Java

/*
* @test
* @bug 8169091
* @summary Method reference T::methodName for generic type T does not compile any more
* @compile T8169091.java
*/
import java.io.Serializable;
import java.util.Comparator;
interface T8169091 {
static <T extends Comparable<? super T>> Comparator<T> comparator() {
return (Comparator<T> & Serializable)T::compareTo;
}
}