Boost logo

Boost-Commit :

Subject: [Boost-commit] svn:boost r84051 - in trunk: boost/multiprecision/detail libs/multiprecision/test libs/multiprecision/test/coverage
From: john_at_[hidden]
Date: 2013-04-26 04:17:16


Author: johnmaddock
Date: 2013-04-26 04:17:12 EDT (Fri, 26 Apr 2013)
New Revision: 84051
URL: http://svn.boost.org/trac/boost/changeset/84051

Log:
Add lot's of enable_if's to integer only operators to restrict them to integer types (improves error messages).
Update test coverage Makesfile.
Update tests for full coverage.
Text files modified:
   trunk/boost/multiprecision/detail/et_ops.hpp | 193 +++++++++++++++++++++++-------------
   trunk/boost/multiprecision/detail/no_et_ops.hpp | 68 ++++++------
   trunk/libs/multiprecision/test/coverage/Makefile | 208 +++++++++++++++++++++++++++++++++------
   trunk/libs/multiprecision/test/test_arithmetic.hpp | 3
   4 files changed, 334 insertions(+), 138 deletions(-)

Modified: trunk/boost/multiprecision/detail/et_ops.hpp
==============================================================================
--- trunk/boost/multiprecision/detail/et_ops.hpp (original)
+++ trunk/boost/multiprecision/detail/et_ops.hpp 2013-04-26 04:17:12 EDT (Fri, 26 Apr 2013)
@@ -30,9 +30,13 @@
    return detail::expression<detail::negate, detail::expression<tag, Arg1, Arg2, Arg3, Arg4> >(v);
 }
 template <class B>
-inline detail::expression<detail::complement_immediates, number<B, et_on> > operator ~ (const number<B, et_on>& v) { return detail::expression<detail::complement_immediates, number<B, et_on> >(v); }
+inline typename enable_if_c<number_category<B>::value == number_kind_integer,
+ detail::expression<detail::complement_immediates, number<B, et_on> > >::type
+ operator ~ (const number<B, et_on>& v) { return detail::expression<detail::complement_immediates, number<B, et_on> >(v); }
 template <class tag, class Arg1, class Arg2, class Arg3, class Arg4>
-inline detail::expression<detail::bitwise_complement, detail::expression<tag, Arg1, Arg2, Arg3, Arg4> > operator ~ (const detail::expression<tag, Arg1, Arg2, Arg3, Arg4>& v) { return detail::expression<detail::bitwise_complement, detail::expression<tag, Arg1, Arg2, Arg3, Arg4> >(v); }
+inline typename enable_if_c<number_category<typename detail::expression<tag, Arg1, Arg2, Arg3, Arg4>::result_type>::value == number_kind_integer,
+ detail::expression<detail::bitwise_complement, detail::expression<tag, Arg1, Arg2, Arg3, Arg4> > >::type
+ operator ~ (const detail::expression<tag, Arg1, Arg2, Arg3, Arg4>& v) { return detail::expression<detail::bitwise_complement, detail::expression<tag, Arg1, Arg2, Arg3, Arg4> >(v); }
 //
 // Then addition:
 //
@@ -523,50 +527,60 @@
 // Modulus:
 //
 template <class B>
-inline detail::expression<detail::modulus_immediates, number<B, et_on>, number<B, et_on> >
- operator % (const number<B, et_on>& a, const number<B, et_on>& b)
+inline typename enable_if_c<number_category<B>::value == number_kind_integer,
+ detail::expression<detail::modulus_immediates, number<B, et_on>, number<B, et_on> > >::type
+ operator % (const number<B, et_on>& a, const number<B, et_on>& b)
 {
    return detail::expression<detail::modulus_immediates, number<B, et_on>, number<B, et_on> >(a, b);
 }
 template <class B, class V>
-inline typename enable_if<is_compatible_arithmetic_type<V, number<B, et_on> >, detail::expression<detail::modulus_immediates, number<B, et_on>, V > >::type
+inline typename enable_if_c<is_compatible_arithmetic_type<V, number<B, et_on> >::value && (number_category<B>::value == number_kind_integer),
+ detail::expression<detail::modulus_immediates, number<B, et_on>, V > >::type
    operator % (const number<B, et_on>& a, const V& b)
 {
    return detail::expression<detail::modulus_immediates, number<B, et_on>, V >(a, b);
 }
 template <class V, class B>
-inline typename enable_if<is_compatible_arithmetic_type<V, number<B, et_on> >, detail::expression<detail::modulus_immediates, V, number<B, et_on> > >::type
- operator % (const V& a, const number<B, et_on>& b)
+inline typename enable_if_c<is_compatible_arithmetic_type<V, number<B, et_on> >::value && (number_category<B>::value == number_kind_integer),
+ detail::expression<detail::modulus_immediates, V, number<B, et_on> > >::type
+ operator % (const V& a, const number<B, et_on>& b)
 {
    return detail::expression<detail::modulus_immediates, V, number<B, et_on> >(a, b);
 }
 template <class B, class tag, class Arg1, class Arg2, class Arg3, class Arg4>
-inline detail::expression<detail::modulus, number<B, et_on>, detail::expression<tag, Arg1, Arg2, Arg3, Arg4> >
- operator % (const number<B, et_on>& a, const detail::expression<tag, Arg1, Arg2, Arg3, Arg4>& b)
+inline typename enable_if_c<number_category<B>::value == number_kind_integer,
+ detail::expression<detail::modulus, number<B, et_on>, detail::expression<tag, Arg1, Arg2, Arg3, Arg4> > >::type
+ operator % (const number<B, et_on>& a, const detail::expression<tag, Arg1, Arg2, Arg3, Arg4>& b)
 {
    return detail::expression<detail::modulus, number<B, et_on>, detail::expression<tag, Arg1, Arg2, Arg3, Arg4> >(a, b);
 }
 template <class tag, class Arg1, class Arg2, class Arg3, class Arg4, class B>
-inline detail::expression<detail::modulus, detail::expression<tag, Arg1, Arg2, Arg3, Arg4>, number<B, et_on> >
- operator % (const detail::expression<tag, Arg1, Arg2, Arg3, Arg4>& a, const number<B, et_on>& b)
+inline typename enable_if_c<number_category<B>::value == number_kind_integer,
+ detail::expression<detail::modulus, detail::expression<tag, Arg1, Arg2, Arg3, Arg4>, number<B, et_on> > >::type
+ operator % (const detail::expression<tag, Arg1, Arg2, Arg3, Arg4>& a, const number<B, et_on>& b)
 {
    return detail::expression<detail::modulus, detail::expression<tag, Arg1, Arg2, Arg3, Arg4>, number<B, et_on> >(a, b);
 }
 template <class tag, class Arg1, class Arg2, class Arg3, class Arg4, class tag2, class Arg1b, class Arg2b, class Arg3b, class Arg4b>
-inline detail::expression<detail::modulus, detail::expression<tag, Arg1, Arg2, Arg3, Arg4>, detail::expression<tag2, Arg1b, Arg2b, Arg3b, Arg4b> >
- operator % (const detail::expression<tag, Arg1, Arg2, Arg3, Arg4>& a, const detail::expression<tag2, Arg1b, Arg2b, Arg3b, Arg4b>& b)
+inline typename enable_if_c<number_category<typename detail::expression<tag, Arg1, Arg2, Arg3, Arg4>::result_type>::value == number_kind_integer,
+ detail::expression<detail::modulus, detail::expression<tag, Arg1, Arg2, Arg3, Arg4>, detail::expression<tag2, Arg1b, Arg2b, Arg3b, Arg4b> > >::type
+ operator % (const detail::expression<tag, Arg1, Arg2, Arg3, Arg4>& a, const detail::expression<tag2, Arg1b, Arg2b, Arg3b, Arg4b>& b)
 {
    return detail::expression<detail::modulus, detail::expression<tag, Arg1, Arg2, Arg3, Arg4>, detail::expression<tag2, Arg1b, Arg2b, Arg3b, Arg4b> >(a, b);
 }
 template <class tag, class Arg1, class Arg2, class Arg3, class Arg4, class V>
-inline typename enable_if<is_compatible_arithmetic_type<V, typename detail::expression<tag, Arg1, Arg2, Arg3, Arg4>::result_type>, detail::expression<detail::modulus, detail::expression<tag, Arg1, Arg2, Arg3, Arg4>, V > >::type
- operator % (const detail::expression<tag, Arg1, Arg2, Arg3, Arg4>& a, const V& b)
+inline typename enable_if_c<is_compatible_arithmetic_type<V, typename detail::expression<tag, Arg1, Arg2, Arg3, Arg4>::result_type>::value
+ && (number_category<typename detail::expression<tag, Arg1, Arg2, Arg3, Arg4>::result_type>::value == number_kind_integer),
+ detail::expression<detail::modulus, detail::expression<tag, Arg1, Arg2, Arg3, Arg4>, V > >::type
+ operator % (const detail::expression<tag, Arg1, Arg2, Arg3, Arg4>& a, const V& b)
 {
    return detail::expression<detail::modulus, detail::expression<tag, Arg1, Arg2, Arg3, Arg4>, V >(a, b);
 }
 template <class V, class tag, class Arg1, class Arg2, class Arg3, class Arg4>
-inline typename enable_if<is_compatible_arithmetic_type<V, typename detail::expression<tag, Arg1, Arg2, Arg3, Arg4>::result_type>, detail::expression<detail::modulus, V, detail::expression<tag, Arg1, Arg2, Arg3, Arg4> > >::type
- operator % (const V& a, const detail::expression<tag, Arg1, Arg2, Arg3, Arg4>& b)
+inline typename enable_if_c<is_compatible_arithmetic_type<V, typename detail::expression<tag, Arg1, Arg2, Arg3, Arg4>::result_type>::value
+ && (number_category<typename detail::expression<tag, Arg1, Arg2, Arg3, Arg4>::result_type>::value == number_kind_integer),
+ detail::expression<detail::modulus, V, detail::expression<tag, Arg1, Arg2, Arg3, Arg4> > >::type
+ operator % (const V& a, const detail::expression<tag, Arg1, Arg2, Arg3, Arg4>& b)
 {
    return detail::expression<detail::modulus, V, detail::expression<tag, Arg1, Arg2, Arg3, Arg4> >(a, b);
 }
@@ -574,14 +588,15 @@
 // Left shift:
 //
 template <class B, class I>
-inline typename enable_if<is_integral<I>, detail::expression<detail::shift_left, number<B, et_on>, I > >::type
+inline typename enable_if_c<is_integral<I>::value && (number_category<B>::value == number_kind_integer), detail::expression<detail::shift_left, number<B, et_on>, I > >::type
    operator << (const number<B, et_on>& a, const I& b)
 {
    return detail::expression<detail::shift_left, number<B, et_on>, I>(a, b);
 }
 template <class tag, class Arg1, class Arg2, class Arg3, class Arg4, class I>
-inline typename enable_if<is_integral<I>, detail::expression<detail::shift_left, detail::expression<tag, Arg1, Arg2, Arg3, Arg4>, I> >::type
- operator << (const detail::expression<tag, Arg1, Arg2, Arg3, Arg4>& a, const I& b)
+inline typename enable_if_c<is_integral<I>::value && (number_category<typename detail::expression<tag, Arg1, Arg2, Arg3, Arg4>::result_type>::value == number_kind_integer),
+ detail::expression<detail::shift_left, detail::expression<tag, Arg1, Arg2, Arg3, Arg4>, I> >::type
+ operator << (const detail::expression<tag, Arg1, Arg2, Arg3, Arg4>& a, const I& b)
 {
    return detail::expression<detail::shift_left, detail::expression<tag, Arg1, Arg2, Arg3, Arg4>, I>(a, b);
 }
@@ -589,14 +604,17 @@
 // Right shift:
 //
 template <class B, class I>
-inline typename enable_if<is_integral<I>, detail::expression<detail::shift_right, number<B, et_on>, I > >::type
- operator >> (const number<B, et_on>& a, const I& b)
+inline typename enable_if_c<is_integral<I>::value && (number_category<B>::value == number_kind_integer),
+ detail::expression<detail::shift_right, number<B, et_on>, I > >::type
+ operator >> (const number<B, et_on>& a, const I& b)
 {
    return detail::expression<detail::shift_right, number<B, et_on>, I>(a, b);
 }
 template <class tag, class Arg1, class Arg2, class Arg3, class Arg4, class I>
-inline typename enable_if<is_integral<I>, detail::expression<detail::shift_right, detail::expression<tag, Arg1, Arg2, Arg3, Arg4>, I> >::type
- operator >> (const detail::expression<tag, Arg1, Arg2, Arg3, Arg4>& a, const I& b)
+inline typename enable_if_c<is_integral<I>::value
+ && (number_category<typename detail::expression<tag, Arg1, Arg2, Arg3, Arg4>::result_type>::value == number_kind_integer),
+ detail::expression<detail::shift_right, detail::expression<tag, Arg1, Arg2, Arg3, Arg4>, I> >::type
+ operator >> (const detail::expression<tag, Arg1, Arg2, Arg3, Arg4>& a, const I& b)
 {
    return detail::expression<detail::shift_right, detail::expression<tag, Arg1, Arg2, Arg3, Arg4>, I>(a, b);
 }
@@ -604,50 +622,62 @@
 // Bitwise AND:
 //
 template <class B>
-inline detail::expression<detail::bitwise_and_immediates, number<B, et_on>, number<B, et_on> >
- operator & (const number<B, et_on>& a, const number<B, et_on>& b)
+inline typename enable_if_c<number_category<B>::value == number_kind_integer,
+ detail::expression<detail::bitwise_and_immediates, number<B, et_on>, number<B, et_on> > >::type
+ operator & (const number<B, et_on>& a, const number<B, et_on>& b)
 {
    return detail::expression<detail::bitwise_and_immediates, number<B, et_on>, number<B, et_on> >(a, b);
 }
 template <class B, class V>
-inline typename enable_if<is_compatible_arithmetic_type<V, number<B, et_on> >, detail::expression<detail::bitwise_and_immediates, number<B, et_on>, V > >::type
- operator & (const number<B, et_on>& a, const V& b)
+inline typename enable_if_c<is_compatible_arithmetic_type<V, number<B, et_on> >::value
+ && (number_category<B>::value == number_kind_integer),
+ detail::expression<detail::bitwise_and_immediates, number<B, et_on>, V > >::type
+ operator & (const number<B, et_on>& a, const V& b)
 {
    return detail::expression<detail::bitwise_and_immediates, number<B, et_on>, V >(a, b);
 }
 template <class V, class B>
-inline typename enable_if<is_compatible_arithmetic_type<V, number<B, et_on> >, detail::expression<detail::bitwise_and_immediates, V, number<B, et_on> > >::type
- operator & (const V& a, const number<B, et_on>& b)
+inline typename enable_if_c<is_compatible_arithmetic_type<V, number<B, et_on> >::value
+ && (number_category<B>::value == number_kind_integer),
+ detail::expression<detail::bitwise_and_immediates, V, number<B, et_on> > >::type
+ operator & (const V& a, const number<B, et_on>& b)
 {
    return detail::expression<detail::bitwise_and_immediates, V, number<B, et_on> >(a, b);
 }
 template <class B, class tag, class Arg1, class Arg2, class Arg3, class Arg4>
-inline detail::expression<detail::bitwise_and, number<B, et_on>, detail::expression<tag, Arg1, Arg2, Arg3, Arg4> >
- operator & (const number<B, et_on>& a, const detail::expression<tag, Arg1, Arg2, Arg3, Arg4>& b)
+inline typename enable_if_c<number_category<B>::value == number_kind_integer,
+ detail::expression<detail::bitwise_and, number<B, et_on>, detail::expression<tag, Arg1, Arg2, Arg3, Arg4> > >::type
+ operator & (const number<B, et_on>& a, const detail::expression<tag, Arg1, Arg2, Arg3, Arg4>& b)
 {
    return detail::expression<detail::bitwise_and, number<B, et_on>, detail::expression<tag, Arg1, Arg2, Arg3, Arg4> >(a, b);
 }
 template <class tag, class Arg1, class Arg2, class Arg3, class Arg4, class B>
-inline detail::expression<detail::bitwise_and, detail::expression<tag, Arg1, Arg2, Arg3, Arg4>, number<B, et_on> >
- operator & (const detail::expression<tag, Arg1, Arg2, Arg3, Arg4>& a, const number<B, et_on>& b)
+inline typename enable_if_c<number_category<B>::value == number_kind_integer,
+ detail::expression<detail::bitwise_and, detail::expression<tag, Arg1, Arg2, Arg3, Arg4>, number<B, et_on> > >::type
+ operator & (const detail::expression<tag, Arg1, Arg2, Arg3, Arg4>& a, const number<B, et_on>& b)
 {
    return detail::expression<detail::bitwise_and, detail::expression<tag, Arg1, Arg2, Arg3, Arg4>, number<B, et_on> >(a, b);
 }
 template <class tag, class Arg1, class Arg2, class Arg3, class Arg4, class tag2, class Arg1b, class Arg2b, class Arg3b, class Arg4b>
-inline detail::expression<detail::bitwise_and, detail::expression<tag, Arg1, Arg2, Arg3, Arg4>, detail::expression<tag2, Arg1b, Arg2b, Arg3b, Arg4b> >
- operator & (const detail::expression<tag, Arg1, Arg2, Arg3, Arg4>& a, const detail::expression<tag2, Arg1b, Arg2b, Arg3b, Arg4b>& b)
+inline typename enable_if_c<number_category<typename detail::expression<tag, Arg1, Arg2, Arg3, Arg4>::result_type>::value == number_kind_integer,
+ detail::expression<detail::bitwise_and, detail::expression<tag, Arg1, Arg2, Arg3, Arg4>, detail::expression<tag2, Arg1b, Arg2b, Arg3b, Arg4b> > >::type
+ operator & (const detail::expression<tag, Arg1, Arg2, Arg3, Arg4>& a, const detail::expression<tag2, Arg1b, Arg2b, Arg3b, Arg4b>& b)
 {
    return detail::expression<detail::bitwise_and, detail::expression<tag, Arg1, Arg2, Arg3, Arg4>, detail::expression<tag2, Arg1b, Arg2b, Arg3b, Arg4b> >(a, b);
 }
 template <class tag, class Arg1, class Arg2, class Arg3, class Arg4, class V>
-inline typename enable_if<is_compatible_arithmetic_type<V, typename detail::expression<tag, Arg1, Arg2, Arg3, Arg4>::result_type>, detail::expression<detail::bitwise_and, detail::expression<tag, Arg1, Arg2, Arg3, Arg4>, V > >::type
- operator & (const detail::expression<tag, Arg1, Arg2, Arg3, Arg4>& a, const V& b)
+inline typename enable_if_c<is_compatible_arithmetic_type<V, typename detail::expression<tag, Arg1, Arg2, Arg3, Arg4>::result_type>::value
+ && (number_category<typename detail::expression<tag, Arg1, Arg2, Arg3, Arg4>::result_type>::value == number_kind_integer),
+ detail::expression<detail::bitwise_and, detail::expression<tag, Arg1, Arg2, Arg3, Arg4>, V > >::type
+ operator & (const detail::expression<tag, Arg1, Arg2, Arg3, Arg4>& a, const V& b)
 {
    return detail::expression<detail::bitwise_and, detail::expression<tag, Arg1, Arg2, Arg3, Arg4>, V >(a, b);
 }
 template <class V, class tag, class Arg1, class Arg2, class Arg3, class Arg4>
-inline typename enable_if<is_compatible_arithmetic_type<V, typename detail::expression<tag, Arg1, Arg2, Arg3, Arg4>::result_type>, detail::expression<detail::bitwise_and, V, detail::expression<tag, Arg1, Arg2, Arg3, Arg4> > >::type
- operator & (const V& a, const detail::expression<tag, Arg1, Arg2, Arg3, Arg4>& b)
+inline typename enable_if_c<is_compatible_arithmetic_type<V, typename detail::expression<tag, Arg1, Arg2, Arg3, Arg4>::result_type>::value
+ && (number_category<typename detail::expression<tag, Arg1, Arg2, Arg3, Arg4>::result_type>::value == number_kind_integer),
+ detail::expression<detail::bitwise_and, V, detail::expression<tag, Arg1, Arg2, Arg3, Arg4> > >::type
+ operator & (const V& a, const detail::expression<tag, Arg1, Arg2, Arg3, Arg4>& b)
 {
    return detail::expression<detail::bitwise_and, V, detail::expression<tag, Arg1, Arg2, Arg3, Arg4> >(a, b);
 }
@@ -655,50 +685,62 @@
 // Bitwise OR:
 //
 template <class B>
-inline detail::expression<detail::bitwise_or_immediates, number<B, et_on>, number<B, et_on> >
+inline typename enable_if_c<number_category<B>::value == number_kind_integer,
+ detail::expression<detail::bitwise_or_immediates, number<B, et_on>, number<B, et_on> > >::type
    operator| (const number<B, et_on>& a, const number<B, et_on>& b)
 {
    return detail::expression<detail::bitwise_or_immediates, number<B, et_on>, number<B, et_on> >(a, b);
 }
 template <class B, class V>
-inline typename enable_if<is_compatible_arithmetic_type<V, number<B, et_on> >, detail::expression<detail::bitwise_or_immediates, number<B, et_on>, V > >::type
- operator| (const number<B, et_on>& a, const V& b)
+inline typename enable_if_c<is_compatible_arithmetic_type<V, number<B, et_on> >::value
+ && (number_category<B>::value == number_kind_integer),
+ detail::expression<detail::bitwise_or_immediates, number<B, et_on>, V > >::type
+ operator| (const number<B, et_on>& a, const V& b)
 {
    return detail::expression<detail::bitwise_or_immediates, number<B, et_on>, V >(a, b);
 }
 template <class V, class B>
-inline typename enable_if<is_compatible_arithmetic_type<V, number<B, et_on> >, detail::expression<detail::bitwise_or_immediates, V, number<B, et_on> > >::type
- operator| (const V& a, const number<B, et_on>& b)
+inline typename enable_if_c<is_compatible_arithmetic_type<V, number<B, et_on> >::value
+ && (number_category<B>::value == number_kind_integer),
+ detail::expression<detail::bitwise_or_immediates, V, number<B, et_on> > >::type
+ operator| (const V& a, const number<B, et_on>& b)
 {
    return detail::expression<detail::bitwise_or_immediates, V, number<B, et_on> >(a, b);
 }
 template <class B, class tag, class Arg1, class Arg2, class Arg3, class Arg4>
-inline detail::expression<detail::bitwise_or, number<B, et_on>, detail::expression<tag, Arg1, Arg2, Arg3, Arg4> >
- operator| (const number<B, et_on>& a, const detail::expression<tag, Arg1, Arg2, Arg3, Arg4>& b)
+inline typename enable_if_c<number_category<B>::value == number_kind_integer,
+ detail::expression<detail::bitwise_or, number<B, et_on>, detail::expression<tag, Arg1, Arg2, Arg3, Arg4> > >::type
+ operator| (const number<B, et_on>& a, const detail::expression<tag, Arg1, Arg2, Arg3, Arg4>& b)
 {
    return detail::expression<detail::bitwise_or, number<B, et_on>, detail::expression<tag, Arg1, Arg2, Arg3, Arg4> >(a, b);
 }
 template <class tag, class Arg1, class Arg2, class Arg3, class Arg4, class B>
-inline detail::expression<detail::bitwise_or, detail::expression<tag, Arg1, Arg2, Arg3, Arg4>, number<B, et_on> >
- operator| (const detail::expression<tag, Arg1, Arg2, Arg3, Arg4>& a, const number<B, et_on>& b)
+inline typename enable_if_c<number_category<B>::value == number_kind_integer,
+ detail::expression<detail::bitwise_or, detail::expression<tag, Arg1, Arg2, Arg3, Arg4>, number<B, et_on> > >::type
+ operator| (const detail::expression<tag, Arg1, Arg2, Arg3, Arg4>& a, const number<B, et_on>& b)
 {
    return detail::expression<detail::bitwise_or, detail::expression<tag, Arg1, Arg2, Arg3, Arg4>, number<B, et_on> >(a, b);
 }
 template <class tag, class Arg1, class Arg2, class Arg3, class Arg4, class tag2, class Arg1b, class Arg2b, class Arg3b, class Arg4b>
-inline detail::expression<detail::bitwise_or, detail::expression<tag, Arg1, Arg2, Arg3, Arg4>, detail::expression<tag2, Arg1b, Arg2b, Arg3b, Arg4b> >
- operator| (const detail::expression<tag, Arg1, Arg2, Arg3, Arg4>& a, const detail::expression<tag2, Arg1b, Arg2b, Arg3b, Arg4b>& b)
+inline typename enable_if_c<number_category<typename detail::expression<tag, Arg1, Arg2, Arg3, Arg4>::result_type>::value == number_kind_integer,
+ detail::expression<detail::bitwise_or, detail::expression<tag, Arg1, Arg2, Arg3, Arg4>, detail::expression<tag2, Arg1b, Arg2b, Arg3b, Arg4b> > >::type
+ operator| (const detail::expression<tag, Arg1, Arg2, Arg3, Arg4>& a, const detail::expression<tag2, Arg1b, Arg2b, Arg3b, Arg4b>& b)
 {
    return detail::expression<detail::bitwise_or, detail::expression<tag, Arg1, Arg2, Arg3, Arg4>, detail::expression<tag2, Arg1b, Arg2b, Arg3b, Arg4b> >(a, b);
 }
 template <class tag, class Arg1, class Arg2, class Arg3, class Arg4, class V>
-inline typename enable_if<is_compatible_arithmetic_type<V, typename detail::expression<tag, Arg1, Arg2, Arg3, Arg4>::result_type>, detail::expression<detail::bitwise_or, detail::expression<tag, Arg1, Arg2, Arg3, Arg4>, V > >::type
- operator| (const detail::expression<tag, Arg1, Arg2, Arg3, Arg4>& a, const V& b)
+inline typename enable_if_c<is_compatible_arithmetic_type<V, typename detail::expression<tag, Arg1, Arg2, Arg3, Arg4>::result_type>::value
+ && (number_category<typename detail::expression<tag, Arg1, Arg2, Arg3, Arg4>::result_type>::value == number_kind_integer),
+ detail::expression<detail::bitwise_or, detail::expression<tag, Arg1, Arg2, Arg3, Arg4>, V > >::type
+ operator| (const detail::expression<tag, Arg1, Arg2, Arg3, Arg4>& a, const V& b)
 {
    return detail::expression<detail::bitwise_or, detail::expression<tag, Arg1, Arg2, Arg3, Arg4>, V >(a, b);
 }
 template <class V, class tag, class Arg1, class Arg2, class Arg3, class Arg4>
-inline typename enable_if<is_compatible_arithmetic_type<V, typename detail::expression<tag, Arg1, Arg2, Arg3, Arg4>::result_type>, detail::expression<detail::bitwise_or, V, detail::expression<tag, Arg1, Arg2, Arg3, Arg4> > >::type
- operator| (const V& a, const detail::expression<tag, Arg1, Arg2, Arg3, Arg4>& b)
+inline typename enable_if_c<is_compatible_arithmetic_type<V, typename detail::expression<tag, Arg1, Arg2, Arg3, Arg4>::result_type>::value
+ && (number_category<typename detail::expression<tag, Arg1, Arg2, Arg3, Arg4>::result_type>::value == number_kind_integer),
+ detail::expression<detail::bitwise_or, V, detail::expression<tag, Arg1, Arg2, Arg3, Arg4> > >::type
+ operator| (const V& a, const detail::expression<tag, Arg1, Arg2, Arg3, Arg4>& b)
 {
    return detail::expression<detail::bitwise_or, V, detail::expression<tag, Arg1, Arg2, Arg3, Arg4> >(a, b);
 }
@@ -706,49 +748,60 @@
 // Bitwise XOR:
 //
 template <class B>
-inline detail::expression<detail::bitwise_xor_immediates, number<B, et_on>, number<B, et_on> >
- operator^ (const number<B, et_on>& a, const number<B, et_on>& b)
+inline typename enable_if_c<number_category<B>::value == number_kind_integer,
+ detail::expression<detail::bitwise_xor_immediates, number<B, et_on>, number<B, et_on> > >::type
+ operator^ (const number<B, et_on>& a, const number<B, et_on>& b)
 {
    return detail::expression<detail::bitwise_xor_immediates, number<B, et_on>, number<B, et_on> >(a, b);
 }
 template <class B, class V>
-inline typename enable_if<is_compatible_arithmetic_type<V, number<B, et_on> >, detail::expression<detail::bitwise_xor_immediates, number<B, et_on>, V > >::type
- operator^ (const number<B, et_on>& a, const V& b)
+inline typename enable_if_c<is_compatible_arithmetic_type<V, number<B, et_on> >::value
+ && (number_category<B>::value == number_kind_integer),
+ detail::expression<detail::bitwise_xor_immediates, number<B, et_on>, V > >::type
+ operator^ (const number<B, et_on>& a, const V& b)
 {
    return detail::expression<detail::bitwise_xor_immediates, number<B, et_on>, V >(a, b);
 }
 template <class V, class B>
-inline typename enable_if<is_compatible_arithmetic_type<V, number<B, et_on> >, detail::expression<detail::bitwise_xor_immediates, V, number<B, et_on> > >::type
- operator^ (const V& a, const number<B, et_on>& b)
+inline typename enable_if_c<is_compatible_arithmetic_type<V, number<B, et_on> >::value
+ && (number_category<B>::value == number_kind_integer),
+ detail::expression<detail::bitwise_xor_immediates, V, number<B, et_on> > >::type
+ operator^ (const V& a, const number<B, et_on>& b)
 {
    return detail::expression<detail::bitwise_xor_immediates, V, number<B, et_on> >(a, b);
 }
 template <class B, class tag, class Arg1, class Arg2, class Arg3, class Arg4>
-inline detail::expression<detail::bitwise_xor, number<B, et_on>, detail::expression<tag, Arg1, Arg2, Arg3, Arg4> >
- operator^ (const number<B, et_on>& a, const detail::expression<tag, Arg1, Arg2, Arg3, Arg4>& b)
+inline typename enable_if_c<number_category<B>::value == number_kind_integer,
+ detail::expression<detail::bitwise_xor, number<B, et_on>, detail::expression<tag, Arg1, Arg2, Arg3, Arg4> > >::type
+ operator^ (const number<B, et_on>& a, const detail::expression<tag, Arg1, Arg2, Arg3, Arg4>& b)
 {
    return detail::expression<detail::bitwise_xor, number<B, et_on>, detail::expression<tag, Arg1, Arg2, Arg3, Arg4> >(a, b);
 }
 template <class tag, class Arg1, class Arg2, class Arg3, class Arg4, class B>
-inline detail::expression<detail::bitwise_xor, detail::expression<tag, Arg1, Arg2, Arg3, Arg4>, number<B, et_on> >
- operator^ (const detail::expression<tag, Arg1, Arg2, Arg3, Arg4>& a, const number<B, et_on>& b)
+inline typename enable_if_c<number_category<B>::value == number_kind_integer,
+ detail::expression<detail::bitwise_xor, detail::expression<tag, Arg1, Arg2, Arg3, Arg4>, number<B, et_on> > >::type
+ operator^ (const detail::expression<tag, Arg1, Arg2, Arg3, Arg4>& a, const number<B, et_on>& b)
 {
    return detail::expression<detail::bitwise_xor, detail::expression<tag, Arg1, Arg2, Arg3, Arg4>, number<B, et_on> >(a, b);
 }
 template <class tag, class Arg1, class Arg2, class Arg3, class Arg4, class tag2, class Arg1b, class Arg2b, class Arg3b, class Arg4b>
-inline detail::expression<detail::bitwise_xor, detail::expression<tag, Arg1, Arg2, Arg3, Arg4>, detail::expression<tag2, Arg1b, Arg2b, Arg3b, Arg4b> >
- operator^ (const detail::expression<tag, Arg1, Arg2, Arg3, Arg4>& a, const detail::expression<tag2, Arg1b, Arg2b, Arg3b, Arg4b>& b)
+inline typename enable_if_c<number_category<typename detail::expression<tag, Arg1, Arg2, Arg3, Arg4>::result_type>::value == number_kind_integer,
+ detail::expression<detail::bitwise_xor, detail::expression<tag, Arg1, Arg2, Arg3, Arg4>, detail::expression<tag2, Arg1b, Arg2b, Arg3b, Arg4b> > >::type
+ operator^ (const detail::expression<tag, Arg1, Arg2, Arg3, Arg4>& a, const detail::expression<tag2, Arg1b, Arg2b, Arg3b, Arg4b>& b)
 {
    return detail::expression<detail::bitwise_xor, detail::expression<tag, Arg1, Arg2, Arg3, Arg4>, detail::expression<tag2, Arg1b, Arg2b, Arg3b, Arg4b> >(a, b);
 }
 template <class tag, class Arg1, class Arg2, class Arg3, class Arg4, class V>
-inline typename enable_if<is_compatible_arithmetic_type<V, typename detail::expression<tag, Arg1, Arg2, Arg3, Arg4>::result_type>, detail::expression<detail::bitwise_xor, detail::expression<tag, Arg1, Arg2, Arg3, Arg4>, V > >::type
- operator^ (const detail::expression<tag, Arg1, Arg2, Arg3, Arg4>& a, const V& b)
+inline typename enable_if_c<is_compatible_arithmetic_type<V, typename detail::expression<tag, Arg1, Arg2, Arg3, Arg4>::result_type>::value
+ && (number_category<typename detail::expression<tag, Arg1, Arg2, Arg3, Arg4>::result_type>::value == number_kind_integer),
+ detail::expression<detail::bitwise_xor, detail::expression<tag, Arg1, Arg2, Arg3, Arg4>, V > >::type
+ operator^ (const detail::expression<tag, Arg1, Arg2, Arg3, Arg4>& a, const V& b)
 {
    return detail::expression<detail::bitwise_xor, detail::expression<tag, Arg1, Arg2, Arg3, Arg4>, V >(a, b);
 }
 template <class V, class tag, class Arg1, class Arg2, class Arg3, class Arg4>
-inline typename enable_if<is_compatible_arithmetic_type<V, typename detail::expression<tag, Arg1, Arg2, Arg3, Arg4>::result_type>, detail::expression<detail::bitwise_xor, V, detail::expression<tag, Arg1, Arg2, Arg3, Arg4> > >::type
+inline typename enable_if_c<is_compatible_arithmetic_type<V, typename detail::expression<tag, Arg1, Arg2, Arg3, Arg4>::result_type>::value
+ && (number_category<typename detail::expression<tag, Arg1, Arg2, Arg3, Arg4>::result_type>::value == number_kind_integer), detail::expression<detail::bitwise_xor, V, detail::expression<tag, Arg1, Arg2, Arg3, Arg4> > >::type
    operator^ (const V& a, const detail::expression<tag, Arg1, Arg2, Arg3, Arg4>& b)
 {
    return detail::expression<detail::bitwise_xor, V, detail::expression<tag, Arg1, Arg2, Arg3, Arg4> >(a, b);

Modified: trunk/boost/multiprecision/detail/no_et_ops.hpp
==============================================================================
--- trunk/boost/multiprecision/detail/no_et_ops.hpp (original)
+++ trunk/boost/multiprecision/detail/no_et_ops.hpp 2013-04-26 04:17:12 EDT (Fri, 26 Apr 2013)
@@ -154,7 +154,7 @@
 // modulus:
 //
 template <class B>
-BOOST_MP_FORCEINLINE number<B, et_off> operator % (const number<B, et_off>& a, const number<B, et_off>& b)
+BOOST_MP_FORCEINLINE typename enable_if_c<number_category<B>::value == number_kind_integer, number<B, et_off> >::type operator % (const number<B, et_off>& a, const number<B, et_off>& b)
 {
    number<B, et_off> result;
    using default_ops::eval_modulus;
@@ -162,7 +162,7 @@
    return BOOST_MP_MOVE(result);
 }
 template <class B, class V>
-BOOST_MP_FORCEINLINE typename enable_if<is_compatible_arithmetic_type<V, number<B, et_off> >, number<B, et_off> >::type
+BOOST_MP_FORCEINLINE typename enable_if_c<is_compatible_arithmetic_type<V, number<B, et_off> >::value && (number_category<B>::value == number_kind_integer), number<B, et_off> >::type
    operator % (const number<B, et_off>& a, const V& b)
 {
    number<B, et_off> result;
@@ -171,7 +171,7 @@
    return BOOST_MP_MOVE(result);
 }
 template <class V, class B>
-BOOST_MP_FORCEINLINE typename enable_if<is_compatible_arithmetic_type<V, number<B, et_off> >, number<B, et_off> >::type
+BOOST_MP_FORCEINLINE typename enable_if_c<is_compatible_arithmetic_type<V, number<B, et_off> >::value && (number_category<B>::value == number_kind_integer), number<B, et_off> >::type
    operator % (const V& a, const number<B, et_off>& b)
 {
    number<B, et_off> result;
@@ -183,7 +183,7 @@
 // Bitwise or:
 //
 template <class B>
-BOOST_MP_FORCEINLINE number<B, et_off> operator | (const number<B, et_off>& a, const number<B, et_off>& b)
+BOOST_MP_FORCEINLINE typename enable_if_c<number_category<B>::value == number_kind_integer, number<B, et_off> >::type operator | (const number<B, et_off>& a, const number<B, et_off>& b)
 {
    number<B, et_off> result;
    using default_ops::eval_bitwise_or;
@@ -191,7 +191,7 @@
    return BOOST_MP_MOVE(result);
 }
 template <class B, class V>
-BOOST_MP_FORCEINLINE typename enable_if<is_compatible_arithmetic_type<V, number<B, et_off> >, number<B, et_off> >::type
+BOOST_MP_FORCEINLINE typename enable_if_c<is_compatible_arithmetic_type<V, number<B, et_off> >::value && (number_category<B>::value == number_kind_integer), number<B, et_off> >::type
    operator | (const number<B, et_off>& a, const V& b)
 {
    number<B, et_off> result;
@@ -200,7 +200,7 @@
    return BOOST_MP_MOVE(result);
 }
 template <class V, class B>
-BOOST_MP_FORCEINLINE typename enable_if<is_compatible_arithmetic_type<V, number<B, et_off> >, number<B, et_off> >::type
+BOOST_MP_FORCEINLINE typename enable_if_c<is_compatible_arithmetic_type<V, number<B, et_off> >::value && (number_category<B>::value == number_kind_integer), number<B, et_off> >::type
    operator | (const V& a, const number<B, et_off>& b)
 {
    number<B, et_off> result;
@@ -212,7 +212,7 @@
 // Bitwise xor:
 //
 template <class B>
-BOOST_MP_FORCEINLINE number<B, et_off> operator ^ (const number<B, et_off>& a, const number<B, et_off>& b)
+BOOST_MP_FORCEINLINE typename enable_if_c<number_category<B>::value == number_kind_integer, number<B, et_off> >::type operator ^ (const number<B, et_off>& a, const number<B, et_off>& b)
 {
    number<B, et_off> result;
    using default_ops::eval_bitwise_xor;
@@ -220,7 +220,7 @@
    return BOOST_MP_MOVE(result);
 }
 template <class B, class V>
-BOOST_MP_FORCEINLINE typename enable_if<is_compatible_arithmetic_type<V, number<B, et_off> >, number<B, et_off> >::type
+BOOST_MP_FORCEINLINE typename enable_if_c<is_compatible_arithmetic_type<V, number<B, et_off> >::value && (number_category<B>::value == number_kind_integer), number<B, et_off> >::type
    operator ^ (const number<B, et_off>& a, const V& b)
 {
    number<B, et_off> result;
@@ -229,7 +229,7 @@
    return BOOST_MP_MOVE(result);
 }
 template <class V, class B>
-BOOST_MP_FORCEINLINE typename enable_if<is_compatible_arithmetic_type<V, number<B, et_off> >, number<B, et_off> >::type
+BOOST_MP_FORCEINLINE typename enable_if_c<is_compatible_arithmetic_type<V, number<B, et_off> >::value && (number_category<B>::value == number_kind_integer), number<B, et_off> >::type
    operator ^ (const V& a, const number<B, et_off>& b)
 {
    number<B, et_off> result;
@@ -241,7 +241,7 @@
 // Bitwise and:
 //
 template <class B>
-BOOST_MP_FORCEINLINE number<B, et_off> operator & (const number<B, et_off>& a, const number<B, et_off>& b)
+BOOST_MP_FORCEINLINE typename enable_if_c<number_category<B>::value == number_kind_integer, number<B, et_off> >::type operator & (const number<B, et_off>& a, const number<B, et_off>& b)
 {
    number<B, et_off> result;
    using default_ops::eval_bitwise_and;
@@ -249,7 +249,7 @@
    return BOOST_MP_MOVE(result);
 }
 template <class B, class V>
-BOOST_MP_FORCEINLINE typename enable_if<is_compatible_arithmetic_type<V, number<B, et_off> >, number<B, et_off> >::type
+BOOST_MP_FORCEINLINE typename enable_if_c<is_compatible_arithmetic_type<V, number<B, et_off> >::value && (number_category<B>::value == number_kind_integer), number<B, et_off> >::type
    operator & (const number<B, et_off>& a, const V& b)
 {
    number<B, et_off> result;
@@ -258,7 +258,7 @@
    return BOOST_MP_MOVE(result);
 }
 template <class V, class B>
-BOOST_MP_FORCEINLINE typename enable_if<is_compatible_arithmetic_type<V, number<B, et_off> >, number<B, et_off> >::type
+BOOST_MP_FORCEINLINE typename enable_if_c<is_compatible_arithmetic_type<V, number<B, et_off> >::value && (number_category<B>::value == number_kind_integer), number<B, et_off> >::type
    operator & (const V& a, const number<B, et_off>& b)
 {
    number<B, et_off> result;
@@ -270,7 +270,7 @@
 // shifts:
 //
 template <class B, class I>
-BOOST_MP_FORCEINLINE typename enable_if<is_integral<I>, number<B, et_off> >::type
+BOOST_MP_FORCEINLINE typename enable_if_c<is_integral<I>::value && (number_category<B>::value == number_kind_integer), number<B, et_off> >::type
    operator << (const number<B, et_off>& a, const I& b)
 {
    number<B, et_off> result(a);
@@ -280,7 +280,7 @@
    return BOOST_MP_MOVE(result);
 }
 template <class B, class I>
-BOOST_MP_FORCEINLINE typename enable_if<is_integral<I>, number<B, et_off> >::type
+BOOST_MP_FORCEINLINE typename enable_if_c<is_integral<I>::value && (number_category<B>::value == number_kind_integer), number<B, et_off> >::type
    operator >> (const number<B, et_off>& a, const I& b)
 {
    number<B, et_off> result(a);
@@ -310,7 +310,7 @@
    return static_cast<number<B, et_off>&&>(v);
 }
 template <class B>
-BOOST_MP_FORCEINLINE number<B, et_off> operator ~ (number<B, et_off>&& v)
+BOOST_MP_FORCEINLINE typename enable_if_c<number_category<B>::value == number_kind_integer, number<B, et_off> >::type operator ~ (number<B, et_off>&& v)
 {
    eval_complement(v.backend(), v.backend());
    return static_cast<number<B, et_off>&&>(v);
@@ -459,14 +459,14 @@
 // modulus:
 //
 template <class B>
-BOOST_MP_FORCEINLINE number<B, et_off> operator % (number<B, et_off>&& a, const number<B, et_off>& b)
+BOOST_MP_FORCEINLINE typename enable_if_c<number_category<B>::value == number_kind_integer, number<B, et_off> >::type operator % (number<B, et_off>&& a, const number<B, et_off>& b)
 {
    using default_ops::eval_modulus;
    eval_modulus(a.backend(), b.backend());
    return static_cast<number<B, et_off>&&>(a);
 }
 template <class B, class V>
-BOOST_MP_FORCEINLINE typename enable_if<is_compatible_arithmetic_type<V, number<B, et_off> >, number<B, et_off> >::type
+BOOST_MP_FORCEINLINE typename enable_if_c<is_compatible_arithmetic_type<V, number<B, et_off> >::value && (number_category<B>::value == number_kind_integer), number<B, et_off> >::type
    operator % (number<B, et_off>&& a, const V& b)
 {
    using default_ops::eval_modulus;
@@ -477,28 +477,28 @@
 // Bitwise or:
 //
 template <class B>
-BOOST_MP_FORCEINLINE number<B, et_off> operator | (number<B, et_off>&& a, const number<B, et_off>& b)
+BOOST_MP_FORCEINLINE typename enable_if_c<number_category<B>::value == number_kind_integer, number<B, et_off> >::type operator | (number<B, et_off>&& a, const number<B, et_off>& b)
 {
    using default_ops::eval_bitwise_or;
    eval_bitwise_or(a.backend(), b.backend());
    return static_cast<number<B, et_off>&&>(a);
 }
 template <class B>
-BOOST_MP_FORCEINLINE number<B, et_off> operator | (const number<B, et_off>& a, number<B, et_off>&& b)
+BOOST_MP_FORCEINLINE typename enable_if_c<number_category<B>::value == number_kind_integer, number<B, et_off> >::type operator | (const number<B, et_off>& a, number<B, et_off>&& b)
 {
    using default_ops::eval_bitwise_or;
    eval_bitwise_or(b.backend(), a.backend());
    return static_cast<number<B, et_off>&&>(b);
 }
 template <class B>
-BOOST_MP_FORCEINLINE number<B, et_off> operator | (number<B, et_off>&& a, number<B, et_off>&& b)
+BOOST_MP_FORCEINLINE typename enable_if_c<number_category<B>::value == number_kind_integer, number<B, et_off> >::type operator | (number<B, et_off>&& a, number<B, et_off>&& b)
 {
    using default_ops::eval_bitwise_or;
    eval_bitwise_or(a.backend(), b.backend());
    return static_cast<number<B, et_off>&&>(a);
 }
 template <class B, class V>
-BOOST_MP_FORCEINLINE typename enable_if<is_compatible_arithmetic_type<V, number<B, et_off> >, number<B, et_off> >::type
+BOOST_MP_FORCEINLINE typename enable_if_c<is_compatible_arithmetic_type<V, number<B, et_off> >::value && (number_category<B>::value == number_kind_integer), number<B, et_off> >::type
    operator | (number<B, et_off>&& a, const V& b)
 {
    using default_ops::eval_bitwise_or;
@@ -506,7 +506,7 @@
    return static_cast<number<B, et_off>&&>(a);
 }
 template <class V, class B>
-BOOST_MP_FORCEINLINE typename enable_if<is_compatible_arithmetic_type<V, number<B, et_off> >, number<B, et_off> >::type
+BOOST_MP_FORCEINLINE typename enable_if_c<is_compatible_arithmetic_type<V, number<B, et_off> >::value && (number_category<B>::value == number_kind_integer), number<B, et_off> >::type
    operator | (const V& a, number<B, et_off>&& b)
 {
    using default_ops::eval_bitwise_or;
@@ -517,28 +517,28 @@
 // Bitwise xor:
 //
 template <class B>
-BOOST_MP_FORCEINLINE number<B, et_off> operator ^ (number<B, et_off>&& a, const number<B, et_off>& b)
+BOOST_MP_FORCEINLINE typename enable_if_c<number_category<B>::value == number_kind_integer, number<B, et_off> >::type operator ^ (number<B, et_off>&& a, const number<B, et_off>& b)
 {
    using default_ops::eval_bitwise_xor;
    eval_bitwise_xor(a.backend(), b.backend());
    return static_cast<number<B, et_off>&&>(a);
 }
 template <class B>
-BOOST_MP_FORCEINLINE number<B, et_off> operator ^ (const number<B, et_off>& a, number<B, et_off>&& b)
+BOOST_MP_FORCEINLINE typename enable_if_c<number_category<B>::value == number_kind_integer, number<B, et_off> >::type operator ^ (const number<B, et_off>& a, number<B, et_off>&& b)
 {
    using default_ops::eval_bitwise_xor;
    eval_bitwise_xor(b.backend(), a.backend());
    return static_cast<number<B, et_off>&&>(b);
 }
 template <class B>
-BOOST_MP_FORCEINLINE number<B, et_off> operator ^ (number<B, et_off>&& a, number<B, et_off>&& b)
+BOOST_MP_FORCEINLINE typename enable_if_c<number_category<B>::value == number_kind_integer, number<B, et_off> >::type operator ^ (number<B, et_off>&& a, number<B, et_off>&& b)
 {
    using default_ops::eval_bitwise_xor;
    eval_bitwise_xor(a.backend(), b.backend());
    return static_cast<number<B, et_off>&&>(a);
 }
 template <class B, class V>
-BOOST_MP_FORCEINLINE typename enable_if<is_compatible_arithmetic_type<V, number<B, et_off> >, number<B, et_off> >::type
+BOOST_MP_FORCEINLINE typename enable_if_c<is_compatible_arithmetic_type<V, number<B, et_off> >::value && (number_category<B>::value == number_kind_integer), number<B, et_off> >::type
    operator ^ (number<B, et_off>&& a, const V& b)
 {
    using default_ops::eval_bitwise_xor;
@@ -546,7 +546,7 @@
    return static_cast<number<B, et_off>&&>(a);
 }
 template <class V, class B>
-BOOST_MP_FORCEINLINE typename enable_if<is_compatible_arithmetic_type<V, number<B, et_off> >, number<B, et_off> >::type
+BOOST_MP_FORCEINLINE typename enable_if_c<is_compatible_arithmetic_type<V, number<B, et_off> >::value && (number_category<B>::value == number_kind_integer), number<B, et_off> >::type
    operator ^ (const V& a, number<B, et_off>&& b)
 {
    using default_ops::eval_bitwise_xor;
@@ -557,28 +557,28 @@
 // Bitwise and:
 //
 template <class B>
-BOOST_MP_FORCEINLINE number<B, et_off> operator & (number<B, et_off>&& a, const number<B, et_off>& b)
+BOOST_MP_FORCEINLINE typename enable_if_c<number_category<B>::value == number_kind_integer, number<B, et_off> >::type operator & (number<B, et_off>&& a, const number<B, et_off>& b)
 {
    using default_ops::eval_bitwise_and;
    eval_bitwise_and(a.backend(), b.backend());
    return static_cast<number<B, et_off>&&>(a);
 }
 template <class B>
-BOOST_MP_FORCEINLINE number<B, et_off> operator & (const number<B, et_off>& a, number<B, et_off>&& b)
+BOOST_MP_FORCEINLINE typename enable_if_c<number_category<B>::value == number_kind_integer, number<B, et_off> >::type operator & (const number<B, et_off>& a, number<B, et_off>&& b)
 {
    using default_ops::eval_bitwise_and;
    eval_bitwise_and(b.backend(), a.backend());
    return static_cast<number<B, et_off>&&>(b);
 }
 template <class B>
-BOOST_MP_FORCEINLINE number<B, et_off> operator & (number<B, et_off>&& a, number<B, et_off>&& b)
+BOOST_MP_FORCEINLINE typename enable_if_c<number_category<B>::value == number_kind_integer, number<B, et_off> >::type operator & (number<B, et_off>&& a, number<B, et_off>&& b)
 {
    using default_ops::eval_bitwise_and;
    eval_bitwise_and(a.backend(), b.backend());
    return static_cast<number<B, et_off>&&>(a);
 }
 template <class B, class V>
-BOOST_MP_FORCEINLINE typename enable_if<is_compatible_arithmetic_type<V, number<B, et_off> >, number<B, et_off> >::type
+BOOST_MP_FORCEINLINE typename enable_if_c<is_compatible_arithmetic_type<V, number<B, et_off> >::value && (number_category<B>::value == number_kind_integer), number<B, et_off> >::type
    operator & (number<B, et_off>&& a, const V& b)
 {
    using default_ops::eval_bitwise_and;
@@ -586,7 +586,7 @@
    return static_cast<number<B, et_off>&&>(a);
 }
 template <class V, class B>
-BOOST_MP_FORCEINLINE typename enable_if<is_compatible_arithmetic_type<V, number<B, et_off> >, number<B, et_off> >::type
+BOOST_MP_FORCEINLINE typename enable_if_c<is_compatible_arithmetic_type<V, number<B, et_off> >::value && (number_category<B>::value == number_kind_integer), number<B, et_off> >::type
    operator & (const V& a, number<B, et_off>&& b)
 {
    using default_ops::eval_bitwise_and;
@@ -597,7 +597,7 @@
 // shifts:
 //
 template <class B, class I>
-BOOST_MP_FORCEINLINE typename enable_if<is_integral<I>, number<B, et_off> >::type
+BOOST_MP_FORCEINLINE typename enable_if_c<is_integral<I>::value && (number_category<B>::value == number_kind_integer), number<B, et_off> >::type
    operator << (number<B, et_off>&& a, const I& b)
 {
    using default_ops::eval_left_shift;
@@ -605,7 +605,7 @@
    return static_cast<number<B, et_off>&&>(a);
 }
 template <class B, class I>
-BOOST_MP_FORCEINLINE typename enable_if<is_integral<I>, number<B, et_off> >::type
+BOOST_MP_FORCEINLINE typename enable_if_c<is_integral<I>::value && (number_category<B>::value == number_kind_integer), number<B, et_off> >::type
    operator >> (number<B, et_off>&& a, const I& b)
 {
    using default_ops::eval_right_shift;

Modified: trunk/libs/multiprecision/test/coverage/Makefile
==============================================================================
--- trunk/libs/multiprecision/test/coverage/Makefile (original)
+++ trunk/libs/multiprecision/test/coverage/Makefile 2013-04-26 04:17:12 EDT (Fri, 26 Apr 2013)
@@ -18,9 +18,7 @@
 ../../../../boost/multiprecision/detail/big_lanczos.hpp\
 ../../../../boost/multiprecision/detail/digits.hpp\
 ../../../../boost/multiprecision/detail/no_et_ops.hpp\
-../../../../boost/multiprecision/detail/cpp_int_core.hpp\
 ../../../../boost/multiprecision/detail/number_base.hpp\
-../../../../boost/multiprecision/detail/cpp_int_trivial_ops.hpp\
 ../../../../boost/multiprecision/detail/generic_interconvert.hpp\
 ../../../../boost/multiprecision/detail/number_compare.hpp\
 ../../../../boost/multiprecision/detail/default_ops.hpp\
@@ -32,70 +30,181 @@
 ../../../../boost/multiprecision/traits/is_restricted_conversion.hpp
 
 coverage : run
- gcov test_arithmetic_cpp_int_1 test_arithmetic_cpp_int_2 test_arithmetic_cpp_int_3 test_arithmetic_cpp_dec_float test_arithmetic_concept test_arithmetic_mpz test_arithmetic_mpf test_arithmetic_mpf_50 test_arithmetic_mpq test_arithmetic_mpfr test_arithmetic_mpfr_50 test_cpp_int test_int_io test_float_io test_rational_io test_gmp_conversions test_mpfr_conversions test_cpp_int_conv
+ gcov test_arithmetic_cpp_int_1 test_arithmetic_cpp_int_2 test_arithmetic_cpp_int_3 \
+ gcov test_arithmetic_cpp_int_4 test_arithmetic_cpp_int_5 test_arithmetic_cpp_int_6 \
+ gcov test_arithmetic_cpp_int_7 test_arithmetic_cpp_int_8 test_arithmetic_cpp_int_9 \
+ gcov test_arithmetic_cpp_int_10 test_arithmetic_cpp_int_11 test_arithmetic_cpp_int_12 \
+ gcov test_arithmetic_cpp_int_13 test_arithmetic_cpp_int_14 test_arithmetic_cpp_int_15 \
+ gcov test_arithmetic_cpp_int_16 test_arithmetic_cpp_int_17 test_arithmetic_cpp_int_18 \
+ test_arithmetic_cpp_dec_float_1 test_arithmetic_cpp_dec_float_2 test_arithmetic_cpp_dec_float_3\
+ test_arithmetic_concept test_arithmetic_mpz test_arithmetic_mpf \
+ test_arithmetic_mpf_50 test_arithmetic_mpq test_arithmetic_mpfr test_arithmetic_mpfr_50 test_cpp_int \
+ test_int_io test_float_io test_rational_io test_gmp_conversions test_mpfr_conversions test_cpp_int_conv
 
-test_arithmetic_cpp_int_1.o : ../test_arithmetic.cpp $(SOURCES)
- g++ -std=gnu++0x -DTEST_CPP_INT_1 --coverage -g -I../../../.. -I../../../../../../trunk -o test_arithmetic_cpp_int_1.o -c ../test_arithmetic.cpp
+test_arithmetic_cpp_int_1.o : ../test_arithmetic_cpp_int_1.cpp $(SOURCES)
+ g++ -std=gnu++0x -DTEST_CPP_INT_1 --coverage -g -I../../../.. -I../../../../../../trunk -o test_arithmetic_cpp_int_1.o -c ../test_arithmetic_cpp_int_1.cpp
 
 test_arithmetic_cpp_int_1 : test_arithmetic_cpp_int_1.o
         g++ -std=gnu++0x --coverage -o test_arithmetic_cpp_int_1 test_arithmetic_cpp_int_1.o
 
-test_arithmetic_cpp_int_2.o : ../test_arithmetic.cpp $(SOURCES)
- g++ -std=gnu++0x -DTEST_CPP_INT_2 --coverage -g -I../../../.. -I../../../../../../trunk -o test_arithmetic_cpp_int_2.o -c ../test_arithmetic.cpp
+test_arithmetic_cpp_int_2.o : ../test_arithmetic_cpp_int_2.cpp $(SOURCES)
+ g++ -std=gnu++0x -DTEST_CPP_INT_2 --coverage -g -I../../../.. -I../../../../../../trunk -o test_arithmetic_cpp_int_2.o -c ../test_arithmetic_cpp_int_2.cpp
 
 test_arithmetic_cpp_int_2 : test_arithmetic_cpp_int_2.o
         g++ -std=gnu++0x --coverage -o test_arithmetic_cpp_int_2 test_arithmetic_cpp_int_2.o
 
-test_arithmetic_cpp_int_3.o : ../test_arithmetic.cpp $(SOURCES)
- g++ -std=gnu++0x -DTEST_CPP_INT_3 --coverage -g -I../../../.. -I../../../../../../trunk -o test_arithmetic_cpp_int_3.o -c ../test_arithmetic.cpp
+test_arithmetic_cpp_int_3.o : ../test_arithmetic_cpp_int_3.cpp $(SOURCES)
+ g++ -std=gnu++0x -DTEST_CPP_INT_3 --coverage -g -I../../../.. -I../../../../../../trunk -o test_arithmetic_cpp_int_3.o -c ../test_arithmetic_cpp_int_3.cpp
 
 test_arithmetic_cpp_int_3 : test_arithmetic_cpp_int_3.o
         g++ -std=gnu++0x --coverage -o test_arithmetic_cpp_int_3 test_arithmetic_cpp_int_3.o
 
-test_arithmetic_cpp_dec_float.o : ../test_arithmetic.cpp $(SOURCES)
- g++ -std=gnu++0x -DTEST_CPP_DEC_FLOAT --coverage -g -I../../../.. -I../../../../../../trunk -o test_arithmetic_cpp_dec_float.o -c ../test_arithmetic.cpp
+test_arithmetic_cpp_int_4.o : ../test_arithmetic_cpp_int_4.cpp $(SOURCES)
+ g++ -std=gnu++0x -DTEST_CPP_INT_3 --coverage -g -I../../../.. -I../../../../../../trunk -o test_arithmetic_cpp_int_4.o -c ../test_arithmetic_cpp_int_4.cpp
 
-test_arithmetic_cpp_dec_float : test_arithmetic_cpp_dec_float.o
- g++ -std=gnu++0x --coverage -o test_arithmetic_cpp_dec_float test_arithmetic_cpp_dec_float.o
+test_arithmetic_cpp_int_4 : test_arithmetic_cpp_int_4.o
+ g++ -std=gnu++0x --coverage -o test_arithmetic_cpp_int_4 test_arithmetic_cpp_int_4.o
 
-test_arithmetic_concept.o : ../test_arithmetic.cpp $(SOURCES)
- g++ -std=gnu++0x -DTEST_BACKEND --coverage -g -I../../../.. -I../../../../../../trunk -o test_arithmetic_concept.o -c ../test_arithmetic.cpp
+test_arithmetic_cpp_int_5.o : ../test_arithmetic_cpp_int_5.cpp $(SOURCES)
+ g++ -std=gnu++0x -DTEST_CPP_INT_3 --coverage -g -I../../../.. -I../../../../../../trunk -o test_arithmetic_cpp_int_5.o -c ../test_arithmetic_cpp_int_5.cpp
+
+test_arithmetic_cpp_int_5 : test_arithmetic_cpp_int_5.o
+ g++ -std=gnu++0x --coverage -o test_arithmetic_cpp_int_5 test_arithmetic_cpp_int_5.o
+
+test_arithmetic_cpp_int_6.o : ../test_arithmetic_cpp_int_6.cpp $(SOURCES)
+ g++ -std=gnu++0x -DTEST_CPP_INT_3 --coverage -g -I../../../.. -I../../../../../../trunk -o test_arithmetic_cpp_int_6.o -c ../test_arithmetic_cpp_int_6.cpp
+
+test_arithmetic_cpp_int_6 : test_arithmetic_cpp_int_6.o
+ g++ -std=gnu++0x --coverage -o test_arithmetic_cpp_int_6 test_arithmetic_cpp_int_6.o
+
+test_arithmetic_cpp_int_7.o : ../test_arithmetic_cpp_int_7.cpp $(SOURCES)
+ g++ -std=gnu++0x -DTEST_CPP_INT_3 --coverage -g -I../../../.. -I../../../../../../trunk -o test_arithmetic_cpp_int_7.o -c ../test_arithmetic_cpp_int_7.cpp
+
+test_arithmetic_cpp_int_7 : test_arithmetic_cpp_int_7.o
+ g++ -std=gnu++0x --coverage -o test_arithmetic_cpp_int_7 test_arithmetic_cpp_int_7.o
+
+test_arithmetic_cpp_int_8.o : ../test_arithmetic_cpp_int_8.cpp $(SOURCES)
+ g++ -std=gnu++0x -DTEST_CPP_INT_3 --coverage -g -I../../../.. -I../../../../../../trunk -o test_arithmetic_cpp_int_8.o -c ../test_arithmetic_cpp_int_8.cpp
+
+test_arithmetic_cpp_int_8 : test_arithmetic_cpp_int_8.o
+ g++ -std=gnu++0x --coverage -o test_arithmetic_cpp_int_8 test_arithmetic_cpp_int_8.o
+
+test_arithmetic_cpp_int_9.o : ../test_arithmetic_cpp_int_9.cpp $(SOURCES)
+ g++ -std=gnu++0x -DTEST_CPP_INT_3 --coverage -g -I../../../.. -I../../../../../../trunk -o test_arithmetic_cpp_int_9.o -c ../test_arithmetic_cpp_int_9.cpp
+
+test_arithmetic_cpp_int_9 : test_arithmetic_cpp_int_9.o
+ g++ -std=gnu++0x --coverage -o test_arithmetic_cpp_int_9 test_arithmetic_cpp_int_9.o
+
+test_arithmetic_cpp_int_10.o : ../test_arithmetic_cpp_int_10.cpp $(SOURCES)
+ g++ -std=gnu++0x -DTEST_CPP_INT_3 --coverage -g -I../../../.. -I../../../../../../trunk -o test_arithmetic_cpp_int_10.o -c ../test_arithmetic_cpp_int_10.cpp
+
+test_arithmetic_cpp_int_10 : test_arithmetic_cpp_int_10.o
+ g++ -std=gnu++0x --coverage -o test_arithmetic_cpp_int_10 test_arithmetic_cpp_int_10.o
+
+test_arithmetic_cpp_int_11.o : ../test_arithmetic_cpp_int_11.cpp $(SOURCES)
+ g++ -std=gnu++0x -DTEST_CPP_INT_3 --coverage -g -I../../../.. -I../../../../../../trunk -o test_arithmetic_cpp_int_11.o -c ../test_arithmetic_cpp_int_12.cpp
+
+test_arithmetic_cpp_int_11 : test_arithmetic_cpp_int_11.o
+ g++ -std=gnu++0x --coverage -o test_arithmetic_cpp_int_11 test_arithmetic_cpp_int_11.o
+
+test_arithmetic_cpp_int_12.o : ../test_arithmetic_cpp_int_12.cpp $(SOURCES)
+ g++ -std=gnu++0x -DTEST_CPP_INT_3 --coverage -g -I../../../.. -I../../../../../../trunk -o test_arithmetic_cpp_int_12.o -c ../test_arithmetic_cpp_int_12.cpp
+
+test_arithmetic_cpp_int_12 : test_arithmetic_cpp_int_12.o
+ g++ -std=gnu++0x --coverage -o test_arithmetic_cpp_int_12 test_arithmetic_cpp_int_12.o
+
+test_arithmetic_cpp_int_13.o : ../test_arithmetic_cpp_int_13.cpp $(SOURCES)
+ g++ -std=gnu++0x -DTEST_CPP_INT_3 --coverage -g -I../../../.. -I../../../../../../trunk -o test_arithmetic_cpp_int_13.o -c ../test_arithmetic_cpp_int_13.cpp
+
+test_arithmetic_cpp_int_13 : test_arithmetic_cpp_int_13.o
+ g++ -std=gnu++0x --coverage -o test_arithmetic_cpp_int_13 test_arithmetic_cpp_int_13.o
+
+test_arithmetic_cpp_int_14.o : ../test_arithmetic_cpp_int_14.cpp $(SOURCES)
+ g++ -std=gnu++0x -DTEST_CPP_INT_3 --coverage -g -I../../../.. -I../../../../../../trunk -o test_arithmetic_cpp_int_14.o -c ../test_arithmetic_cpp_int_14.cpp
+
+test_arithmetic_cpp_int_14 : test_arithmetic_cpp_int_14.o
+ g++ -std=gnu++0x --coverage -o test_arithmetic_cpp_int_14 test_arithmetic_cpp_int_14.o
+
+test_arithmetic_cpp_int_15.o : ../test_arithmetic_cpp_int_15.cpp $(SOURCES)
+ g++ -std=gnu++0x -DTEST_CPP_INT_3 --coverage -g -I../../../.. -I../../../../../../trunk -o test_arithmetic_cpp_int_15.o -c ../test_arithmetic_cpp_int_15.cpp
+
+test_arithmetic_cpp_int_15 : test_arithmetic_cpp_int_15.o
+ g++ -std=gnu++0x --coverage -o test_arithmetic_cpp_int_15 test_arithmetic_cpp_int_15.o
+
+test_arithmetic_cpp_int_16.o : ../test_arithmetic_cpp_int_16.cpp $(SOURCES)
+ g++ -std=gnu++0x -DTEST_CPP_INT_3 --coverage -g -I../../../.. -I../../../../../../trunk -o test_arithmetic_cpp_int_16.o -c ../test_arithmetic_cpp_int_16.cpp
+
+test_arithmetic_cpp_int_16 : test_arithmetic_cpp_int_16.o
+ g++ -std=gnu++0x --coverage -o test_arithmetic_cpp_int_16 test_arithmetic_cpp_int_16.o
+
+test_arithmetic_cpp_int_17.o : ../test_arithmetic_cpp_int_17.cpp $(SOURCES)
+ g++ -std=gnu++0x -DTEST_CPP_INT_3 --coverage -g -I../../../.. -I../../../../../../trunk -o test_arithmetic_cpp_int_17.o -c ../test_arithmetic_cpp_int_17.cpp
+
+test_arithmetic_cpp_int_17 : test_arithmetic_cpp_int_17.o
+ g++ -std=gnu++0x --coverage -o test_arithmetic_cpp_int_17 test_arithmetic_cpp_int_17.o
+
+test_arithmetic_cpp_int_18.o : ../test_arithmetic_cpp_int_18.cpp $(SOURCES)
+ g++ -std=gnu++0x -DTEST_CPP_INT_3 --coverage -g -I../../../.. -I../../../../../../trunk -o test_arithmetic_cpp_int_18.o -c ../test_arithmetic_cpp_int_18.cpp
+
+test_arithmetic_cpp_int_18 : test_arithmetic_cpp_int_18.o
+ g++ -std=gnu++0x --coverage -o test_arithmetic_cpp_int_18 test_arithmetic_cpp_int_18.o
+
+test_arithmetic_cpp_dec_float_1.o : ../test_arithmetic_cpp_dec_float_1.cpp $(SOURCES)
+ g++ -std=gnu++0x -DTEST_CPP_DEC_FLOAT --coverage -g -I../../../.. -I../../../../../../trunk -o test_arithmetic_cpp_dec_float_1.o -c ../test_arithmetic_cpp_dec_float_1.cpp
+
+test_arithmetic_cpp_dec_float_1 : test_arithmetic_cpp_dec_float_1.o
+ g++ -std=gnu++0x --coverage -o test_arithmetic_cpp_dec_float_1 test_arithmetic_cpp_dec_float_1.o
+
+test_arithmetic_cpp_dec_float_2.o : ../test_arithmetic_cpp_dec_float_2.cpp $(SOURCES)
+ g++ -std=gnu++0x -DTEST_CPP_DEC_FLOAT --coverage -g -I../../../.. -I../../../../../../trunk -o test_arithmetic_cpp_dec_float_2.o -c ../test_arithmetic_cpp_dec_float_2.cpp
+
+test_arithmetic_cpp_dec_float_2 : test_arithmetic_cpp_dec_float_2.o
+ g++ -std=gnu++0x --coverage -o test_arithmetic_cpp_dec_float_2 test_arithmetic_cpp_dec_float_2.o
+
+test_arithmetic_cpp_dec_float_3.o : ../test_arithmetic_cpp_dec_float_3.cpp $(SOURCES)
+ g++ -std=gnu++0x -DTEST_CPP_DEC_FLOAT --coverage -g -I../../../.. -I../../../../../../trunk -o test_arithmetic_cpp_dec_float_3.o -c ../test_arithmetic_cpp_dec_float_3.cpp
+
+test_arithmetic_cpp_dec_float_3 : test_arithmetic_cpp_dec_float_3.o
+ g++ -std=gnu++0x --coverage -o test_arithmetic_cpp_dec_float_3 test_arithmetic_cpp_dec_float_3.o
+
+test_arithmetic_concept.o : ../test_arithmetic_backend_concept.cpp $(SOURCES)
+ g++ -std=gnu++0x -DTEST_BACKEND --coverage -g -I../../../.. -I../../../../../../trunk -o test_arithmetic_concept.o -c ../test_arithmetic_backend_concept.cpp
 
 test_arithmetic_concept : test_arithmetic_concept.o
         g++ -std=gnu++0x --coverage -o test_arithmetic_concept test_arithmetic_concept.o
 
-test_arithmetic_mpz.o : ../test_arithmetic.cpp $(SOURCES)
- g++ -std=gnu++0x -DTEST_MPZ --coverage -g -I../../../.. -I../../../../../../trunk -o test_arithmetic_mpz.o -c ../test_arithmetic.cpp
+test_arithmetic_mpz.o : ../test_arithmetic_mpz.cpp $(SOURCES)
+ g++ -std=gnu++0x -DTEST_MPZ --coverage -g -I../../../.. -I../../../../../../trunk -o test_arithmetic_mpz.o -c ../test_arithmetic_mpz.cpp
 
 test_arithmetic_mpz : test_arithmetic_mpz.o
         g++ -std=gnu++0x --coverage -o test_arithmetic_mpz test_arithmetic_mpz.o -lgmp
 
-test_arithmetic_mpf.o : ../test_arithmetic.cpp $(SOURCES)
- g++ -std=gnu++0x -DTEST_MPF --coverage -g -I../../../.. -I../../../../../../trunk -o test_arithmetic_mpf.o -c ../test_arithmetic.cpp
+test_arithmetic_mpf.o : ../test_arithmetic_mpf.cpp $(SOURCES)
+ g++ -std=gnu++0x -DTEST_MPF --coverage -g -I../../../.. -I../../../../../../trunk -o test_arithmetic_mpf.o -c ../test_arithmetic_mpf.cpp
 
 test_arithmetic_mpf : test_arithmetic_mpf.o
         g++ -std=gnu++0x --coverage -o test_arithmetic_mpf test_arithmetic_mpf.o -lgmp
 
-test_arithmetic_mpf_50.o : ../test_arithmetic.cpp $(SOURCES)
- g++ -std=gnu++0x -DTEST_MPF_50 --coverage -g -I../../../.. -I../../../../../../trunk -o test_arithmetic_mpf_50.o -c ../test_arithmetic.cpp
+test_arithmetic_mpf_50.o : ../test_arithmetic_mpf_50.cpp $(SOURCES)
+ g++ -std=gnu++0x -DTEST_MPF_50 --coverage -g -I../../../.. -I../../../../../../trunk -o test_arithmetic_mpf_50.o -c ../test_arithmetic_mpf_50.cpp
 
 test_arithmetic_mpf_50 : test_arithmetic_mpf_50.o
         g++ -std=gnu++0x --coverage -o test_arithmetic_mpf_50 test_arithmetic_mpf_50.o -lgmp
 
-test_arithmetic_mpq.o : ../test_arithmetic.cpp $(SOURCES)
- g++ -std=gnu++0x -DTEST_MPQ --coverage -g -I../../../.. -I../../../../../../trunk -o test_arithmetic_mpq.o -c ../test_arithmetic.cpp
+test_arithmetic_mpq.o : ../test_arithmetic_mpq.cpp $(SOURCES)
+ g++ -std=gnu++0x -DTEST_MPQ --coverage -g -I../../../.. -I../../../../../../trunk -o test_arithmetic_mpq.o -c ../test_arithmetic_mpq.cpp
 
 test_arithmetic_mpq : test_arithmetic_mpq.o
         g++ -std=gnu++0x --coverage -o test_arithmetic_mpq test_arithmetic_mpq.o -lgmp
 
-test_arithmetic_mpfr.o : ../test_arithmetic.cpp $(SOURCES)
- g++ -std=gnu++0x -DTEST_MPFR --coverage -g -I../../../.. -I../../../../../../trunk -o test_arithmetic_mpfr.o -c ../test_arithmetic.cpp
+test_arithmetic_mpfr.o : ../test_arithmetic_mpfr.cpp $(SOURCES)
+ g++ -std=gnu++0x -DTEST_MPFR --coverage -g -I../../../.. -I../../../../../../trunk -o test_arithmetic_mpfr.o -c ../test_arithmetic_mpfr.cpp
 
 test_arithmetic_mpfr : test_arithmetic_mpfr.o
         g++ -std=gnu++0x --coverage -o test_arithmetic_mpfr test_arithmetic_mpfr.o -lmpfr -lgmp
 
-test_arithmetic_mpfr_50.o : ../test_arithmetic.cpp $(SOURCES)
- g++ -std=gnu++0x -DTEST_MPFR_50 --coverage -g -I../../../.. -I../../../../../../trunk -o test_arithmetic_mpfr_50.o -c ../test_arithmetic.cpp
+test_arithmetic_mpfr_50.o : ../test_arithmetic_mpfr_50.cpp $(SOURCES)
+ g++ -std=gnu++0x -DTEST_MPFR_50 --coverage -g -I../../../.. -I../../../../../../trunk -o test_arithmetic_mpfr_50.o -c ../test_arithmetic_mpfr_50.cpp
 
 test_arithmetic_mpfr_50 : test_arithmetic_mpfr_50.o
         g++ -std=gnu++0x --coverage -o test_arithmetic_mpfr_50 test_arithmetic_mpfr_50.o -lmpfr -lgmp
@@ -113,7 +222,7 @@
         g++ -std=gnu++0x --coverage -o test_int_io test_int_io.o -lgmp
 
 test_float_io.o : ../test_float_io.cpp $(SOURCES)
- g++ -std=gnu++0x --coverage -g -I../../../.. -I../../../../../../trunk -o test_float_io.o -c ../test_float_io.cpp
+ g++ -std=gnu++0x --coverage -g -DTEST_MPF_50 -DTEST_CPP_DEC_FLOAT -DTEST_MPFR_50 -I../../../.. -I../../../../../../trunk -o test_float_io.o -c ../test_float_io.cpp
 
 test_float_io : test_float_io.o
         g++ -std=gnu++0x --coverage -o test_float_io test_float_io.o -lmpfr -lgmp
@@ -142,12 +251,36 @@
 test_cpp_int_conv : test_cpp_int_conv.o
         g++ -std=gnu++0x --coverage -o test_cpp_int_conv test_cpp_int_conv.o
 
-run : test_arithmetic_cpp_int_1 test_arithmetic_cpp_int_2 test_arithmetic_cpp_int_3 test_arithmetic_cpp_dec_float test_arithmetic_concept test_arithmetic_mpz test_arithmetic_mpf test_arithmetic_mpf_50 \
-test_arithmetic_mpq test_arithmetic_mpfr test_arithmetic_mpfr_50 test_cpp_int test_int_io test_float_io test_rational_io test_gmp_conversions test_mpfr_conversions test_cpp_int_conv
+run : test_arithmetic_cpp_int_1 test_arithmetic_cpp_int_2 test_arithmetic_cpp_int_3 \
+ test_arithmetic_cpp_int_4 test_arithmetic_cpp_int_5 test_arithmetic_cpp_int_6 \
+ test_arithmetic_cpp_int_7 test_arithmetic_cpp_int_8 test_arithmetic_cpp_int_9 \
+ test_arithmetic_cpp_int_10 test_arithmetic_cpp_int_11 test_arithmetic_cpp_int_12 \
+ test_arithmetic_cpp_int_13 test_arithmetic_cpp_int_14 test_arithmetic_cpp_int_15 \
+ test_arithmetic_cpp_int_16 test_arithmetic_cpp_int_17 test_arithmetic_cpp_int_18 \
+ test_arithmetic_cpp_dec_float_1 test_arithmetic_cpp_dec_float_2 test_arithmetic_cpp_dec_float_3 test_arithmetic_concept \
+ test_arithmetic_mpz test_arithmetic_mpf test_arithmetic_mpf_50 test_arithmetic_mpq test_arithmetic_mpfr test_arithmetic_mpfr_50 \
+ test_cpp_int test_int_io test_float_io test_rational_io test_gmp_conversions test_mpfr_conversions test_cpp_int_conv
         ./test_arithmetic_cpp_int_1
         ./test_arithmetic_cpp_int_2
         ./test_arithmetic_cpp_int_3
- ./test_arithmetic_cpp_dec_float
+ ./test_arithmetic_cpp_int_4
+ ./test_arithmetic_cpp_int_5
+ ./test_arithmetic_cpp_int_6
+ ./test_arithmetic_cpp_int_7
+ ./test_arithmetic_cpp_int_8
+ ./test_arithmetic_cpp_int_9
+ ./test_arithmetic_cpp_int_10
+ ./test_arithmetic_cpp_int_11
+ ./test_arithmetic_cpp_int_12
+ ./test_arithmetic_cpp_int_13
+ ./test_arithmetic_cpp_int_14
+ ./test_arithmetic_cpp_int_15
+ ./test_arithmetic_cpp_int_16
+ ./test_arithmetic_cpp_int_17
+ ./test_arithmetic_cpp_int_18
+ ./test_arithmetic_cpp_dec_float_1
+ ./test_arithmetic_cpp_dec_float_2
+ ./test_arithmetic_cpp_dec_float_3
         ./test_arithmetic_concept
         ./test_arithmetic_mpz
         ./test_arithmetic_mpf
@@ -164,9 +297,16 @@
         ./test_cpp_int_conv
 
 clean :
- rm -rf *.o *.gc* test_arithmetic_cpp_int_1 test_arithmetic_cpp_int_2 test_arithmetic_cpp_int_3 test_arithmetic_cpp_dec_float test_arithmetic_concept test_arithmetic_mpz \
- test_arithmetic_mpf test_arithmetic_mpf_50 test_arithmetic_mpq test_arithmetic_mpfr test_arithmetic_mpfr_50 test_cpp_int\
- test_int_io test_float_io test_rational_io test_gmp_conversions test_mpfr_conversions test_cpp_int_conv
+ rm -rf *.o *.gc* test_arithmetic_cpp_int_1 test_arithmetic_cpp_int_2 test_arithmetic_cpp_int_3 \
+ test_arithmetic_cpp_int_4 test_arithmetic_cpp_int_5 test_arithmetic_cpp_int_6 \
+ test_arithmetic_cpp_int_7 test_arithmetic_cpp_int_8 test_arithmetic_cpp_int_9 \
+ test_arithmetic_cpp_int_10 test_arithmetic_cpp_int_11 test_arithmetic_cpp_int_12 \
+ test_arithmetic_cpp_int_13 test_arithmetic_cpp_int_14 test_arithmetic_cpp_int_15 \
+ test_arithmetic_cpp_int_16 test_arithmetic_cpp_int_17 test_arithmetic_cpp_int_18 \
+ test_arithmetic_cpp_dec_float test_arithmetic_concept test_arithmetic_mpz \
+ test_arithmetic_mpf test_arithmetic_mpf_50 test_arithmetic_mpq test_arithmetic_mpfr test_arithmetic_mpfr_50 test_cpp_int\
+ test_int_io test_float_io test_rational_io test_gmp_conversions test_mpfr_conversions test_cpp_int_conv
+
 
 
 

Modified: trunk/libs/multiprecision/test/test_arithmetic.hpp
==============================================================================
--- trunk/libs/multiprecision/test/test_arithmetic.hpp (original)
+++ trunk/libs/multiprecision/test/test_arithmetic.hpp 2013-04-26 04:17:12 EDT (Fri, 26 Apr 2013)
@@ -1728,6 +1728,9 @@
    b = 30;
    c = a + b * c;
    BOOST_CHECK_EQUAL(c , 20 + 30 * 10);
+ c = 10;
+ c = a + b / c;
+ BOOST_CHECK_EQUAL(c , 20 + 30 / 10);
 
    //
    // Test conditionals:


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