Boost.Range merge of bug fixes and documentation

[SVN r64120]
This commit is contained in:
Neil Groves
2010-07-18 11:36:34 +00:00
parent ca2328ed87
commit 26c095d022
275 changed files with 7445 additions and 5987 deletions

View File

@ -110,6 +110,14 @@ namespace boost
{
shuffled = true;
}
// Verify that the shuffle can be performed on a
// temporary range
Container test2(cont);
boost::random_shuffle(boost::make_iterator_range(test2));
ok = test_shuffle_result(cont, test2);
if (!ok)
break;
}
}
@ -124,6 +132,17 @@ namespace boost
{
BOOST_CHECK( gen.invocation_count() > 0 );
}
// Test that random shuffle works when
// passed a temporary range
RandomGenerator gen2;
Container cont2(old_cont);
boost::random_shuffle(boost::make_iterator_range(cont2), gen2);
test_shuffle_result(cont2, old_cont);
if (cont2.size() > 2)
{
BOOST_CHECK( gen2.invocation_count() > 0 );
}
}
template<class Container>