Summary: | Code assist fails in this particular situation | ||
---|---|---|---|
Product: | [Eclipse Project] JDT | Reporter: | Mauro Molinari <mauromol> |
Component: | Core | Assignee: | Jay Arthanareeswaran <jarthana> |
Status: | NEW --- | QA Contact: | |
Severity: | normal | ||
Priority: | P3 | CC: | jarthana, manoj.palat |
Version: | 4.2.1 | ||
Target Milestone: | --- | ||
Hardware: | PC | ||
OS: | Windows 7 | ||
Whiteboard: |
Description
Mauro Molinari
2012-10-27 13:29:24 EDT
This is a simpler case: public enum X { A() { public int count(Foo foo) { foo.returnInteger(new Foo() { }).intV|; return 0; } }; } class Foo { Integer returnInteger(Foo myClass) { return new Integer(0); } } Srikanth, please follow up. The following code produces right proposals. The difference between this and the one from comment #1 is that in the former case the allocation expression gets all the statements, thus producing the right context and receiver. In the buggy one the statements are missing. class Foo { Integer returnInteger(Foo myClass) { return new Integer(0); } } class TestMain { public int foo() { Foo myClass = new Foo(); int i = myClass.returnInteger(new Foo() { }).intV; return i; } } Apologies editing wrong bug I won't be able to finish this one. Will keep in my list, but no promise yet. Thank you Jayaprakash! Sorry, this needs to be moved out of 4.5. Sorry, no hope for 4.6. Bulk moving to 4.7. Bulk move out of 4.8 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. I can still reproduce the problem with the simple test case in comment #1 in 2019-12. 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. I can still reproduce the problem with the simple test case in comment #1 in 2022-06. |