Boost logo

Boost-Commit :

Subject: [Boost-commit] svn:boost r73572 - in sandbox/e_float: boost/e_float libs/e_float/src/e_float libs/e_float/src/e_float/gmp libs/e_float/src/e_float/mpfr libs/e_float/test/real/cases
From: e_float_at_[hidden]
Date: 2011-08-06 09:21:16


Author: christopher_kormanyos
Date: 2011-08-06 09:21:15 EDT (Sat, 06 Aug 2011)
New Revision: 73572
URL: http://svn.boost.org/trac/boost/changeset/73572

Log:
- Begin adapting GMP back-end for Boost.Math compatibility.
- Do some additional trivial cleanup.
Text files modified:
   sandbox/e_float/boost/e_float/e_float_gmp.hpp | 59 +++++++++++---------
   sandbox/e_float/libs/e_float/src/e_float/e_float_base.cpp | 3
   sandbox/e_float/libs/e_float/src/e_float/gmp/e_float_gmp.cpp | 27 +++++---
   sandbox/e_float/libs/e_float/src/e_float/mpfr/e_float_mpfr.cpp | 116 ++++++++++++---------------------------
   sandbox/e_float/libs/e_float/test/real/cases/test_case_0000z_global_ops_pod.cpp | 64 ++++++++-------------
   5 files changed, 111 insertions(+), 158 deletions(-)

Modified: sandbox/e_float/boost/e_float/e_float_gmp.hpp
==============================================================================
--- sandbox/e_float/boost/e_float/e_float_gmp.hpp (original)
+++ sandbox/e_float/boost/e_float/e_float_gmp.hpp 2011-08-06 09:21:15 EDT (Sat, 06 Aug 2011)
@@ -83,39 +83,33 @@
       ::mpf_t rop;
 
     public:
-
- // Constructors
- e_float(void);
-
- e_float(const INT32 n);
- e_float(const INT64 n);
- e_float(const UINT32 u);
- e_float(const UINT64 u);
+ e_float();
+ e_float(const char n);
+ e_float(const signed char n);
+ e_float(const unsigned char n);
+ e_float(const wchar_t n);
+ e_float(const signed short n);
+ e_float(const unsigned short n);
+ e_float(const signed int n);
+ e_float(const unsigned int n);
+ e_float(const signed long n);
+ e_float(const unsigned long n);
+ e_float(const signed long long n);
+ e_float(const unsigned long long n);
+ e_float(const float f);
       e_float(const double d);
+ e_float(const long double ld);
       e_float(const char* const s);
       e_float(const std::string& str);
 
       e_float(const e_float& f);
-
- // Constructor from mantissa and exponent.
       e_float(const double mantissa, const INT64 exponent);
 
       virtual ~e_float();
 
     private:
-
       explicit e_float(const ::mpf_t& op);
 
- static const INT64& max_exp2(void);
- static const INT64& min_exp2(void);
-
- static void init(void);
-
- void from_uint64(const UINT64 u);
- void from_uint32(const UINT32 u);
-
- INT32 cmp_data(const ::mpf_t& v) const;
-
     public:
 
       virtual INT32 cmp(const e_float& v) const;
@@ -133,8 +127,10 @@
       virtual e_float& operator-=(const e_float& v);
       virtual e_float& operator*=(const e_float& v);
       virtual e_float& operator/=(const e_float& v);
- virtual e_float& mul_by_int(const INT32 n);
- virtual e_float& div_by_int(const INT32 n);
+ virtual e_float& add_unsigned_long_long(const unsigned long long n);
+ virtual e_float& sub_unsigned_long_long(const unsigned long long n);
+ virtual e_float& mul_unsigned_long_long(const unsigned long long n);
+ virtual e_float& div_unsigned_long_long(const unsigned long long n);
 
       virtual e_float& calculate_inv (void);
       virtual e_float& calculate_sqrt(void);
@@ -162,13 +158,22 @@
       virtual e_float extract_integer_part(void) const;
       virtual e_float extract_decimal_part(void) const;
 
- // Argument range and check functions
- virtual INT64 order(void) const;
-
     private:
+ static const INT64& max_exp2(void);
+ static const INT64& min_exp2(void);
+
+ static void init(void);
+
+ INT32 cmp_data(const ::mpf_t& v) const;
+
+ void from_unsigned_long_long(const unsigned long long u);
+ void from_unsigned_long(const unsigned long u);
 
- virtual void wr_string(std::string& str, std::ostream& os) const;
       virtual bool rd_string(const char* const s);
+
+ virtual INT64 get_order_exact(void) const;
+ virtual INT64 get_order_approximate(void) const;
+ virtual void get_output_string(std::string& str, INT64& my_exp, const std::size_t number_of_digits) const;
     };
   }
 

Modified: sandbox/e_float/libs/e_float/src/e_float/e_float_base.cpp
==============================================================================
--- sandbox/e_float/libs/e_float/src/e_float/e_float_base.cpp (original)
+++ sandbox/e_float/libs/e_float/src/e_float/e_float_base.cpp 2011-08-06 09:21:15 EDT (Sat, 06 Aug 2011)
@@ -39,8 +39,7 @@
 {
   std::string str;
   static_cast<void>(is >> str);
- const bool b_read = f.rd_string(str.c_str());
- static_cast<void>(b_read);
+ static_cast<void>(f.rd_string(str.c_str()));
   return is;
 }
 

Modified: sandbox/e_float/libs/e_float/src/e_float/gmp/e_float_gmp.cpp
==============================================================================
--- sandbox/e_float/libs/e_float/src/e_float/gmp/e_float_gmp.cpp (original)
+++ sandbox/e_float/libs/e_float/src/e_float/gmp/e_float_gmp.cpp 2011-08-06 09:21:15 EDT (Sat, 06 Aug 2011)
@@ -95,16 +95,6 @@
   from_uint64(u);
 }
 
-void gmp::e_float::from_uint64(const UINT64 u)
-{
- ::mpf_init_set_str(rop, Util::lexical_cast(u).c_str(), 10);
-}
-
-void gmp::e_float::from_uint32(const UINT32 u)
-{
- ::mpf_init_set_ui(rop, static_cast<unsigned long int>(u));
-}
-
 gmp::e_float::e_float() : fpclass (ef_finite),
                           prec_elem(ef_digits10_tol)
 {
@@ -179,6 +169,23 @@
   ::mpf_clear(rop);
 }
 
+void gmp::e_float::from_unsigned_long_long(const unsigned long long u)
+{
+ if(n <= static_cast<unsigned long long>((std::numeric_limits<unsigned long>::max)()))
+ {
+ from_unsigned_long(static_cast<unsigned long>(u));
+ }
+ else
+ {
+ ::mpf_init_set_str(rop, Util::lexical_cast(u).c_str(), 10);
+ }
+}
+
+void gmp::e_float::from_unsigned_long(const unsigned long u)
+{
+ ::mpf_init_set_ui(rop, u);
+}
+
 void gmp::e_float::precision(const INT32 prec_digits)
 {
   const unsigned long int digits2_request = static_cast<unsigned long int>(static_cast<UINT64>(static_cast<double>(prec_digits) / ::d_log2()));

Modified: sandbox/e_float/libs/e_float/src/e_float/mpfr/e_float_mpfr.cpp
==============================================================================
--- sandbox/e_float/libs/e_float/src/e_float/mpfr/e_float_mpfr.cpp (original)
+++ sandbox/e_float/libs/e_float/src/e_float/mpfr/e_float_mpfr.cpp 2011-08-06 09:21:15 EDT (Sat, 06 Aug 2011)
@@ -21,14 +21,6 @@
 
 namespace
 {
- typedef enum enum_os_float_field_type
- {
- os_float_field_scientific,
- os_float_field_fixed,
- os_float_field_none
- }
- os_float_filed_type;
-
   const double& d_log2(void)
   {
     static const double value_log2 = 0.3010299956639811952137389;
@@ -48,60 +40,30 @@
   }
 }
 
-mpfr::e_float::e_float()
-{
- init();
- ::mpfr_init(rop);
-}
-
-mpfr::e_float::e_float(const char n) { const bool b_neg = (std::numeric_limits<char>::is_signed ? (n < static_cast<char> (0)) : false); from_unsigned_long((!b_neg) ? static_cast<unsigned long>(n) : static_cast<unsigned long>(-n)); if(b_neg) { ::mpfr_neg(rop, rop, GMP_RNDN); } }
-mpfr::e_float::e_float(const wchar_t n) { const bool b_neg = (std::numeric_limits<wchar_t>::is_signed ? (n < static_cast<wchar_t>(0)) : false); from_unsigned_long((!b_neg) ? static_cast<unsigned long>(n) : static_cast<unsigned long>(-n)); if(b_neg) { ::mpfr_neg(rop, rop, GMP_RNDN); } }
-
-mpfr::e_float::e_float(const signed char n) { const bool b_neg = (n < static_cast<signed char>(0)); from_unsigned_long ((!b_neg) ? static_cast<unsigned long> (n) : static_cast<unsigned long> (-n)); if(b_neg) { ::mpfr_neg(rop, rop, GMP_RNDN); } }
-mpfr::e_float::e_float(const signed short n) { const bool b_neg = (n < static_cast<signed short>(0)); from_unsigned_long ((!b_neg) ? static_cast<unsigned long> (n) : static_cast<unsigned long> (-n)); if(b_neg) { ::mpfr_neg(rop, rop, GMP_RNDN); } }
-mpfr::e_float::e_float(const signed int n) { const bool b_neg = (n < static_cast<signed int>(0)); from_unsigned_long ((!b_neg) ? static_cast<unsigned long> (n) : static_cast<unsigned long> (-n)); if(b_neg) { ::mpfr_neg(rop, rop, GMP_RNDN); } }
-mpfr::e_float::e_float(const signed long n) { const bool b_neg = (n < static_cast<signed long>(0)); from_unsigned_long ((!b_neg) ? static_cast<unsigned long> (n) : static_cast<unsigned long> (-n)); if(b_neg) { ::mpfr_neg(rop, rop, GMP_RNDN); } }
-mpfr::e_float::e_float(const signed long long n) { const bool b_neg = (n < static_cast<signed long long>(0)); from_unsigned_long_long((!b_neg) ? static_cast<unsigned long long>(n) : static_cast<unsigned long long>(-n)); if(b_neg) { ::mpfr_neg(rop, rop, GMP_RNDN); } }
-
-mpfr::e_float::e_float(const unsigned char n) { from_unsigned_long (static_cast<unsigned long> (n)); }
-mpfr::e_float::e_float(const unsigned short n) { from_unsigned_long (static_cast<unsigned long> (n)); }
-mpfr::e_float::e_float(const unsigned int n) { from_unsigned_long (static_cast<unsigned long> (n)); }
-mpfr::e_float::e_float(const unsigned long n) { from_unsigned_long (static_cast<unsigned long> (n)); }
-mpfr::e_float::e_float(const unsigned long long n) { from_unsigned_long_long(static_cast<unsigned long long>(n)); }
-
-mpfr::e_float::e_float(const float f)
-{
- init();
- mpfr_init_set_d(rop, static_cast<double>(f), GMP_RNDN);
-}
-
-mpfr::e_float::e_float(const double d)
-{
- init();
- mpfr_init_set_d(rop, d, GMP_RNDN);
-}
-
-mpfr::e_float::e_float(const long double ld)
-{
- init();
- mpfr_init_set_ld(rop, ld, GMP_RNDN);
-}
+mpfr::e_float::e_float() { init(); ::mpfr_init(rop); }
 
-mpfr::e_float::e_float(const e_float& f)
-{
- init();
- mpfr_init_set(rop, f.rop, GMP_RNDN);
-}
+mpfr::e_float::e_float(const char n) { init(); const bool b_neg = (std::numeric_limits<char>::is_signed ? (n < static_cast<char> (0)) : false); from_unsigned_long((!b_neg) ? static_cast<unsigned long>(n) : static_cast<unsigned long>(-n)); if(b_neg) { ::mpfr_neg(rop, rop, GMP_RNDN); } }
+mpfr::e_float::e_float(const wchar_t n) { init(); const bool b_neg = (std::numeric_limits<wchar_t>::is_signed ? (n < static_cast<wchar_t>(0)) : false); from_unsigned_long((!b_neg) ? static_cast<unsigned long>(n) : static_cast<unsigned long>(-n)); if(b_neg) { ::mpfr_neg(rop, rop, GMP_RNDN); } }
 
-mpfr::e_float::e_float(const char* s)
-{
- static_cast<void>(rd_string(s));
-}
+mpfr::e_float::e_float(const signed char n) { init(); const bool b_neg = (n < static_cast<signed char>(0)); from_unsigned_long ((!b_neg) ? static_cast<unsigned long> (n) : static_cast<unsigned long> (-n)); if(b_neg) { ::mpfr_neg(rop, rop, GMP_RNDN); } }
+mpfr::e_float::e_float(const signed short n) { init(); const bool b_neg = (n < static_cast<signed short>(0)); from_unsigned_long ((!b_neg) ? static_cast<unsigned long> (n) : static_cast<unsigned long> (-n)); if(b_neg) { ::mpfr_neg(rop, rop, GMP_RNDN); } }
+mpfr::e_float::e_float(const signed int n) { init(); const bool b_neg = (n < static_cast<signed int>(0)); from_unsigned_long ((!b_neg) ? static_cast<unsigned long> (n) : static_cast<unsigned long> (-n)); if(b_neg) { ::mpfr_neg(rop, rop, GMP_RNDN); } }
+mpfr::e_float::e_float(const signed long n) { init(); const bool b_neg = (n < static_cast<signed long>(0)); from_unsigned_long ((!b_neg) ? static_cast<unsigned long> (n) : static_cast<unsigned long> (-n)); if(b_neg) { ::mpfr_neg(rop, rop, GMP_RNDN); } }
+mpfr::e_float::e_float(const signed long long n) { init(); const bool b_neg = (n < static_cast<signed long long>(0)); from_unsigned_long_long((!b_neg) ? static_cast<unsigned long long>(n) : static_cast<unsigned long long>(-n)); if(b_neg) { ::mpfr_neg(rop, rop, GMP_RNDN); } }
+
+mpfr::e_float::e_float(const unsigned char n) { init(); from_unsigned_long (static_cast<unsigned long> (n)); }
+mpfr::e_float::e_float(const unsigned short n) { init(); from_unsigned_long (static_cast<unsigned long> (n)); }
+mpfr::e_float::e_float(const unsigned int n) { init(); from_unsigned_long (static_cast<unsigned long> (n)); }
+mpfr::e_float::e_float(const unsigned long n) { init(); from_unsigned_long (static_cast<unsigned long> (n)); }
+mpfr::e_float::e_float(const unsigned long long n) { init(); from_unsigned_long_long(static_cast<unsigned long long>(n)); }
+
+mpfr::e_float::e_float(const float f) { init(); mpfr_init_set_d(rop, static_cast<double>(f), GMP_RNDN); }
+mpfr::e_float::e_float(const double d) { init(); mpfr_init_set_d(rop, d, GMP_RNDN); }
+mpfr::e_float::e_float(const long double ld) { init(); mpfr_init_set_ld(rop, ld, GMP_RNDN); }
+mpfr::e_float::e_float(const e_float& f) { init(); mpfr_init_set(rop, f.rop, GMP_RNDN); }
 
-mpfr::e_float::e_float(const std::string& str)
-{
- static_cast<void>(rd_string(str.c_str()));
-}
+mpfr::e_float::e_float(const char* s) { init(); static_cast<void>(rd_string(s)); }
+mpfr::e_float::e_float(const std::string& str) { init(); static_cast<void>(rd_string(str.c_str())); }
 
 mpfr::e_float::e_float(const double mantissa, const INT64 exponent)
 {
@@ -135,13 +97,18 @@
 
 void mpfr::e_float::from_unsigned_long_long(const unsigned long long u)
 {
- init();
- static_cast<void>(::mpfr_init_set_str(rop, Util::lexical_cast(u).c_str(), 10, GMP_RNDN));
+ if(u <= static_cast<unsigned long long>((std::numeric_limits<unsigned long>::max)()))
+ {
+ from_unsigned_long(static_cast<unsigned long>(u));
+ }
+ else
+ {
+ static_cast<void>(::mpfr_init_set_str(rop, Util::lexical_cast(u).c_str(), 10, GMP_RNDN));
+ }
 }
 
 void mpfr::e_float::from_unsigned_long(const unsigned long u)
 {
- init();
   mpfr_init_set_ui(rop, u, GMP_RNDN);
 }
 
@@ -207,7 +174,7 @@
 
 mpfr::e_float& mpfr::e_float::add_unsigned_long_long(const unsigned long long n)
 {
- if(n > static_cast<unsigned long long>(std::numeric_limits<unsigned long>::max()))
+ if(n > static_cast<unsigned long long>((std::numeric_limits<unsigned long>::max)()))
   {
     operator+=(e_float(n));
   }
@@ -221,7 +188,7 @@
 
 mpfr::e_float& mpfr::e_float::sub_unsigned_long_long(const unsigned long long n)
 {
- if(n > static_cast<unsigned long long>(std::numeric_limits<unsigned long>::max()))
+ if(n > static_cast<unsigned long long>((std::numeric_limits<unsigned long>::max)()))
   {
     operator-=(e_float(n));
   }
@@ -235,7 +202,7 @@
 
 mpfr::e_float& mpfr::e_float::mul_unsigned_long_long(const unsigned long long n)
 {
- if(n > static_cast<unsigned long long>(std::numeric_limits<unsigned long>::max()))
+ if(n > static_cast<unsigned long long>((std::numeric_limits<unsigned long>::max)()))
   {
     operator*=(e_float(n));
   }
@@ -249,7 +216,7 @@
 
 mpfr::e_float& mpfr::e_float::div_unsigned_long_long(const unsigned long long n)
 {
- if(n > static_cast<unsigned long long>(std::numeric_limits<unsigned long>::max()))
+ if(n > static_cast<unsigned long long>((std::numeric_limits<unsigned long>::max)()))
   {
     operator/=(e_float(n));
   }
@@ -368,9 +335,7 @@
     return static_cast<INT64>(!b_neg ? static_cast<INT64>(1) : static_cast<INT64>(-1));
   }
 
- static const char c0 = static_cast<char>('\0');
-
- std::tr1::array<char, 32u> str = {{ c0 }};
+ std::tr1::array<char, 32u> str = {{ static_cast<char>('0') }};
 
   mp_exp_t p10;
 
@@ -378,16 +343,11 @@
 
   std::string str_n64(static_cast<std::size_t>(p10), static_cast<char>('0'));
 
- std::copy(str.begin(),
- str.begin() + str_n64.size(),
- str_n64.begin());
+ std::copy(str.begin(), str.begin() + str_n64.size(), str_n64.begin());
 
   std::stringstream ss;
-
   ss << str_n64;
-
   INT64 n;
-
   ss >> n;
 
   return ((!b_neg) ? n : -n);
@@ -515,11 +475,7 @@
   }
 }
 
-bool mpfr::e_float::rd_string(const char* const s)
-{
- init();
- return (::mpfr_init_set_str(rop, s, 10, GMP_RNDN) == 1);
-}
+bool mpfr::e_float::rd_string(const char* const s) { return (::mpfr_init_set_str(rop, s, 10, GMP_RNDN) == 1); }
 
 e_float mpfr::e_float::my_cbrt (const e_float& x) { e_float res; static_cast<void>(::mpfr_cbrt (res.rop, x.rop, GMP_RNDN)); return res; }
 e_float mpfr::e_float::my_rootn (const e_float& x, const UINT32 p) { e_float res; static_cast<void>(::mpfr_root (res.rop, x.rop, static_cast<unsigned long int>(p), GMP_RNDN)); return res; }

Modified: sandbox/e_float/libs/e_float/test/real/cases/test_case_0000z_global_ops_pod.cpp
==============================================================================
--- sandbox/e_float/libs/e_float/test/real/cases/test_case_0000z_global_ops_pod.cpp (original)
+++ sandbox/e_float/libs/e_float/test/real/cases/test_case_0000z_global_ops_pod.cpp 2011-08-06 09:21:15 EDT (Sat, 06 Aug 2011)
@@ -8,10 +8,6 @@
 // "Algorithm 910: A Portable C++ Multiple-Precision System for Special-Function Calculations",
 // in ACM TOMS, {VOL 37, ISSUE 4, (February 2011)} (C) ACM, 2011. http://doi.acm.org/10.1145/1916461.1916469
 
-#if defined(_MSC_VER)
-#pragma warning(disable:4127)
-#endif
-
 #include <sstream>
 #include <string>
 #include <limits>
@@ -28,35 +24,21 @@
     static e_float the_value_min;
     static e_float the_value_max;
 
- template<typename T>
+ template<typename TYPE, typename CAST_TYPE>
     inline static bool check_type(void)
     {
- the_value_min = std::numeric_limits<T>::min();
- the_value_max = std::numeric_limits<T>::max();
+ the_value_min = (std::numeric_limits<TYPE>::min)();
+ the_value_max = (std::numeric_limits<TYPE>::max)();
 
       std::stringstream ss;
 
- if(std::numeric_limits<T>::is_signed)
- {
- ss << static_cast<signed long long>(std::numeric_limits<T>::min());
- }
- else
- {
- ss << static_cast<unsigned long long>(std::numeric_limits<T>::min());
- }
+ ss << static_cast<CAST_TYPE>((std::numeric_limits<TYPE>::min)());
       std::string str_min = ss.str();
 
       ss.clear();
       ss.str("");
 
- if(std::numeric_limits<T>::is_signed)
- {
- ss << static_cast<signed long long>(std::numeric_limits<T>::max());
- }
- else
- {
- ss << static_cast<unsigned long long>(std::numeric_limits<T>::max());
- }
+ ss << static_cast<CAST_TYPE>((std::numeric_limits<TYPE>::max)());
       std::string str_max = ss.str();
 
       return ((the_value_min == e_float(str_min)) && (the_value_max == e_float(str_max)));
@@ -74,13 +56,11 @@
     class TestCaseGlobalOpsPodBase : public TestCaseReal
     {
     protected:
-
       mutable bool my_test_result;
 
       TestCaseGlobalOpsPodBase() : my_test_result(false) { }
 
     private:
-
       virtual const std::vector<e_float>& control_data(void) const
       {
         static const std::vector<e_float> dummy(1u, ef::one());
@@ -88,7 +68,6 @@
       }
 
     public:
-
       virtual ~TestCaseGlobalOpsPodBase() { }
 
       virtual bool execute(const bool b_write_output) const
@@ -128,6 +107,7 @@
     public:
       TestCase_case_00009_global_ops_pod_equate() { }
       virtual ~TestCase_case_00009_global_ops_pod_equate() { }
+
     private:
       virtual const std::string& name(void) const
       {
@@ -140,18 +120,22 @@
 
         my_test_result = true;
 
- my_test_result &= ::e_float_equate_to::check_type<char>();
- my_test_result &= ::e_float_equate_to::check_type<signed char>();
- my_test_result &= ::e_float_equate_to::check_type<unsigned char>();
- my_test_result &= ::e_float_equate_to::check_type<wchar_t>();
- my_test_result &= ::e_float_equate_to::check_type<signed short>();
- my_test_result &= ::e_float_equate_to::check_type<unsigned short>();
- my_test_result &= ::e_float_equate_to::check_type<signed int>();
- my_test_result &= ::e_float_equate_to::check_type<unsigned int>();
- my_test_result &= ::e_float_equate_to::check_type<signed long>();
- my_test_result &= ::e_float_equate_to::check_type<unsigned long>();
- my_test_result &= ::e_float_equate_to::check_type<signed long long>();
- my_test_result &= ::e_float_equate_to::check_type<unsigned long long>();
+ my_test_result &= (std::numeric_limits<char>::is_signed ? ::e_float_equate_to::check_type<char, signed long long>()
+ : ::e_float_equate_to::check_type<char, unsigned long long>());
+ my_test_result &= (std::numeric_limits<wchar_t>::is_signed ? ::e_float_equate_to::check_type<wchar_t, signed long long>()
+ : ::e_float_equate_to::check_type<wchar_t, unsigned long long>());
+
+ my_test_result &= ::e_float_equate_to::check_type<signed char, signed long long>();
+ my_test_result &= ::e_float_equate_to::check_type<signed short, signed long long>();
+ my_test_result &= ::e_float_equate_to::check_type<signed int, signed long long>();
+ my_test_result &= ::e_float_equate_to::check_type<signed long, signed long long>();
+ my_test_result &= ::e_float_equate_to::check_type<signed long long, signed long long>();
+
+ my_test_result &= ::e_float_equate_to::check_type<unsigned char, unsigned long long>();
+ my_test_result &= ::e_float_equate_to::check_type<unsigned short, unsigned long long>();
+ my_test_result &= ::e_float_equate_to::check_type<unsigned int, unsigned long long>();
+ my_test_result &= ::e_float_equate_to::check_type<unsigned long, unsigned long long>();
+ my_test_result &= ::e_float_equate_to::check_type<unsigned long long, unsigned long long>();
 
         e_float x(123u);
 
@@ -166,6 +150,7 @@
     public:
       TestCase_case_00010_global_ops_pod_operations() { }
       virtual ~TestCase_case_00010_global_ops_pod_operations() { }
+
     private:
       virtual const std::string& name(void) const
       {
@@ -195,8 +180,9 @@
         my_test_result &= (e_float(static_cast<char>('1')) < static_cast<char>('2'));
         my_test_result &= (e_float(static_cast<char>('2')) <= static_cast<char>('2'));
         my_test_result &= (e_float(static_cast<char>('2')) >= static_cast<char>('2'));
+ my_test_result &= (3.14 != ef::pi());
 
- my_test_result &= (e_float("1e1000") > std::numeric_limits<unsigned long long>::max());
+ my_test_result &= (e_float("1e1000") > (std::numeric_limits<unsigned long long>::max)());
         my_test_result &= (ef::zero() == 0);
         my_test_result &= (std::numeric_limits<e_float>::epsilon() > 0);
 


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