Merge unordered from trunk.

- Avoid using operator& with the value type.
- More comments in headers.
- Remove old clang workaround.
- Adjust use of inline to make Borland a little happier.
- Avoid `-Wconversion` warnings.


[SVN r67663]
This commit is contained in:
Daniel James
2011-01-04 23:05:55 +00:00
parent dc8e65043b
commit 54f9626c12
13 changed files with 215 additions and 81 deletions

View File

@@ -52,7 +52,7 @@ void unique_insert_tests1(X*,
tracker.compare_key(x, *it);
if(x.size() < b * old_bucket_count)
if(static_cast<double>(x.size()) < b * static_cast<double>(old_bucket_count))
BOOST_TEST(x.bucket_count() == old_bucket_count);
}
@@ -83,7 +83,7 @@ void equivalent_insert_tests1(X*,
tracker.compare_key(x, *it);
if(x.size() < b * old_bucket_count)
if(static_cast<double>(x.size()) < b * static_cast<double>(old_bucket_count))
BOOST_TEST(x.bucket_count() == old_bucket_count);
}
@@ -118,7 +118,7 @@ void insert_tests2(X*,
BOOST_TEST(*r1 == *r2);
tracker.compare_key(x, *it);
if(x.size() < b * old_bucket_count)
if(static_cast<double>(x.size()) < b * static_cast<double>(old_bucket_count))
BOOST_TEST(x.bucket_count() == old_bucket_count);
}
@@ -145,7 +145,7 @@ void insert_tests2(X*,
BOOST_TEST(*r1 == *r2);
tracker.compare_key(x, *it);
if(x.size() < b * old_bucket_count)
if(static_cast<double>(x.size()) < b * static_cast<double>(old_bucket_count))
BOOST_TEST(x.bucket_count() == old_bucket_count);
}
@@ -172,7 +172,7 @@ void insert_tests2(X*,
BOOST_TEST(*pos == *r2);
tracker.compare_key(x, *it);
if(x.size() < b * old_bucket_count)
if(static_cast<double>(x.size()) < b * static_cast<double>(old_bucket_count))
BOOST_TEST(x.bucket_count() == old_bucket_count);
}
@@ -197,7 +197,7 @@ void insert_tests2(X*,
tracker.insert(*it);
tracker.compare_key(x, *it);
if(x.size() < b * old_bucket_count)
if(static_cast<double>(x.size()) < b * static_cast<double>(old_bucket_count))
BOOST_TEST(x.bucket_count() == old_bucket_count);
}
@@ -275,7 +275,7 @@ void unique_emplace_tests1(X*,
tracker.compare_key(x, *it);
if(x.size() < b * old_bucket_count)
if(static_cast<double>(x.size()) < b * static_cast<double>(old_bucket_count))
BOOST_TEST(x.bucket_count() == old_bucket_count);
}
@@ -306,7 +306,7 @@ void equivalent_emplace_tests1(X*,
tracker.compare_key(x, *it);
if(x.size() < b * old_bucket_count)
if(static_cast<double>(x.size()) < b * static_cast<double>(old_bucket_count))
BOOST_TEST(x.bucket_count() == old_bucket_count);
}
@@ -335,7 +335,7 @@ void map_tests(X*, test::random_generator generator = test::default_generator)
tracker.compare_key(x, *it);
if(x.size() < b * old_bucket_count)
if(static_cast<double>(x.size()) < b * static_cast<double>(old_bucket_count))
BOOST_TEST(x.bucket_count() == old_bucket_count);
}