Actions
Task #1745
closedskiplist: Changing to const_iterators
Status:
Closed
Priority:
Normal
Assignee:
-
Target version:
-
Start date:
07/08/2014
Due date:
% Done:
0%
Estimated time:
Description
Reported by Junxiao:
http://stackoverflow.com/questions/765257/should-i-prefer-iterators-over-const-iterators
This article points out that a caller may modify a value referenced by an iterator. I don't think the SkipList type can handle this situation correctly.
I suggest changing all iterator to const_iterator, so that they cannot be changed. repo index won't need to use a mutable iterator anywhere.
Updated by Junxiao Shi over 8 years ago
- Status changed from Resolved to Closed
This is no longer needed because Index is now based on std::set.
Actions