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.
Product Version = NetBeans IDE 7.3 RC2 (Build 201302050851) Operating System = Windows 7 version 6.1 running on amd64 Java; VM; Vendor = 1.7.0_13 Runtime = Java HotSpot(TM) 64-Bit Server VM 23.7-b01 The "unnecessary null test" hint is unfluenced by the @javax.annotation.Notnull annotation. The following code: public void showBug2(@javax.annotation.Nonnull String str) { assert str != null; .............. generates a false hint message on the assert line while it should not. By removing the annotation on the str parameter, the hint message disappears.
Created attachment 131227 [details] IDE log
Created attachment 131228 [details] Netbeans screen shot The image show the flase message hint on the second method while the first one, without annotation, does not have any hint messages.
Created attachment 131229 [details] Class source file
Integrated into 'main-golden', will be available in build *201306212301* on http://bits.netbeans.org/dev/nightly/ (upload may still be in progress) Changeset: http://hg.netbeans.org/main-golden/rev/af654455806b User: Jan Lahoda <jlahoda@netbeans.org> Log: #225970: making null pointer check ignore precondition checks.
The check should be ignoring typical "precondition checks" after the above changeset.