mirror of
https://gitflic.ru/project/openide/openide.git
synced 2026-08-26 00:11:26 +07:00
new inference: resolve bounds which are not mentioned by additional constraints before starting algorithm
(cherry picked from commit f4c3b393d749a7ad27936014c932492643a277e4)
This commit is contained in:
+13
@@ -0,0 +1,13 @@
|
||||
import java.util.function.Function;
|
||||
|
||||
abstract class Test {
|
||||
abstract <T, A, R> Collector<T, A, R> create(Foo<A> foo, Function<A,R> fun);
|
||||
abstract <Ts> Foo<Ts[]> toArray(Ts identity);
|
||||
|
||||
<Tf> Collector<Tf, ?, Tf> foo(Tf t) {
|
||||
return create(toArray(t), a -> a[0]);
|
||||
}
|
||||
|
||||
interface Collector<T1, A1, R1> {}
|
||||
class Foo<D> {}
|
||||
}
|
||||
Reference in New Issue
Block a user