mirror of
https://gitflic.ru/project/openide/openide.git
synced 2026-01-06 03:21:12 +07:00
diamond: replace wildcards with corresponding bound when inference (IDEA-66124)
This commit is contained in:
@@ -74,3 +74,24 @@ class NonParameterized {
|
||||
new NonParameterized<<error descr="Diamond operator is not applicable for non-parameterized types"></error>>();
|
||||
}
|
||||
}
|
||||
|
||||
|
||||
interface I<T> {
|
||||
T m();
|
||||
}
|
||||
|
||||
class FI1 {
|
||||
I<? extends String> i1 = new I<>() {
|
||||
@Override
|
||||
public String m() {
|
||||
return null;
|
||||
}
|
||||
};
|
||||
|
||||
I<?> i2 = new I<>() {
|
||||
@Override
|
||||
public Object m() {
|
||||
return null;
|
||||
}
|
||||
};
|
||||
}
|
||||
Reference in New Issue
Block a user