Bug 435122 - Compilation error when extracting variable with invalid name (literal)
Summary: Compilation error when extracting variable with invalid name (literal)
Status: NEW
Alias: None
Product: CDT
Classification: Tools
Component: cdt-refactoring (show other bugs)
Version: Next   Edit
Hardware: PC Mac OS X
: P3 normal (vote)
Target Milestone: ---   Edit
Assignee: Project Inbox CLA
QA Contact: Jonah Graham CLA
URL:
Whiteboard:
Keywords:
Depends on:
Blocks:
 
Reported: 2014-05-17 11:18 EDT by Melina Mongiovi CLA
Modified: 2020-09-04 15:17 EDT (History)
1 user (show)

See Also:


Attachments

Note You need to log in before you can comment on or make changes to this bug.
Description Melina Mongiovi CLA 2014-05-17 11:18:41 EDT
Eclipse IDE for C/C++ Developers


Reproducing the bug:


Consider the following code:
======== Original Version ========

float func_0 (  float LocalVar_1){
	int LocalVar_0 = 2;
return LocalVar_1;
}
int Function_0 ( ){

int LocalVar_0 = -1;
return LocalVar_0;
}

After applying the refactoring, we have the resulting code:

float func_0 (  float LocalVar_1){
	int 0 = 2;
	int LocalVar_0 = 0;
return LocalVar_1;
}
int Function_0 ( ){

int LocalVar_0 = -1;
return LocalVar_0;
}