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 251722

Summary: Missing severity levels for java hints and suggestions
Product: java Reporter: cezariusz <cezariusz>
Component: HintsAssignee: Svata Dedic <sdedic>
Status: NEW ---    
Severity: normal CC: carljmosca
Priority: P3    
Version: 8.0.2   
Hardware: PC   
OS: Windows 7   
Issue Type: DEFECT Exception Reporter:
Attachments: Hint as warning on for
Hint as warning on if
Hint as warning on use anonymous inner class

Description cezariusz 2015-04-08 18:00:45 UTC
Product Version: NetBeans IDE Dev (Build 201504030001)
Java: 1.8.0_25; Java HotSpot(TM) 64-Bit Server VM 25.25-b02
Runtime: Java(TM) SE Runtime Environment 1.8.0_25-b18
System: Windows 7 version 6.1 running on amd64; Cp1250; pl_PL (nb)

Some hints are incorrectly marked as warnings. They shouldn't have the exclamation mark overlay on hint bulb. The strange side effect is that when I put the cursor in the place, where such hint is shown, the whole file is marked yellow (instead of green).

The list of such hints include:
1. "Invert If"
2. "Convert to for (Iterator....){}"
Comment 1 cezariusz 2015-04-08 18:01:37 UTC
Created attachment 153102 [details]
Hint as warning on for
Comment 2 cezariusz 2015-04-08 18:01:55 UTC
Created attachment 153103 [details]
Hint as warning on if
Comment 3 cezariusz 2015-04-10 12:05:01 UTC
Created attachment 153127 [details]
Hint as warning on use anonymous inner class

3. "Use anonymous inner class"

See also bug #251757 for a test case.
Comment 4 Svata Dedic 2016-07-27 12:49:21 UTC
The java hints infrastructure currently does not support a severity which would present as 'suggestion' but stay visible even if caret is positioned elsewhere.
Comment 5 Svata Dedic 2016-07-27 12:49:35 UTC
*** Bug 267254 has been marked as a duplicate of this bug. ***