Boost logo

Boost Users :

From: David Abrahams (dave_at_[hidden])
Date: 2008-06-06 11:45:33

on Fri Jun 06 2008, Jeff Flinn <> wrote:

> I'm moving from 1.34.1 to 1.35.0
> The following compiles in 1.34.1 and fails in 1.35.0 on MSVC 8. Any
> thoughts on how to correct this?


in 1.35 I'm pretty sure that iterator_range<T>::size() only works when T
is a random access iterator, and filtered iterators are by necessity
bidirectional. I suggest you use

                std::distance(r.begin(), r.end())

if you're willing to pay for O(N) execution.

Dave Abrahams
BoostPro Computing

Boost-users list run by williamkempf at, kalb at, bjorn.karlsson at, gregod at, wekempf at