mirror of
https://gitflic.ru/project/openide/openide.git
synced 2025-12-22 23:20:57 +07:00
25 lines
483 B
Java
25 lines
483 B
Java
class Collection<T> {}
|
|
|
|
interface Bar {}
|
|
|
|
class BarImpl implements Bar {}
|
|
|
|
interface Foo<E extends Bar> {
|
|
Collection<E> getElements();
|
|
}
|
|
|
|
class FooImpl implements Foo<BarImpl> {
|
|
public Collection<BarImpl> getElements() {
|
|
return null;
|
|
}
|
|
}
|
|
|
|
public class Bazz {
|
|
public static <E extends Bar> Collection<E> getElements(Collection<? extends Foo<E>> foos) {
|
|
return null;
|
|
}
|
|
|
|
public static void failure(final Collection<FooImpl> foos) {
|
|
<caret>getElements(foos);
|
|
}
|
|
} |