Details
-
Bug
-
Status: Open
-
Major
-
Resolution: Unresolved
-
12.0
-
None
-
None
Description
When a private static final field is only used as an annotation parameter, the editor marks it as "not used". Example:
public class Example { @SuppressWarnings(FOO) public void foo() { } private static final String FOO = "FOO"; }
Here the field FOO will be highlighted as unused in its declaration, with a tooltip "Field FOO not used".
My actual use-case is @JsonProperty annotations that occur both on constructor parameters and on getters, hence each property name string occurs multiple times, so
it is useful to define psf constants for those names. But it is irritating that they are all marked as unused by the editor.