mirror of
https://gitflic.ru/project/openide/openide.git
synced 2026-11-13 00:33:59 +07:00
new inference: strict subtyping: skip raw types
This commit is contained in:
1 parent
828cb5a1a2
commit
232f8bd465
3 files changed
+23
No files matched your search
+15
@@ -0,0 +1,15 @@
|
||||
import java.util.Map;
|
||||
import java.util.TreeMap;
|
||||
import java.util.function.Supplier;
|
||||
|
||||
class Test {
|
||||
interface I<K> {}
|
||||
|
||||
{
|
||||
I i = foo(TreeMap::new);
|
||||
}
|
||||
|
||||
<M extends Map<Integer, Integer>> I<M> foo(Supplier<M> mapFactory) {
|
||||
return null;
|
||||
}
|
||||
}
|
||||
Reference in new issue
Block a user