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 145018 - Change return type hint
Summary: Change return type hint
Status: RESOLVED WORKSFORME
Alias: None
Product: java
Classification: Unclassified
Component: Hints (show other bugs)
Version: 6.x
Hardware: All All
: P3 blocker (vote)
Assignee: Jan Lahoda
URL:
Keywords:
Depends on:
Blocks:
 
Reported: 2008-08-25 15:16 UTC by Jiri Prox
Modified: 2012-12-27 11:16 UTC (History)
1 user (show)

See Also:
Issue Type: ENHANCEMENT
Exception Reporter:


Attachments
Works in 7.3 (3.04 KB, image/png)
2012-12-27 11:15 UTC, markiewb
Details

Note You need to log in before you can comment on or make changes to this bug.
Description Jiri Prox 2008-08-25 15:16:24 UTC
Product Version: NetBeans IDE Dev (Build 20080825043643)
Java: 1.6.0_10-rc; Java HotSpot(TM) Client VM 11.0-b13
System: Linux version 2.6.22-15-generic running on i386; UTF-8; en_US (nb)

Change type hint can be extended to work also for methods. It will suggest change return type of method when there is
incompatible type used in the return clause.

Example:

    public String meth() {
        return 1;
    }

the hint on line with return can suggest changing the method into:

    public int meth() {
        return 1;
    }
Comment 1 markiewb 2012-12-27 11:15:44 UTC
Created attachment 129713 [details]
Works in 7.3

Works for me in 7.3 (201212260001). See screenshot