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 258944 - Hints don't work for method creation and thrown exceptions
Summary: Hints don't work for method creation and thrown exceptions
Status: RESOLVED FIXED
Alias: None
Product: editor
Classification: Unclassified
Component: Hints & Annotations (show other bugs)
Version: 8.2
Hardware: PC Linux
: P3 normal (vote)
Assignee: Milutin Kristofic
URL:
Keywords:
Depends on:
Blocks:
 
Reported: 2016-04-21 11:13 UTC by fordfrog
Modified: 2016-05-07 11:51 UTC (History)
0 users

See Also:
Issue Type: DEFECT
Exception Reporter:


Attachments

Note You need to log in before you can comment on or make changes to this bug.
Description fordfrog 2016-04-21 11:13:41 UTC
having code like this:

        try (final Statement stm = con.createStatement()) {
            
        }

in function editor complains about "unreported exception SQLException;...". hitting Alt+ENTER only displays the information but does not provide the "light bulb" that made it possible to either add the exception to method declaration or add catch statement.

another issue that i suppose is related is that most of the time if one writes method that does not exist, hitting Alt+ENTER does not provide "light bulb" to create the method. it happened once to me that it offered it but i have no idea how to reproduce it.

these bugs appeared first in 2016-04-20's night build sources.
Comment 1 fordfrog 2016-04-21 11:19:20 UTC
i just found out that the "light bulb" is now context related. method creation works when cursor is on the method and i press Alt+ENTER. but for thrown exception in the try () i was not able to trigger the "light bulb".
Comment 2 fordfrog 2016-04-21 11:20:48 UTC
also found out that when cursor is on method that does not exist and pressing Alt+ENTER, the hint appears. then i can place cursor anywhere on the row and the "light bulb" works.
Comment 3 fordfrog 2016-05-07 11:51:55 UTC
this is fixed since nightly build 20160507