mirror of
https://gitflic.ru/project/openide/openide.git
synced 2025-12-22 14:50:53 +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;
|
|
}
|
|
} |