mirror of
https://gitflic.ru/project/openide/openide.git
synced 2026-01-03 15:50:52 +07:00
24 lines
443 B
Java
24 lines
443 B
Java
import java.util.function.BinaryOperator;
|
|
|
|
class Test {
|
|
static class Base<T> {
|
|
Child<T> prepend(Child<T> other) {
|
|
return null;
|
|
}
|
|
}
|
|
|
|
static class Child<T> extends Base<T> {
|
|
@SafeVarargs
|
|
final Child<T> prepend(T... args) {
|
|
return this;
|
|
}
|
|
|
|
Child<T> prepend(T arg) {
|
|
return this;
|
|
}
|
|
}
|
|
|
|
public static void main(String[] args) {
|
|
BinaryOperator<Child<String>> prepend = Child::prepend;
|
|
}
|
|
} |