mirror of
https://gitflic.ru/project/openide/openide.git
synced 2026-08-26 00:11:26 +07:00
redundant cast: process instanceof (IDEA-128493)
This commit is contained in:
+13
@@ -0,0 +1,13 @@
|
||||
@SuppressWarnings({"UnusedDeclaration"})
|
||||
class C {
|
||||
boolean foo(final ConfigurableField<String> nameField) {
|
||||
return (Formatter<?>)nameField.getFormatter() instanceof DefaultFormatter;
|
||||
}
|
||||
}
|
||||
|
||||
@SuppressWarnings({"UnusedDeclaration"})
|
||||
interface Formatter<V>{}
|
||||
class DefaultFormatter implements Formatter<Object>{}
|
||||
interface ConfigurableField<V> {
|
||||
Formatter<V> getFormatter();
|
||||
}
|
||||
Reference in New Issue
Block a user