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 255393 - Find Usages does not find method implemented by lambda - 2
Summary: Find Usages does not find method implemented by lambda - 2
Status: RESOLVED FIXED
Alias: None
Product: java
Classification: Unclassified
Component: Source (show other bugs)
Version: 8.1
Hardware: PC Mac OS X
: P2 normal (vote)
Assignee: Tomas Zezula
URL:
Keywords: API, API_REVIEW_FAST
Depends on:
Blocks:
 
Reported: 2015-09-18 06:59 UTC by Tomas Zezula
Modified: 2015-09-25 01:46 UTC (History)
4 users (show)

See Also:
Issue Type: DEFECT
Exception Reporter:


Attachments
Patch file (10.85 KB, patch)
2015-09-23 13:11 UTC, Tomas Zezula
Details | Diff

Note You need to log in before you can comment on or make changes to this bug.
Description Tomas Zezula 2015-09-18 06:59:51 UTC
See screenshot: https://netbeans.org/bugzilla/attachment.cgi?id=156177
The lambda: (String s) -> "Hello " + s, "World" is not found.

As the Java 8 lambdas unlike the BGGA Java lambdas have no functional types the Lambda expression is just an implementation of an functional interface. So it should be found in find usages.

P2 as other IDEs JDev, Idea, works fine.
Comment 1 Ralph Ruijs 2015-09-21 07:51:15 UTC
jet-main#ba0fae6c1671

Refactoring handles lambda expressions, but they seem missing from the ClassIndex. Please reassign if they are part of the index, but have to be handled differently. Thanks!
Comment 2 Quality Engineering 2015-09-22 01:22:06 UTC
Integrated into 'main-silver', will be available in build *201509220002* on http://bits.netbeans.org/dev/nightly/ (upload may still be in progress)

Changeset: http://hg.netbeans.org/main-silver/rev/ba0fae6c1671
User: Ralph Benjamin Ruijs <ralphbenjamin@netbeans.org>
Log: #255393 - Find Usages does not find method implemented by lambda - 2
Comment 3 Tomas Zezula 2015-09-22 08:47:19 UTC
I will take a look.
Comment 4 Tomas Zezula 2015-09-23 13:11:29 UTC
Created attachment 156381 [details]
Patch file
Comment 5 Tomas Zezula 2015-09-23 13:13:00 UTC
The patch covers an API change adding a SearchKind for lambda implementors and Find Usages fix for the lambdas.
Comment 6 Ralph Ruijs 2015-09-23 15:18:21 UTC
(In reply to Tomas Zezula from comment #4)
> Created attachment 156381 [details]
> Patch file

Patch looks good to me, I'll update the Change Method Parameters refactoring after it lands in jet-main.
Comment 7 Tomas Zezula 2015-09-24 08:00:03 UTC
Fixed jet-main 8adf4be5dc32
Comment 8 Quality Engineering 2015-09-25 01:46:36 UTC
Integrated into 'main-silver', will be available in build *201509250002* on http://bits.netbeans.org/dev/nightly/ (upload may still be in progress)

Changeset: http://hg.netbeans.org/main-silver/rev/8adf4be5dc32
User: Tomas Zezula <tzezula@netbeans.org>
Log: #255393:Find Usages does not find method implemented by lambda - 2