trac 8676 sliced adaptor fixed.

This commit is contained in:
Neil Groves
2014-03-03 00:10:08 +00:00
parent 8b60f2c768
commit 63acc5c633
4 changed files with 59 additions and 4 deletions

View File

@ -34,7 +34,8 @@ namespace boost
public:
template<typename Rng, typename T, typename U>
sliced_range(Rng& rng, T t, U u)
: base_t(boost::make_iterator_range(rng, t, u - boost::size(rng)))
: base_t(boost::next(boost::begin(rng), t),
boost::next(boost::begin(rng), u))
{
}
};