forked from boostorg/range
[boost][range] - Improved handling of temporary ranges in range algorithms.
[SVN r63903]
This commit is contained in:
@ -42,6 +42,9 @@ namespace boost
|
||||
// Test the mutable version
|
||||
fn_t result_fn = boost::for_each(rng, fn_t(rng));
|
||||
BOOST_CHECK_EQUAL( boost::udistance(rng), result_fn.invocation_count() );
|
||||
|
||||
fn_t result_fn2 = boost::for_each(boost::make_iterator_range(rng), fn_t(rng));
|
||||
BOOST_CHECK_EQUAL( boost::udistance(rng), result_fn.invocation_count() );
|
||||
|
||||
// Test the constant version
|
||||
const SinglePassRange& cref_rng = rng;
|
||||
|
Reference in New Issue
Block a user