forked from boostorg/unordered
Run most of the unordered container tests (not the exception tests) on warning
level 4 on Visual C++. [SVN r38648]
This commit is contained in:
@@ -9,6 +9,7 @@ project unordered-test/unordered
|
||||
: requirements
|
||||
<toolset>intel-linux:"<cxxflags>-strict_ansi -cxxlib-icc"
|
||||
<toolset>gcc:<cxxflags>-Wsign-promo
|
||||
<toolset>msvc:<cxxflags>/W4
|
||||
;
|
||||
|
||||
test-suite unordered-tests
|
||||
|
||||
@@ -6,7 +6,17 @@
|
||||
#include <boost/unordered_set.hpp>
|
||||
#include <boost/unordered_map.hpp>
|
||||
|
||||
#if defined(BOOST_MSVC)
|
||||
#pragma warning(push)
|
||||
#pragma warning(disable:4100) // unreferenced formal parameter
|
||||
#endif
|
||||
|
||||
#include <boost/concept_check.hpp>
|
||||
|
||||
#if defined(BOOST_MSVC)
|
||||
#pragma warning(pop)
|
||||
#endif
|
||||
|
||||
#include <boost/mpl/assert.hpp>
|
||||
#include <boost/iterator/iterator_traits.hpp>
|
||||
#include "../helpers/check_return_type.hpp"
|
||||
|
||||
@@ -9,6 +9,11 @@
|
||||
#include <boost/limits.hpp>
|
||||
#include "../helpers/random_values.hpp"
|
||||
|
||||
#if defined(BOOST_MSVC)
|
||||
#pragma warning(push)
|
||||
#pragma warning(disable:4127) // conditional expression is constant
|
||||
#endif
|
||||
|
||||
template <class X>
|
||||
void load_factor_tests(X* = 0)
|
||||
{
|
||||
@@ -70,3 +75,8 @@ int main()
|
||||
|
||||
return boost::report_errors();
|
||||
}
|
||||
|
||||
#if defined(BOOST_MSVC)
|
||||
#pragma warning(pop)
|
||||
#pragma warning(disable:4127) // conditional expression is constant
|
||||
#endif
|
||||
|
||||
@@ -11,7 +11,7 @@ struct count_copies
|
||||
{
|
||||
static int count;
|
||||
count_copies() { ++count; }
|
||||
count_copies(count_copies const& x) { ++count; }
|
||||
count_copies(count_copies const&) { ++count; }
|
||||
private:
|
||||
count_copies& operator=(count_copies const&);
|
||||
};
|
||||
@@ -20,7 +20,7 @@ private:
|
||||
namespace boost {
|
||||
#endif
|
||||
|
||||
std::size_t hash_value(count_copies const& x) {
|
||||
std::size_t hash_value(count_copies const&) {
|
||||
return 0;
|
||||
}
|
||||
|
||||
@@ -28,7 +28,7 @@ std::size_t hash_value(count_copies const& x) {
|
||||
}
|
||||
#endif
|
||||
|
||||
bool operator==(count_copies const& x, count_copies const& y) {
|
||||
bool operator==(count_copies const&, count_copies const&) {
|
||||
return true;
|
||||
}
|
||||
|
||||
|
||||
Reference in New Issue
Block a user