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 have a Maven project set to Java 1.3 source code level. The editor shows a warning about missing generic type, but 1.3 does not support generics. I will attach a screenshot.
Created attachment 85896 [details] Screenshot of the project properties and the warning in the java editor
It will be nice to be able to determine sourcelevel from CompilationInfo. This will be useful for this issue and also some other problems in code completion etc. Thanks Dusane.
Created attachment 85911 [details] Proposed API change
I would like to propose a small change to the java.source API to allow for getting the source version used by the javac compiler from CompilationInfo (diff is attached).
Seems good to me.
Seems OK to me also.
Y01 Missing test? Y02 Don't forget to increase dependency of modules that will use the new method to 0.46
Requested API change integrated into jet-main (including missing test). http://hg.netbeans.org/jet-main/rev/4671b2a6fde5
Integrated into 'main-golden', will be available in build *200908130201* on http://bits.netbeans.org/dev/nightly/ (upload may still be in progress) Changeset: http://hg.netbeans.org/main-golden/rev/4671b2a6fde5 User: Dusan Balek <dbalek@netbeans.org> Log: CompilationInfo.getSourceVersion() method added (see issue #169970).
Fixed. --- http://hg.netbeans.org/jet-main/rev/798d21d29894
Integrated into 'main-golden', will be available in build *200908140201* on http://bits.netbeans.org/dev/nightly/ (upload may still be in progress) Changeset: http://hg.netbeans.org/main-golden/rev/798d21d29894 User: Max Sauer <msauer@netbeans.org> Log: #169970: Java 1.3 projects get [rawtypes] warnings
Integrated into 'main-golden', will be available in build *200908210201* on http://bits.netbeans.org/dev/nightly/ (upload may still be in progress) Changeset: http://hg.netbeans.org/main-golden/rev/1b32260fc9ac User: Jan Lahoda <jlahoda@netbeans.org> Log: #169970(better fix): disabling the rawtypes warning for source levels < 1.5 on compiler level.
Jan's change does nothing more than to reverts Max' changes, so the issue is open again.
And did you actually try to reproduce the problem on a build with my change? My change reverts Max's change *and* installs new javac: 2.1 --- a/libs.javacimpl/external/binaries-list 2.2 +++ b/libs.javacimpl/external/binaries-list 2.3 @@ -1,1 +1,1 @@ 2.4 -2C677BED0467528931E819A88F43BA5750F33510 javac-impl-nb-7.0-b07.jar 2.5 +9CD5A09E5146CA7E7605303FD3393098653C23B2 javac-impl-nb-7.0-b07.jar Max's change is no longer needed with the new javac: http://hg.netbeans.org/main/nb-javac/rev/cce9961e143a
Jan, I did not try to reproduce. I did not understand what your change to a binary file did as your only comment was "better fix". I close the issue as fixed.