|
Boost-Commit : |
Subject: [Boost-commit] svn:boost r81434 - trunk/libs/multiprecision/test
From: john_at_[hidden]
Date: 2012-11-20 07:00:17
Author: johnmaddock
Date: 2012-11-20 07:00:15 EST (Tue, 20 Nov 2012)
New Revision: 81434
URL: http://svn.boost.org/trac/boost/changeset/81434
Log:
Fix Intel compile failure
Text files modified:
trunk/libs/multiprecision/test/test_mixed_cpp_int.cpp | 10 ++++++----
1 files changed, 6 insertions(+), 4 deletions(-)
Modified: trunk/libs/multiprecision/test/test_mixed_cpp_int.cpp
==============================================================================
--- trunk/libs/multiprecision/test/test_mixed_cpp_int.cpp (original)
+++ trunk/libs/multiprecision/test/test_mixed_cpp_int.cpp 2012-11-20 07:00:15 EST (Tue, 20 Nov 2012)
@@ -43,9 +43,11 @@
//
// Try again with integer types as the source:
//
- static const unsigned max_digits = std::numeric_limits<test_type>::is_signed ? std::numeric_limits<long long>::digits : std::numeric_limits<unsigned long long>::digits;
- static const unsigned require_digits = std::numeric_limits<test_type>::digits <= 2 * max_digits ? std::numeric_limits<test_type>::digits / 2 : max_digits;
- typedef typename boost::mpl::if_c<std::numeric_limits<test_type>::is_signed, typename boost::int_t<require_digits>::least, typename boost::uint_t<require_digits>::least>::type i_type;
+ enum{ max_digits = std::numeric_limits<test_type>::is_signed ? std::numeric_limits<long long>::digits : std::numeric_limits<unsigned long long>::digits };
+ enum{ require_digits = std::numeric_limits<test_type>::digits <= 2 * max_digits ? std::numeric_limits<test_type>::digits / 2 : max_digits };
+ typedef typename boost::uint_t<require_digits>::least uint_least;
+ typedef typename boost::int_t<require_digits>::least int_least;
+ typedef typename boost::mpl::if_c<std::numeric_limits<test_type>::is_signed, int_least, uint_least>::type i_type;
i_type ih = (std::numeric_limits<i_type>::max)();
i_type il = (std::numeric_limits<i_type>::max)();
@@ -80,7 +82,7 @@
test<checked_uint256_t, checked_uint512_t>();
test<number<cpp_int_backend<64, 64, unsigned_magnitude, checked, void>, et_off>, checked_uint128_t>();
test<boost::uint64_t, checked_int128_t>();
-
+
return boost::report_errors();
}
Boost-Commit list run by bdawes at acm.org, david.abrahams at rcn.com, gregod at cs.rpi.edu, cpdaniel at pacbell.net, john at johnmaddock.co.uk