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 7407 - Setting deprecation flag doesn't work
Summary: Setting deprecation flag doesn't work
Status: CLOSED WORKSFORME
Alias: None
Product: java
Classification: Unclassified
Component: Unsupported (show other bugs)
Version: 3.x
Hardware: PC All
: P3 normal (vote)
Assignee: Svata Dedic
URL:
Keywords:
Depends on: 7583
Blocks:
  Show dependency tree
 
Reported: 2000-08-17 05:55 UTC by Vaughn Spurlin
Modified: 2007-09-26 09:14 UTC (History)
1 user (show)

See Also:
Issue Type: DEFECT
Exception Reporter:


Attachments
test java file (719 bytes, text/plain)
2000-08-24 09:05 UTC, pzajac
Details

Note You need to log in before you can comment on or make changes to this bug.
Description Vaughn Spurlin 2000-08-17 05:55:29 UTC
User Jason Che-han Yip reported the following.

I went to Project | Settings | Compiler Types and for all the types, I set
Deprecation to true. I checked the deprecation tag replace and it's
"-deprecation". It doesn't work. I'm still being told to run the compiler with
-deprecation for details.

Vaughn Spurlin verified the problem with builds 842 and 1067, but found that it
worked correctly with Netbeans 3.0 build 4.
Comment 1 pzajac 2000-08-24 09:01:59 UTC
It was tested on [Netbeans-18] and [1083]. Deprecation property od compiler
doesn't work correctly.
Comment 2 pzajac 2000-08-24 09:05:59 UTC
Created attachment 110 [details]
test java file
Comment 3 Svata Dedic 2000-09-07 14:17:59 UTC
Replacements for deprecation flag added to the commandline.
Comment 4 Svata Dedic 2000-09-14 17:29:59 UTC
Additional info:
All the optional flags that can be passed to the compiler (debug, deprecation,
optimize) don't work with the corresponding settings in the compiler property
sheet. If the option replacement (e.g. {deprecation}) is present in the
compiler's descriptor commandline, the flag is always passed regardless of the
property setting. If the replacement is missing from the command line, the flag
is never passed although it is set to true.
Comment 5 Svata Dedic 2000-09-14 17:34:59 UTC
a) deprecation, optimize, debug tags were added to the default commandline.
b) all these tags are replaced based on the corresponding property's value - if
the property is true, the tag is replaced by the replacement (the real option),
if the property is false, it is replaced by an empty string.
Comment 6 Jan Becicka 2000-10-06 15:32:59 UTC
[1117] Bug still lives
Comment 7 Svata Dedic 2000-10-09 09:36:59 UTC
I tried flipping deprecation flag (and debuginfo, optimize too) in 1117
(06/10/2000, 06:40 CET) and it works for external compiler and fastjavac.
{deprecation} is replaced properly on the commandline.
Comment 8 Svata Dedic 2000-10-09 09:37:59 UTC
*** Bug 7753 has been marked as a duplicate of this bug. ***
Comment 9 ibeaumont 2000-11-09 11:03:59 UTC
Always had problems with this - just tried it on build 65 and still have the
same problem.  Am using FastJavac compilation.  Deprecation is set to true, but
when I compile the file it still tells me I am using deprecated APIs and to
recompile with -deprecation.
Comment 10 Tomas Hurka 2001-01-12 11:12:59 UTC
I tested it yesterday (11 Jan 2001) on latest build from cvs and it works for
me.
Comment 11 Quality Engineering 2003-07-01 13:12:43 UTC
Resolved for 3.3.x or earlier, no new info since then -> closing.
Comment 12 Quality Engineering 2003-07-01 13:20:45 UTC
Resolved for 3.4.x or earlier, no new info since then -> closing.