JDK-8033421 : @SuppressWarnings("deprecation") does not work when overriding deprecated method
  • Type: Bug
  • Component: tools
  • Sub-Component: javac
  • Affected Version: 8
  • Priority: P4
  • Status: Closed
  • Resolution: Fixed
  • Submitted: 2014-02-02
  • Updated: 2015-01-21
  • Resolved: 2014-02-07
The Version table provides details related to the release that this issue/RFE will be addressed.

Unresolved : Release in which this issue/RFE will be addressed.
Resolved: Release in which this issue/RFE has been resolved.
Fixed : Release in which this issue/RFE has been fixed. The release containing this fix may be available for download as an Early Access Release or a General Availability Release.

To download the current JDK release, click here.
8u40Fixed 9 b04Fixed
Related Reports
Relates :  
Consider this example:
public class Depr implements Intf {
    public void test() { }

interface Intf {
    @Deprecated void test();

Running with -Xlint:deprecation produces this:
$ javac -Xlint:deprecation Depr.java 
Depr.java:3: warning: [deprecation] test() in Intf has been deprecated
    public void test() { }
1 warning

While the warning should probably be suppressed by the @SuppessWarnings annotation.

This can be reproduced with:
$ javac -fullversion
javac full version "1.8.0-ea-b121"

See original bugreport: