Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Renaming Local Variables Leads to Changes in Code Behavior #7847

Open
assdfsdafasfa opened this issue Oct 8, 2024 · 0 comments
Open

Renaming Local Variables Leads to Changes in Code Behavior #7847

assdfsdafasfa opened this issue Oct 8, 2024 · 0 comments
Labels
kind:bug Bug report or fix needs:triage Requires attention from one of the committers

Comments

@assdfsdafasfa
Copy link

Apache NetBeans version

Apache NetBeans 23

What happened

When the "variabeToBeRenamed" is selected for the rename variable refactoring, code before refactoring, "variable" variable assigned to "fieldToBeRenamed" field;

class SourceClass{
int variableToBeRenamed = 1;
class InnerClass{
int field = 0;
void method(){
field = variableToBeRenamed ;
}
}
}

Language / Project Type / NetBeans Component

No response

How to reproduce

When the "variabeToBeRenamed" is selected for the rename variable refactoring, code before refactoring, "variable" variable assigned to "fieldToBeRenamed" field;

class SourceClass{
int variableToBeRenamed = 1;
class InnerClass{
int field = 0;
void method(){
field = variableToBeRenamed ;
}
}
}

Did this work correctly in an earlier version?

Apache NetBeans 23

Operating System

Windows11

JDK

20

Apache NetBeans packaging

Apache NetBeans provided installer

Anything else

No response

Are you willing to submit a pull request?

No

@assdfsdafasfa assdfsdafasfa added kind:bug Bug report or fix needs:triage Requires attention from one of the committers labels Oct 8, 2024
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
kind:bug Bug report or fix needs:triage Requires attention from one of the committers
Projects
None yet
Development

No branches or pull requests

1 participant