You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Right now, the Items struct uses the default version of the nth method for Iterators. But this makes repeated calls to next(), which is unnecessary for Items. The Items struct should use it's own version that skips directly to the nth offset element.
The text was updated successfully, but these errors were encountered:
thestinger
changed the title
Items should implement a better version of nth()
random access iterators should implement a better version of nth()
Sep 18, 2014
This is likely in reference to what is now std::vec::Iter, but really it's applicable to all RandomAccessIterators. There's some mumbling of just dropping RAI as a trait for now pending better design/motivation (it's currently marked as unstable iirc).
Right now, the Items struct uses the default version of the
nth
method for Iterators. But this makes repeated calls tonext()
, which is unnecessary for Items. The Items struct should use it's own version that skips directly to then
th offset element.The text was updated successfully, but these errors were encountered: