Jean-Marc Lasgouttes wrote: > Alfredo Braunstein <[EMAIL PROTECTED]> > writes: > >> Jean-Marc Lasgouttes wrote: >> >>> I guess we need a erase(pos_type). >> >> grep boost::next *cpp | wc >> 37 185 2583 >> >> A slightly different idea: I wonder if a specialization of advance for >> RandomAccessList::iterator would get us an instant noticeable performance >> improvement (because boost::next uses advance I presume). > > Or we could make sure that plist.begin() + pos works as expected.
I don't think it's possible unfortunately, for the reasons in my other post. We could have a O(1) RandomAccessList::getIterator(int pos) but it's obviously not so cool ;-) And it doesn't work for advancing an existing iterator. A/
