mirror of
https://gitflic.ru/project/openide/openide.git
synced 2026-01-07 22:09:38 +07:00
new inference: missed condition in conditional expression (IDEA-127752)
This commit is contained in:
@@ -0,0 +1,14 @@
|
||||
class Test {
|
||||
static class TKey<T> {
|
||||
}
|
||||
|
||||
public interface Getter {
|
||||
<T> T getValue(TKey<T> key);
|
||||
}
|
||||
|
||||
static final TKey<Boolean> KEY_B = new TKey<>();
|
||||
|
||||
public static void f(Getter getter) {
|
||||
String name = getter.getValue(KEY_B) ? "foo" : "bar";
|
||||
}
|
||||
}
|
||||
Reference in New Issue
Block a user