
13 May
2009
13 May
'09
11 p.m.
Steven Watanabe wrote:
How do you plan to represent the end without adding extra overhead for comparisons?
In the general case, you would need to use a boolean since you cannot just set the iterator to some magic value such as null. The case of pointers could still be specialized. The efficiency overhead could eventually be avoided by relaxing the requirement that both the begin and the end iterator should have the same type, as was suggested by David Abrahams in this message: http://article.gmane.org/gmane.comp.lib.boost.devel/179289