Details
-
Bug
-
Status: Resolved
-
Major
-
Resolution: Fixed
-
1.4, 1.5
-
None
Description
The remove() method of ArrayListItemIterator doesn't move the pointer back one item. After remove() your only option is to call next(), but the implementation of ArrayListItemIterator moves to second next item instead of the item which comes after the removed one. So it is impossible to iterate to the item which comes immediately after the removed item.
The following code illustrates this (run with "-ea"):
public class ArrayListTest {
public static void main(String[] args)
}
I didn't check the other Iterator implementations.