This Bugzilla instance is a read-only archive of historic NetBeans bug reports. To report a bug in NetBeans please follow the project's instructions for reporting issues.

Bug 76741 - Can't rename iteration variable
Summary: Can't rename iteration variable
Status: VERIFIED FIXED
Alias: None
Product: java
Classification: Unclassified
Component: Refactoring (show other bugs)
Version: 5.x
Hardware: All All
: P3 blocker with 1 vote (vote)
Assignee: issues@java
URL:
Keywords:
: 63480 65342 82408 83307 105133 (view as bug list)
Depends on:
Blocks:
 
Reported: 2006-05-23 15:25 UTC by Jaromir Uhrik
Modified: 2007-09-19 16:04 UTC (History)
2 users (show)

See Also:
Issue Type: DEFECT
Exception Reporter:


Attachments
Screenshot attached... (31.18 KB, image/png)
2006-05-23 15:28 UTC, Jaromir Uhrik
Details

Note You need to log in before you can comment on or make changes to this bug.
Description Jaromir Uhrik 2006-05-23 15:25:41 UTC
[NetBeans 5.5 Beta]
Write following code to main method:
 for (int i = 0; i < 10; i++) {
    System.out.println(i);
 }
 for (int j = 0; j < 10; j++) {
    System.out.println(j);
 }
Now move cursor to declaration of variable "j". Push Refactor|Rename. The rename
dialog appears and asks you to type variable name. Type "i". This rename is not
possible because name "i" is already used as a variable (see attached screenshot).
Comment 1 Jaromir Uhrik 2006-05-23 15:28:17 UTC
Created attachment 30564 [details]
Screenshot attached...
Comment 2 Jan Becicka 2006-05-26 12:50:25 UTC
It is duplicate of some issue I cannot find
Comment 3 olegsukhodolsky 2006-09-01 20:57:26 UTC
it looks like 83307 is a duplicate of this issue
Comment 4 Jiri Prox 2006-09-04 07:58:29 UTC
*** Issue 83307 has been marked as a duplicate of this issue. ***
Comment 5 Jan Becicka 2006-11-22 13:39:41 UTC
*** Issue 82408 has been marked as a duplicate of this issue. ***
Comment 6 Jan Becicka 2006-11-22 13:40:02 UTC
*** Issue 63480 has been marked as a duplicate of this issue. ***
Comment 7 Jan Becicka 2007-04-26 12:23:11 UTC
*** Issue 65342 has been marked as a duplicate of this issue. ***
Comment 8 Jan Becicka 2007-05-30 10:15:35 UTC
Checking in RenameRefactoringPlugin.java;
/cvs/refactoring/java/src/org/netbeans/modules/refactoring/java/plugins/RenameRefactoringPlugin.java,v
 <--  RenameRefactoringPlugin.java
new revision: 1.20; previous revision: 1.19
done
RCS file:
/cvs/refactoring/java/src/org/netbeans/modules/refactoring/java/plugins/LocalVarScanner.java,v
done
Checking in LocalVarScanner.java;
/cvs/refactoring/java/src/org/netbeans/modules/refactoring/java/plugins/LocalVarScanner.java,v
 <--  LocalVarScanner.java
initial revision: 1.1
done
Checking in RenameTransformer.java;
/cvs/refactoring/java/src/org/netbeans/modules/refactoring/java/plugins/RenameTransformer.java,v
 <--  RenameTransformer.java
new revision: 1.8; previous revision: 1.7
done
Comment 9 Jiri Prox 2007-05-30 14:06:30 UTC
*** Issue 105133 has been marked as a duplicate of this issue. ***
Comment 10 Jaromir Uhrik 2007-09-19 16:04:43 UTC
Verified.