Boost logo

Boost :

Subject: Re: [boost] Is Boost.Range broken?
From: David Abrahams (dave_at_[hidden])
Date: 2008-11-23 02:04:28

on Sat Nov 22 2008, Tomas Puverle <> wrote:

> Scott,
>> But what semantics for empty *are* documented?
>>> #Semantics
>> empty(x) returns boost::begin(x) == boost::end(x)
> Prior to 1.35, the iterator_range<> documentation read the following:
> "Recall that many default constructed iterators are singular and hence can only
> be assigned, but not compared or incremented or anything. However, if one
> creates a default constructed iterator_range, then one can still call all its
> member functions. This means that the iterator_range will still be usable in
> many contexts even though the iterators underneath are not. "
> Does this answer your question?

Finally, it answers mine. Now the question is: whose code will remain
broken? Those who used iterator_range prior to 1.35 and relied on this
feature, or those who used it after 1.35 and expect not to incur space
and time overhead to support it?

Dave Abrahams
BoostPro Computing

Boost list run by bdawes at, gregod at, cpdaniel at, john at