Boost logo

Boost-Commit :

From: john_at_[hidden]
Date: 2008-05-18 04:29:52


Author: johnmaddock
Date: 2008-05-18 04:29:50 EDT (Sun, 18 May 2008)
New Revision: 45478
URL: http://svn.boost.org/trac/boost/changeset/45478

Log:
Merged changes from Trunk.
Text files modified:
   sandbox/math_toolkit/boost/math/concepts/real_concept.hpp | 5 ++++-
   sandbox/math_toolkit/boost/math/concepts/std_real_concept.hpp | 10 ++++++++--
   sandbox/math_toolkit/libs/math/doc/sf_and_dist/roadmap.qbk | 3 ++-
   sandbox/math_toolkit/libs/math/test/compile_test/instantiate.hpp | 13 +++++++++----
   sandbox/math_toolkit/libs/math/test/compile_test/sf_modf_incl_test.cpp | 2 +-
   sandbox/math_toolkit/libs/math/test/compile_test/sf_round_incl_test.cpp | 6 +++---
   sandbox/math_toolkit/libs/math/test/compile_test/sf_trunc_incl_test.cpp | 6 +++---
   sandbox/math_toolkit/libs/math/test/compile_test/test_compile_result.hpp | 2 +-
   sandbox/math_toolkit/libs/math/test/pow_test.cpp | 2 +-
   sandbox/math_toolkit/libs/math/test/test_rational_instances/test_rational_double4.cpp | 2 +-
   sandbox/math_toolkit/libs/math/test/test_rational_instances/test_rational_float4.cpp | 2 +-
   sandbox/math_toolkit/libs/math/test/test_rational_instances/test_rational_ldouble4.cpp | 2 +-
   sandbox/math_toolkit/libs/math/test/test_rational_instances/test_rational_real_concept4.cpp | 2 +-
   sandbox/math_toolkit/libs/math/test/test_rationals.cpp | 2 +-
   sandbox/math_toolkit/libs/math/test/test_round.cpp | 4 ++--
   sandbox/math_toolkit/libs/math/vc71_fix/instantiate_all.cpp | 4 +++-
   16 files changed, 42 insertions(+), 25 deletions(-)

Modified: sandbox/math_toolkit/boost/math/concepts/real_concept.hpp
==============================================================================
--- sandbox/math_toolkit/boost/math/concepts/real_concept.hpp (original)
+++ sandbox/math_toolkit/boost/math/concepts/real_concept.hpp 2008-05-18 04:29:50 EDT (Sun, 18 May 2008)
@@ -66,7 +66,10 @@
    real_concept(int c) : m_value(c){}
    real_concept(unsigned long c) : m_value(c){}
    real_concept(long c) : m_value(c){}
-#if defined(BOOST_HAS_LONG_LONG) || defined(__DECCXX) || defined(__SUNPRO_CC)
+#if defined(__DECCXX) || defined(__SUNPRO_CC)
+ real_concept(unsigned long long c) : m_value(static_cast<real_concept_base_type>(c)){}
+ real_concept(long long c) : m_value(static_cast<real_concept_base_type>(c)){}
+#elif defined(BOOST_HAS_LONG_LONG)
    real_concept(unsigned long long c) : m_value(static_cast<real_concept_base_type>(c)){}
    real_concept(long long c) : m_value(static_cast<real_concept_base_type>(c)){}
 #elif defined(BOOST_HAS_MS_INT64)

Modified: sandbox/math_toolkit/boost/math/concepts/std_real_concept.hpp
==============================================================================
--- sandbox/math_toolkit/boost/math/concepts/std_real_concept.hpp (original)
+++ sandbox/math_toolkit/boost/math/concepts/std_real_concept.hpp 2008-05-18 04:29:50 EDT (Sun, 18 May 2008)
@@ -58,7 +58,10 @@
    std_real_concept(int c) : m_value(c){}
    std_real_concept(unsigned long c) : m_value(c){}
    std_real_concept(long c) : m_value(c){}
-#if defined(BOOST_HAS_LONG_LONG) || defined(__DECCXX) || defined(__SUNPRO_CC)
+#if defined(__DECCXX) || defined(__SUNPRO_CC)
+ std_real_concept(unsigned long long c) : m_value(static_cast<std_real_concept_base_type>(c)){}
+ std_real_concept(long long c) : m_value(static_cast<std_real_concept_base_type>(c)){}
+#elif defined(BOOST_HAS_LONG_LONG)
    std_real_concept(unsigned long long c) : m_value(static_cast<std_real_concept_base_type>(c)){}
    std_real_concept(long long c) : m_value(static_cast<std_real_concept_base_type>(c)){}
 #endif
@@ -79,7 +82,10 @@
    std_real_concept& operator=(unsigned int c) { m_value = c; return *this; }
    std_real_concept& operator=(long c) { m_value = c; return *this; }
    std_real_concept& operator=(unsigned long c) { m_value = c; return *this; }
-#if defined(BOOST_HAS_LONG_LONG) || defined(__DECCXX) || defined(__SUNPRO_CC)
+#if defined(__DECCXX) || defined(__SUNPRO_CC)
+ std_real_concept& operator=(unsigned long long c) { m_value = static_cast<std_real_concept_base_type>(c); return *this; }
+ std_real_concept& operator=(long long c) { m_value = static_cast<std_real_concept_base_type>(c); return *this; }
+#elif defined(BOOST_HAS_LONG_LONG)
    std_real_concept& operator=(long long c) { m_value = static_cast<std_real_concept_base_type>(c); return *this; }
    std_real_concept& operator=(unsigned long long c) { m_value = static_cast<std_real_concept_base_type>(c); return *this; }
 #endif

Modified: sandbox/math_toolkit/libs/math/doc/sf_and_dist/roadmap.qbk
==============================================================================
--- sandbox/math_toolkit/libs/math/doc/sf_and_dist/roadmap.qbk (original)
+++ sandbox/math_toolkit/libs/math/doc/sf_and_dist/roadmap.qbk 2008-05-18 04:29:50 EDT (Sun, 18 May 2008)
@@ -71,7 +71,7 @@
 
 SVN Revisions:
 
-Sandbox and trunk last synchonised at revision: 44695.
+Sandbox and trunk last synchonised at revision: 45480.
 
 ]
 [/
@@ -81,3 +81,4 @@
   http://www.boost.org/LICENSE_1_0.txt).
 ]
 
+

Modified: sandbox/math_toolkit/libs/math/test/compile_test/instantiate.hpp
==============================================================================
--- sandbox/math_toolkit/libs/math/test/compile_test/instantiate.hpp (original)
+++ sandbox/math_toolkit/libs/math/test/compile_test/instantiate.hpp 2008-05-18 04:29:50 EDT (Sun, 18 May 2008)
@@ -16,6 +16,8 @@
 #include <boost/math/special_functions.hpp>
 #include <boost/math/concepts/distributions.hpp>
 
+#ifndef BOOST_MATH_INSTANTIATE_MINIMUM
+
 typedef boost::math::policies::policy<> test_policy;
 
 namespace test{
@@ -29,6 +31,7 @@
 BOOST_MATH_DECLARE_DISTRIBUTIONS(double, test_policy)
 
 }
+#endif
 
 namespace boost{ namespace math{
 //
@@ -79,7 +82,7 @@
    function_requires<DistributionConcept<non_central_beta_distribution<RealType> > >();
    function_requires<DistributionConcept<non_central_f_distribution<RealType> > >();
    function_requires<DistributionConcept<non_central_t_distribution<RealType> > >();
-
+#ifndef BOOST_MATH_INSTANTIATE_MINIMUM
    function_requires<DistributionConcept<bernoulli_distribution<RealType, test_policy> > >();
    function_requires<DistributionConcept<beta_distribution<RealType, test_policy> > >();
    function_requires<DistributionConcept<binomial_distribution<RealType, test_policy> > >();
@@ -128,7 +131,7 @@
    function_requires<DistributionConcept<dist_test::non_central_beta > >();
    function_requires<DistributionConcept<dist_test::non_central_f > >();
    function_requires<DistributionConcept<dist_test::non_central_t > >();
-
+#endif
    int i;
    RealType v1(0.5), v2(0.5), v3(0.5);
    boost::math::tgamma(v1);
@@ -242,7 +245,7 @@
 #ifdef BOOST_HAS_LONG_LONG
    boost::math::lltrunc(v1);
    boost::math::llround(v1);
- long long ll;
+ boost::long_long_type ll;
    boost::math::modf(v1, &ll);
 #endif
    boost::math::pow<2>(v1);
@@ -502,7 +505,7 @@
 {
    using namespace boost;
    using namespace boost::math;
-
+#ifndef BOOST_MATH_INSTANTIATE_MINIMUM
    int i = 1;
    long l = 1;
    short s = 1;
@@ -851,7 +854,9 @@
    test::sph_bessel(i, 1);
    test::sph_neumann(i, lr);
    test::sph_neumann(i, i);
+#endif
 }
 
 
 #endif // BOOST_LIBS_MATH_TEST_INSTANTIATE_HPP
+

Modified: sandbox/math_toolkit/libs/math/test/compile_test/sf_modf_incl_test.cpp
==============================================================================
--- sandbox/math_toolkit/libs/math/test/compile_test/sf_modf_incl_test.cpp (original)
+++ sandbox/math_toolkit/libs/math/test/compile_test/sf_modf_incl_test.cpp 2008-05-18 04:29:50 EDT (Sun, 18 May 2008)
@@ -20,7 +20,7 @@
 int ii;
 long ll;
 #ifdef BOOST_HAS_LONG_LONG
-long long llll;
+boost::long_long_type llll;
 #endif
 
 void check()

Modified: sandbox/math_toolkit/libs/math/test/compile_test/sf_round_incl_test.cpp
==============================================================================
--- sandbox/math_toolkit/libs/math/test/compile_test/sf_round_incl_test.cpp (original)
+++ sandbox/math_toolkit/libs/math/test/compile_test/sf_round_incl_test.cpp 2008-05-18 04:29:50 EDT (Sun, 18 May 2008)
@@ -31,10 +31,10 @@
    check_result<long>(boost::math::lround<long double>(l));
 #endif
 #ifdef BOOST_HAS_LONG_LONG
- check_result<long long>(boost::math::llround<float>(f));
- check_result<long long>(boost::math::llround<double>(d));
+ check_result<boost::long_long_type>(boost::math::llround<float>(f));
+ check_result<boost::long_long_type>(boost::math::llround<double>(d));
 #ifndef BOOST_MATH_NO_LONG_DOUBLE_MATH_FUNCTIONS
- check_result<long long>(boost::math::llround<long double>(l));
+ check_result<boost::long_long_type>(boost::math::llround<long double>(l));
 #endif
 #endif
 }

Modified: sandbox/math_toolkit/libs/math/test/compile_test/sf_trunc_incl_test.cpp
==============================================================================
--- sandbox/math_toolkit/libs/math/test/compile_test/sf_trunc_incl_test.cpp (original)
+++ sandbox/math_toolkit/libs/math/test/compile_test/sf_trunc_incl_test.cpp 2008-05-18 04:29:50 EDT (Sun, 18 May 2008)
@@ -31,10 +31,10 @@
    check_result<long>(boost::math::ltrunc<long double>(l));
 #endif
 #ifdef BOOST_HAS_LONG_LONG
- check_result<long long>(boost::math::lltrunc<float>(f));
- check_result<long long>(boost::math::lltrunc<double>(d));
+ check_result<boost::long_long_type>(boost::math::lltrunc<float>(f));
+ check_result<boost::long_long_type>(boost::math::lltrunc<double>(d));
 #ifndef BOOST_MATH_NO_LONG_DOUBLE_MATH_FUNCTIONS
- check_result<long long>(boost::math::lltrunc<long double>(l));
+ check_result<boost::long_long_type>(boost::math::lltrunc<long double>(l));
 #endif
 #endif
 }

Modified: sandbox/math_toolkit/libs/math/test/compile_test/test_compile_result.hpp
==============================================================================
--- sandbox/math_toolkit/libs/math/test/compile_test/test_compile_result.hpp (original)
+++ sandbox/math_toolkit/libs/math/test/compile_test/test_compile_result.hpp 2008-05-18 04:29:50 EDT (Sun, 18 May 2008)
@@ -24,7 +24,7 @@
 inline void check_result_imp(int, int){}
 inline void check_result_imp(long, long){}
 #ifdef BOOST_HAS_LONG_LONG
-inline void check_result_imp(long long, long long){}
+inline void check_result_imp(boost::long_long_type, boost::long_long_type){}
 #endif
 inline void check_result_imp(bool, bool){}
 

Modified: sandbox/math_toolkit/libs/math/test/pow_test.cpp
==============================================================================
--- sandbox/math_toolkit/libs/math/test/pow_test.cpp (original)
+++ sandbox/math_toolkit/libs/math/test/pow_test.cpp 2008-05-18 04:29:50 EDT (Sun, 18 May 2008)
@@ -109,7 +109,7 @@
 #ifndef BOOST_MATH_NO_LONG_DOUBLE_MATH_FUNCTIONS
     BOOST_STATIC_ASSERT((is_same<BOOST_TYPEOF(pow<2>(7.0l)), long double>::value));
 #endif
-};
+}
 
 
 namespace boost { namespace math { namespace policies {

Modified: sandbox/math_toolkit/libs/math/test/test_rational_instances/test_rational_double4.cpp
==============================================================================
--- sandbox/math_toolkit/libs/math/test/test_rational_instances/test_rational_double4.cpp (original)
+++ sandbox/math_toolkit/libs/math/test/test_rational_instances/test_rational_double4.cpp 2008-05-18 04:29:50 EDT (Sun, 18 May 2008)
@@ -6,5 +6,5 @@
 #include "test_rational.hpp"
 
 #ifdef BOOST_HAS_LONG_LONG
-template void do_test_spots<double, unsigned long long>(double, unsigned long long);
+template void do_test_spots<double, boost::ulong_long_type>(double, boost::ulong_long_type);
 #endif

Modified: sandbox/math_toolkit/libs/math/test/test_rational_instances/test_rational_float4.cpp
==============================================================================
--- sandbox/math_toolkit/libs/math/test/test_rational_instances/test_rational_float4.cpp (original)
+++ sandbox/math_toolkit/libs/math/test/test_rational_instances/test_rational_float4.cpp 2008-05-18 04:29:50 EDT (Sun, 18 May 2008)
@@ -7,5 +7,5 @@
 #include "test_rational.hpp"
 
 #ifdef BOOST_HAS_LONG_LONG
-template void do_test_spots<float, unsigned long long>(float, unsigned long long);
+template void do_test_spots<float, boost::ulong_long_type>(float, boost::ulong_long_type);
 #endif

Modified: sandbox/math_toolkit/libs/math/test/test_rational_instances/test_rational_ldouble4.cpp
==============================================================================
--- sandbox/math_toolkit/libs/math/test/test_rational_instances/test_rational_ldouble4.cpp (original)
+++ sandbox/math_toolkit/libs/math/test/test_rational_instances/test_rational_ldouble4.cpp 2008-05-18 04:29:50 EDT (Sun, 18 May 2008)
@@ -7,5 +7,5 @@
 #include "test_rational.hpp"
 
 #ifdef BOOST_HAS_LONG_LONG
-template void do_test_spots<long double, unsigned long long>(long double, unsigned long long);
+template void do_test_spots<long double, boost::ulong_long_type>(long double, boost::ulong_long_type);
 #endif

Modified: sandbox/math_toolkit/libs/math/test/test_rational_instances/test_rational_real_concept4.cpp
==============================================================================
--- sandbox/math_toolkit/libs/math/test/test_rational_instances/test_rational_real_concept4.cpp (original)
+++ sandbox/math_toolkit/libs/math/test/test_rational_instances/test_rational_real_concept4.cpp 2008-05-18 04:29:50 EDT (Sun, 18 May 2008)
@@ -11,6 +11,6 @@
 #include <boost/math/concepts/real_concept.hpp>
 
 #ifdef BOOST_HAS_LONG_LONG
-template void do_test_spots<boost::math::concepts::real_concept, unsigned long long>(boost::math::concepts::real_concept, unsigned long long);
+template void do_test_spots<boost::math::concepts::real_concept, boost::ulong_long_type>(boost::math::concepts::real_concept, boost::ulong_long_type);
 #endif
 #endif

Modified: sandbox/math_toolkit/libs/math/test/test_rationals.cpp
==============================================================================
--- sandbox/math_toolkit/libs/math/test/test_rationals.cpp (original)
+++ sandbox/math_toolkit/libs/math/test/test_rationals.cpp 2008-05-18 04:29:50 EDT (Sun, 18 May 2008)
@@ -20,7 +20,7 @@
    do_test_spots(t, int(0));
    do_test_spots(t, unsigned(0));
 #ifdef BOOST_HAS_LONG_LONG
- do_test_spots(t, (unsigned long long)(0));
+ do_test_spots(t, (boost::ulong_long_type)(0));
 #endif
    do_test_spots(t, float(0));
    do_test_spots(t, T(0));

Modified: sandbox/math_toolkit/libs/math/test/test_round.cpp
==============================================================================
--- sandbox/math_toolkit/libs/math/test/test_round.cpp (original)
+++ sandbox/math_toolkit/libs/math/test/test_round.cpp 2008-05-18 04:29:50 EDT (Sun, 18 May 2008)
@@ -141,9 +141,9 @@
       }
 
 #ifdef BOOST_HAS_LONG_LONG
- if(abs(r) < (std::numeric_limits<long long>::max)())
+ if(abs(r) < (std::numeric_limits<boost::long_long_type>::max)())
       {
- long long ll = boost::math::llround(arg);
+ boost::long_long_type ll = boost::math::llround(arg);
          check_within_half(arg, ll);
          ll = boost::math::lltrunc(arg);
          check_trunc_result(arg, ll);

Modified: sandbox/math_toolkit/libs/math/vc71_fix/instantiate_all.cpp
==============================================================================
--- sandbox/math_toolkit/libs/math/vc71_fix/instantiate_all.cpp (original)
+++ sandbox/math_toolkit/libs/math/vc71_fix/instantiate_all.cpp 2008-05-18 04:29:50 EDT (Sun, 18 May 2008)
@@ -14,8 +14,10 @@
 // as that would lead to recursive project dependencies...
 //
 
-#include "../test/compile_test/instantiate.hpp"
+#define BOOST_MATH_ASSERT_UNDEFINED_POLICY false
+#define BOOST_MATH_INSTANTIATE_MINIMUM
 #include <boost/math/concepts/real_concept.hpp>
+#include "../test/compile_test/instantiate.hpp"
 
 void some_proc()
 {


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