|
Boost-Commit : |
Subject: [Boost-commit] svn:boost r50341 - in trunk: boost/math/special_functions libs/math/test
From: john_at_[hidden]
Date: 2008-12-21 05:23:53
Author: johnmaddock
Date: 2008-12-21 05:23:52 EST (Sun, 21 Dec 2008)
New Revision: 50341
URL: http://svn.boost.org/trac/boost/changeset/50341
Log:
Fix some Sun-5.9 on Linux failures.
Text files modified:
trunk/boost/math/special_functions/sinc.hpp | 2 +-
trunk/boost/math/special_functions/sinhc.hpp | 3 +--
trunk/libs/math/test/complex_test.cpp | 4 ++--
trunk/libs/math/test/test_expint.cpp | 7 +++++++
trunk/libs/math/test/test_poisson.cpp | 2 +-
5 files changed, 12 insertions(+), 6 deletions(-)
Modified: trunk/boost/math/special_functions/sinc.hpp
==============================================================================
--- trunk/boost/math/special_functions/sinc.hpp (original)
+++ trunk/boost/math/special_functions/sinc.hpp 2008-12-21 05:23:52 EST (Sun, 21 Dec 2008)
@@ -117,7 +117,7 @@
{
#if defined(BOOST_FUNCTION_SCOPE_USING_DECLARATION_BREAKS_ADL) || defined(__GNUC__)
using namespace std;
-#elif defined(BOOST_NO_STDC_NAMESPACE)
+#elif defined(BOOST_NO_STDC_NAMESPACE) && !defined(__SUNPRO_CC)
using ::abs;
using ::sin;
using ::sqrt;
Modified: trunk/boost/math/special_functions/sinhc.hpp
==============================================================================
--- trunk/boost/math/special_functions/sinhc.hpp (original)
+++ trunk/boost/math/special_functions/sinhc.hpp 2008-12-21 05:23:52 EST (Sun, 21 Dec 2008)
@@ -23,7 +23,6 @@
#include <string>
#include <stdexcept>
-
#include <boost/config.hpp>
@@ -114,7 +113,7 @@
{
#if defined(BOOST_FUNCTION_SCOPE_USING_DECLARATION_BREAKS_ADL) || defined(__GNUC__)
using namespace std;
-#elif defined(BOOST_NO_STDC_NAMESPACE)
+#elif defined(BOOST_NO_STDC_NAMESPACE) && !defined(__SUNPRO_CC)
using ::abs;
using ::sinh;
using ::sqrt;
Modified: trunk/libs/math/test/complex_test.cpp
==============================================================================
--- trunk/libs/math/test/complex_test.cpp (original)
+++ trunk/libs/math/test/complex_test.cpp 2008-12-21 05:23:52 EST (Sun, 21 Dec 2008)
@@ -47,7 +47,7 @@
//
bool result = true;
static const std::complex<T> zero(0);
- static const T eps = std::pow(static_cast<T>(std::numeric_limits<T>::radix), 1 - std::numeric_limits<T>::digits);
+ static const T eps = std::pow(static_cast<T>(std::numeric_limits<T>::radix), static_cast<T>(1 - std::numeric_limits<T>::digits));
if(a == zero)
{
if(b != zero)
@@ -258,7 +258,7 @@
typedef std::complex<T> ct;
ct result;
static const T two = 2.0;
- T eps = std::pow(two, 1-std::numeric_limits<T>::digits); // numeric_limits<>::epsilon way too small to be useful on Darwin.
+ T eps = std::pow(two, T(1-std::numeric_limits<T>::digits)); // numeric_limits<>::epsilon way too small to be useful on Darwin.
static const T zero = 0;
static const T mzero = -zero;
static const T one = 1;
Modified: trunk/libs/math/test/test_expint.cpp
==============================================================================
--- trunk/libs/math/test/test_expint.cpp (original)
+++ trunk/libs/math/test/test_expint.cpp 2008-12-21 05:23:52 EST (Sun, 21 Dec 2008)
@@ -115,6 +115,13 @@
".*", 150, 50); // test function
}
add_expected_result(
+ "Sun.*", // compiler
+ ".*", // stdlib
+ ".*", // platform
+ "real_concept", // test type(s)
+ ".*Ei.*", // test data group
+ ".*", 150, 50); // test function
+ add_expected_result(
".*", // compiler
".*", // stdlib
".*", // platform
Modified: trunk/libs/math/test/test_poisson.cpp
==============================================================================
--- trunk/libs/math/test/test_poisson.cpp (original)
+++ trunk/libs/math/test/test_poisson.cpp 2008-12-21 05:23:52 EST (Sun, 21 Dec 2008)
@@ -442,7 +442,7 @@
RealType x = quantile(p1, poisson_quantile_data[i][1]);
BOOST_CHECK_CLOSE_FRACTION(x, poisson_quantile_data[i][2], tol);
x = quantile(complement(p1, poisson_quantile_data[i][1]));
- BOOST_CHECK_CLOSE_FRACTION(x, poisson_quantile_data[i][3], tol);
+ BOOST_CHECK_CLOSE_FRACTION(x, poisson_quantile_data[i][3], tol * 3);
//
// Now with round down to integer:
//
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