From ec3632c322c701462a3dab25c203e1997ecabd80 Mon Sep 17 00:00:00 2001 From: Daniel James Date: Fri, 27 Nov 2009 19:43:26 +0000 Subject: [PATCH] Try to suppress some more Visual C++ warnings. [SVN r57976] --- hash/test/hash_complex_test.cpp | 3 +++ hash/test/hash_float_test.hpp | 4 ++++ include/boost/functional/hash/hash.hpp | 2 +- 3 files changed, 8 insertions(+), 1 deletion(-) diff --git a/hash/test/hash_complex_test.cpp b/hash/test/hash_complex_test.cpp index 7adffd9..3d7c200 100644 --- a/hash/test/hash_complex_test.cpp +++ b/hash/test/hash_complex_test.cpp @@ -25,6 +25,9 @@ int main() {} #pragma warning(disable:4305) // truncation from 'double' to 'const std::complex::_Ty' #pragma warning(disable:4309) // truncation of constant value #pragma warning(disable:4512) // assignment operator could not be generated +#if BOOST_MSVC < 1400 +#pragma warning(disable:4267) // conversion from 'size_t' to 'unsigned int', possible loss of data +#endif #endif #include diff --git a/hash/test/hash_float_test.hpp b/hash/test/hash_float_test.hpp index b1c19fc..ab3cbf2 100644 --- a/hash/test/hash_float_test.hpp +++ b/hash/test/hash_float_test.hpp @@ -23,6 +23,10 @@ #if defined(BOOST_MSVC) #pragma warning(push) #pragma warning(disable:4127) // conditional expression is constant +#pragma warning(disable:4723) // conditional expression is constant +#if BOOST_MSVC < 1400 +#pragma warning(disable:4267) // conversion from 'size_t' to 'unsigned int', possible loss of data +#endif #endif char const* float_type(float*) { return "float"; } diff --git a/include/boost/functional/hash/hash.hpp b/include/boost/functional/hash/hash.hpp index ce1ce94..697cb41 100644 --- a/include/boost/functional/hash/hash.hpp +++ b/include/boost/functional/hash/hash.hpp @@ -199,7 +199,7 @@ namespace boost #if defined(BOOST_MSVC) #pragma warning(push) -#if BOOST_MSVC == 1400 +#if BOOST_MSVC <= 1400 #pragma warning(disable:4267) // 'argument' : conversion from 'size_t' to 'unsigned int', // possible loss of data // A misguided attempt to detect 64-bit incompatability.