Avoid -Wconversion warnings in unordered & hash.

[SVN r67170]
This commit is contained in:
Daniel James
2010-12-11 14:43:00 +00:00
parent 5a81ca6ffe
commit 3d7abd9cbe
4 changed files with 14 additions and 13 deletions

View File

@@ -19,7 +19,8 @@ test::seed_t seed(2974);
template <class X>
bool postcondition(X const& x, BOOST_DEDUCED_TYPENAME X::size_type n)
{
return x.bucket_count() > x.size() / x.max_load_factor() &&
return static_cast<double>(x.bucket_count()) >
static_cast<double>(x.size()) / x.max_load_factor() &&
x.bucket_count() >= n;
}