DeprecatedVariable
Applying the @Deprecated annotation to local variables or parameters has no effect

Severity
WARNING

The problem

@Deprecated annotations should not be applied to local variables and parameters, since they have no effect there.

The javadoc for @Deprecated says

Use of the @Deprecated annotation on a local variable declaration or on a parameter declaration or a package declaration has no effect on the warnings issued by a compiler.

Suppression

Suppress false positives by adding the suppression annotation @SuppressWarnings("DeprecatedVariable") to the enclosing element.