]>
git.proxmox.com Git - ceph.git/blob - ceph/src/boost/libs/multiprecision/test/test_mixed_cpp_dec_float.cpp
1 ///////////////////////////////////////////////////////////////
2 // Copyright 2012 John Maddock. Distributed under the Boost
3 // Software License, Version 1.0. (See accompanying file
4 // LICENSE_1_0.txt or copy at http://www.boost.org/LICENSE_1_
7 # define _SCL_SECURE_NO_WARNINGS
10 #include <boost/multiprecision/cpp_dec_float.hpp>
11 #include "test_mixed.hpp"
15 #ifndef BOOST_NO_EXCEPTIONS
18 typedef boost::multiprecision::number
<boost::multiprecision::cpp_dec_float
<100>, boost::multiprecision::et_on
> big_type1
;
19 typedef boost::multiprecision::number
<boost::multiprecision::cpp_dec_float
<50>, boost::multiprecision::et_on
> small_type1
;
20 typedef boost::multiprecision::number
<boost::multiprecision::cpp_dec_float
<100>, boost::multiprecision::et_off
> big_type2
;
21 typedef boost::multiprecision::number
<boost::multiprecision::cpp_dec_float
<50>, boost::multiprecision::et_off
> small_type2
;
23 test
<big_type1
, small_type1
>();
24 test
<big_type2
, small_type2
>();
25 test
<big_type1
, small_type2
>();
26 test
<big_type2
, small_type1
>();
27 #ifndef BOOST_NO_EXCEPTIONS
29 catch(const std::exception
& e
)
31 std::cout
<< "Failed with unexpected exception: " << e
.what() << std::endl
;
35 return boost::report_errors();