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.
I am not sure about this, just something I noticed while working on a j2seproject. I got a warning from javac (JDK 1.5): Note: /tmp/testantlogging/src/testantlogging/Main.java uses unchecked or unsafe operations. Note: Recompile with -Xlint:unchecked for details. After adding this to my build.xml: <target name="init-macrodef-javac"> <macrodef name="javac" uri="http://www.netbeans.org/ns/j2se-project/1"> <attribute name="srcdir" default="${src.dir}"/> <attribute name="destdir" default="${build.classes.dir}"/> <attribute name="classpath" default="${javac.classpath}"/> <attribute name="debug" default="${javac.debug}"/> <element name="customize" optional="true"/> <sequential> <javac srcdir="@{srcdir}" destdir="@{destdir}" debug="@{debug}" deprecation="${javac.deprecation}" source="${javac.source}" target="${javac.target}" includeantruntime="false"> <classpath> <path path="@{classpath}"/> </classpath> <compilerarg compiler="javac1.5" value="-Xlint:unchecked"/> <!-- *ADDED* --> <customize/> </javac> </sequential> </macrodef> </target> I get the real messages: Compiling 1 source file to /tmp/testantlogging/build/classes /tmp/testantlogging/src/testantlogging/Main.java:63: warning: [unchecked] unchecked call to addFirst(E) as a member of the raw type java.util.LinkedList stack.addFirst(name); ^ /tmp/testantlogging/src/testantlogging/Main.java:86: warning: [unchecked] unchecked call to addFirst(E) as a member of the raw type java.util.LinkedList stack.addFirst(name); ^ 2 warnings Frankly I have no idea what these warnings mean, but presumably they could be important to someone more experienced with generics. :-) If I declare the generic type of my LinkedList in JDK 1.5 semantics, then the warnings go away (to be replaced with many background parser errors because our trunk javac does not grok generics!). Anyway, seems like something we might want to turn on by default for 1.5 users, as a complement to -deprecation (which is apparently now an alias for -Xlint:deprecation??), since it is not obvious how to do the right build.xml edit. Or we could wait for more direct support for such flags in Ant (with proper cross-compiler support).
*** Issue 46314 has been marked as a duplicate of this issue. ***
This should be an option in the UI, just like deprecation warnings on/off.
IMHO, this has to be done for NB 4.0.
Sorry, I think it is too late to be changing the UI for 4.0; we are well past UI freeze. Will certainly be considered for 4.1 however.
Then it should be documented how to turn it on in build.xml.
That's why I added RELNOTE, for the docs team. There are a lot of things we intend to make available in the online help, the knowledge base, etc. Documentation is still in progress and will not be complete until the release. BTW there are already comments in the default build.xml noting various targets you may wish to override. The exact syntax in Ant should be covered in the Ant manual.
Covered by issue #46995. No GUI for nonstandard (-X) options. *** This issue has been marked as a duplicate of 46995 ***