I thought it to be more useful to not have any restriction. Then you can e.g. go through a set and add and remove items as you go, and there will be no copy-on-write overhead and you will reach the newly added items if they're inserted ahead of the iterator. To me that's more natural than a frozen index set with copy-on-write, i.e. if the case wasn't mentioned in a manual that's how I'd assume it to be.
Other more unusual operations are made possible too, e.g. to store two iterators (perhaps pointers would be a more appropriate name in this case) that are next to each other, and then at a later point do some operation on the elements that have been inserted in between. The difference from simply looking them up again is that it will be completely well defined even if the indices are identical.
/ Martin Stjernholm, Roxen IS
Previous text:
2003-01-30 19:29: Subject: Re: hybrid of array & list
Hm, *ponders* Doesn't it do rather well without it, though?
I think an iteration should iterate over the dataset as it were at the point of the iteration initialization. If that isn't possible, at least the same index set.
/ Mirar