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 201739

Summary: [Change return type] Change to void
Product: java Reporter: Jiri Prox <jiriprox>
Component: HintsAssignee: Svata Dedic <sdedic>
Status: NEW ---    
Severity: normal CC: markiewb
Priority: P3    
Version: 7.1   
Hardware: PC   
OS: Other   
Issue Type: ENHANCEMENT Exception Reporter:
Attachments: Shows the error without any fixable hint

Description Jiri Prox 2011-09-07 12:21:51 UTC
Change return type hint can suggest changing to void it the return statement is not followed by any value, e.g. "return;"
Comment 1 markiewb 2013-02-08 19:24:46 UTC
Created attachment 131172 [details]
Shows the error without any fixable hint

The errorcode is "compiler.err.missing.ret.val".

Provide fixes
* "Change return type to void" (as reported)
* "Return null" -> return null;
* "Return local variable, field of the given type String" -> return localVar; return field;