Bug 97324 - Change Method Signature throws IOOBE for potential reference with differing argument count [refactoring]
Summary: Change Method Signature throws IOOBE for potential reference with differing a...
Status: VERIFIED WORKSFORME
Alias: None
Product: JDT
Classification: Eclipse Project
Component: UI (show other bugs)
Version: 3.1   Edit
Hardware: PC Windows XP
: P3 normal (vote)
Target Milestone: 3.1 RC2   Edit
Assignee: Markus Keller CLA
QA Contact:
URL:
Whiteboard:
Keywords:
Depends on: 97322
Blocks:
  Show dependency tree
 
Reported: 2005-05-30 13:26 EDT by Markus Keller CLA
Modified: 2005-06-09 11:45 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 Markus Keller CLA 2005-05-30 13:26:23 EDT
I20050527-1300

class Tester {
	static void myMethod(int a, String b) {}
	void call() {
		myMethod(12);
	}
}

Change Method Signature: move parameter "a" down.

java.lang.IndexOutOfBoundsException: Index: 1, Size: 1
	at java.util.ArrayList.RangeCheck(ArrayList.java:547)
	at java.util.ArrayList.get(ArrayList.java:322)
	at java.util.Collections$UnmodifiableList.get(Collections.java:1155)
	at
org.eclipse.jdt.internal.corext.refactoring.structure.ChangeSignatureRefactoring$OccurrenceUpdate.reshuffleElements(ChangeSignatureRefactoring.java:1346)
	at
org.eclipse.jdt.internal.corext.refactoring.structure.ChangeSignatureRefactoring$ReferenceUpdate.updateNode(ChangeSignatureRefactoring.java:1459)
	at
org.eclipse.jdt.internal.corext.refactoring.structure.ChangeSignatureRefactoring.createChangeManager(ChangeSignatureRefactoring.java:1071)
	at
org.eclipse.jdt.internal.corext.refactoring.structure.ChangeSignatureRefactoring.checkFinalConditions(ChangeSignatureRefactoring.java:767)
	at
org.eclipse.ltk.core.refactoring.CheckConditionsOperation.run(CheckConditionsOperation.java:84)
	at
org.eclipse.ltk.core.refactoring.CreateChangeOperation.run(CreateChangeOperation.java:114)
	at
org.eclipse.ltk.core.refactoring.PerformChangeOperation.run(PerformChangeOperation.java:189)
	at org.eclipse.core.internal.resources.Workspace.run(Workspace.java:1719)
	at
org.eclipse.ltk.internal.ui.refactoring.WorkbenchRunnableAdapter.run(WorkbenchRunnableAdapter.java:86)
	at
org.eclipse.jface.operation.ModalContext$ModalContextThread.run(ModalContext.java:113)
Comment 1 Markus Keller CLA 2005-06-06 10:17:34 EDT
Checked with JDT/Core from HEAD that the solution for bug 97322 fixes this bug.
Comment 2 Tobias Widmer CLA 2005-06-09 11:45:09 EDT
Verified using N20050609-0010