This Bugzilla instance is a read-only archive of historic NetBeans bug reports. To report a bug in NetBeans please follow the project's instructions for reporting issues.

Bug 114267 - Netbeans ignores @SuppressWarnings("deprecation")
Summary: Netbeans ignores @SuppressWarnings("deprecation")
Alias: None
Product: java
Classification: Unclassified
Component: Source (show other bugs)
Version: 6.x
Hardware: All All
: P3 blocker with 1 vote (vote)
Assignee: Jan Lahoda
Depends on:
Reported: 2007-08-30 17:13 UTC by _ gtzabari
Modified: 2016-12-17 22:45 UTC (History)
0 users

See Also:
Issue Type: DEFECT
Exception Reporter:


Note You need to log in before you can comment on or make changes to this bug.
Description _ gtzabari 2007-08-30 17:13:02 UTC
dev build 200708300000

Netbeans displays a "deprecation" hint even though my function is marked with @SuppressWarnings(value = "deprecation").
"Fixable Error -> Fix Code..." generates the exact same @SuppressWarning annotation and the hint still does not go away.
Comment 1 Jan Lahoda 2007-08-30 17:27:22 UTC
I assume the deprecated type is the return type of the method (or maybe the type of one of the parameters?). See:
Comment 2 _ gtzabari 2007-08-30 18:20:08 UTC
No. My method is overriding a superclass method which is marked with @Deprecated.
Comment 3 Jan Lahoda 2007-09-24 12:42:20 UTC
Sorry, but overriding deprecated method seems to work OK for me (at least in recent builds). I was able to reproduce a
problem with subclassing (I have enhanced bug 6594914) - see below. Also see .
package javaapplication5;

public class A {

package javaapplication5;

public class B extends A { //reports "A is deprecated" here

Comment 4 Jiri Prox 2008-04-11 00:51:48 UTC
moving opened issues from TM <= 6.1 to TM=Dev
Comment 5 Jan Becicka 2008-08-05 15:25:15 UTC
We cannot reproduce it. Please attach code snippet. Thanks.
Comment 6 _ gtzabari 2008-08-22 01:58:22 UTC
Unfortunately I don't remember my original use-case and as such I can no longer reproduce it. Do you want to keep this
issue open for the JDK bug you've discovered or should we close it as WORKSFORME?
Comment 7 Jiri Prox 2008-08-22 09:03:04 UTC
The JDK bug should be closed as Won't fix since they have to be fixed on the JDK side.
Comment 8 Leperous 2016-12-17 22:45:40 UTC
This was fixed in JDK 7 so it would be good to see it now fixed in NB 8.