Bug 504051 - [content assist] context assintant doesn't always work on lambda
Summary: [content assist] context assintant doesn't always work on lambda
Status: VERIFIED DUPLICATE of bug 539685
Alias: None
Product: JDT
Classification: Eclipse Project
Component: Core (show other bugs)
Version: 4.6   Edit
Hardware: PC Windows 7
: P3 major (vote)
Target Milestone: 4.20 M3   Edit
Assignee: Jay Arthanareeswaran CLA
QA Contact:
URL:
Whiteboard:
Keywords:
Depends on:
Blocks:
 
Reported: 2016-10-05 06:23 EDT by lala lala CLA
Modified: 2021-05-26 02:56 EDT (History)
5 users (show)

See Also:


Attachments

Note You need to log in before you can comment on or make changes to this bug.
Description lala lala CLA 2016-10-05 06:23:18 EDT
Considering following code:

public class La {
    public static void main(String [] args)  {		 		
        La l = new La();
	String res = l.calc((a, b) -> "sum:" + (a.intValue() + b.intValue()), new Integer(2), new Integer(2));
        System.out.println(res);	
    }

    public String calc(BiFunction<Integer, Integer, String> bi, Integer i1, Integer i2) {
        return bi.apply(i1, i2);
    }
}

Context assistant does not work when cursor placed just after "a." in statement "a.intValue()", but it works when placed after "b." 
"a" is however correctly recognized as Integer, but context assistant only correctly works on "b".
Comment 1 Jay Arthanareeswaran CLA 2016-10-05 06:34:50 EDT
Reproduced, will take a look during 4.7.
Comment 2 Manoj N Palat CLA 2018-05-21 06:02:12 EDT
Bulk move out of 4.8
Comment 3 Eclipse Genie CLA 2020-08-06 16:47:44 EDT
This bug hasn't had any activity in quite some time. Maybe the problem got resolved, was a duplicate of something else, or became less pressing for some reason - or maybe it's still relevant but just hasn't been looked at yet.

If you have further information on the current state of the bug, please add it. The information can be, for example, that the problem still occurs, that you still want the feature, that more information is needed, or that the bug is (for whatever reason) no longer relevant.

--
The automated Eclipse Genie.
Comment 4 Graeme Geldenhuys CLA 2020-11-15 07:12:52 EST
I can confirm the bug still exists 4 years later in 2020-09. Code completion works in `b.` but not for `a.`


-- Configuration Details --
Product: Eclipse IDE 4.17.0.20200910-1200 (org.eclipse.epp.package.java.product)Installed Features:
 org.eclipse.jdt 3.18.500.v20200902-1800
Versioning Plugin:
 org.eclipse.platform 4.17.0.v20200902-1800
Comment 5 Stephan Herrmann CLA 2021-05-22 17:43:26 EDT
Testing on today's HEAD completion works fine after 'a.' 

Likely fixed via bug 539685 

Feel free to re-open if you can reproduce on a recent build (from https://download.eclipse.org/eclipse/downloads/index.html )

*** This bug has been marked as a duplicate of bug 539685 ***
Comment 6 Jay Arthanareeswaran CLA 2021-05-26 02:56:45 EDT
Verified for 4.20 RC1 with build I20210525-1800