Bug 424124

Summary: [1.8][Code Completion] Changes the case of the name of the variable
Product: [Eclipse Project] JDT Reporter: shankha banerjee <shankhba>
Component: CoreAssignee: JDT-Core-Inbox <jdt-core-inbox>
Status: NEW --- QA Contact: Jay Arthanareeswaran <jarthana>
Severity: normal    
Priority: P3 CC: manoj.palat, shankhba, srikanth_sankaran
Version: 4.4   
Target Milestone: ---   
Hardware: PC   
OS: Windows 7   
Whiteboard: stalebug

Description shankha banerjee CLA 2013-12-16 09:05:51 EST
class X1 {};

interface I {
	void foo (X1 x1/* 1. Press Space. */);
}

class X2 {
	 I i = (X1 x1/* 2. Press Space */) -> {};
}

------------------------------------------------------
1. No changes
2.  I i = (X1 X1)

No errors issues by the compiler. Shouldn't the compiler throw a error.
b115 does not.

The problem with the above transformation is:

interface J {
	int foo (X1 x1);
}

class X3 {
	J j = (X1 x1) -> {
		return x1.x;
	};
}

We would get a syntax error for return x1.x;
if "X1 x1" is modified to "X1 X1".
Comment 1 Srikanth Sankaran CLA 2014-01-06 10:25:37 EST
Retargetting to 4.4, will pull it up to Java 8 GA if time permits.
Comment 2 Manoj N Palat CLA 2015-04-07 23:58:17 EDT
Shankha: Can you please take a look and move it out of 4.5 if required?
Comment 3 Eclipse Genie CLA 2020-08-06 15:53:34 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 Eclipse Genie CLA 2022-08-14 06:19:43 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.