|
Boost-Commit : |
Subject: [Boost-commit] svn:boost r54543 - sandbox/numeric_adaptor/libs/numeric_adaptor/test
From: bruno.lalande_at_[hidden]
Date: 2009-06-30 16:47:15
Author: bruno.lalande
Date: 2009-06-30 16:47:14 EDT (Tue, 30 Jun 2009)
New Revision: 54543
URL: http://svn.boost.org/trac/boost/changeset/54543
Log:
Took advantage of ADL, usable now that those functions are free.
Text files modified:
sandbox/numeric_adaptor/libs/numeric_adaptor/test/test_arithmetic.cpp | 2 +-
sandbox/numeric_adaptor/libs/numeric_adaptor/test/test_heron.cpp | 2 +-
sandbox/numeric_adaptor/libs/numeric_adaptor/test/test_trig.cpp | 10 +++++-----
3 files changed, 7 insertions(+), 7 deletions(-)
Modified: sandbox/numeric_adaptor/libs/numeric_adaptor/test/test_arithmetic.cpp
==============================================================================
--- sandbox/numeric_adaptor/libs/numeric_adaptor/test/test_arithmetic.cpp (original)
+++ sandbox/numeric_adaptor/libs/numeric_adaptor/test/test_arithmetic.cpp 2009-06-30 16:47:14 EDT (Tue, 30 Jun 2009)
@@ -55,7 +55,7 @@
BOOST_CHECK_EQUAL((double)-n5, -56.0);
BOOST_CHECK_EQUAL((double)-n6, -2.0);
- BOOST_CHECK_EQUAL((double)boost::numeric_adaptor::abs(-n5), 56.0);
+ BOOST_CHECK_EQUAL((double)abs(-n5), 56.0);
}
int test_main(int, char*[])
Modified: sandbox/numeric_adaptor/libs/numeric_adaptor/test/test_heron.cpp
==============================================================================
--- sandbox/numeric_adaptor/libs/numeric_adaptor/test/test_heron.cpp (original)
+++ sandbox/numeric_adaptor/libs/numeric_adaptor/test/test_heron.cpp 2009-06-30 16:47:14 EDT (Tue, 30 Jun 2009)
@@ -30,7 +30,7 @@
num b = 0.000023;
num c = 31622.77661;
num s((a + b + c) / num(2.0));
- return boost::numeric_adaptor::sqrt(s * (s - a) * (s - b) * (s - c));
+ return sqrt(s * (s - a) * (s - b) * (s - c));
}
int test_main(int, char*[])
Modified: sandbox/numeric_adaptor/libs/numeric_adaptor/test/test_trig.cpp
==============================================================================
--- sandbox/numeric_adaptor/libs/numeric_adaptor/test/test_trig.cpp (original)
+++ sandbox/numeric_adaptor/libs/numeric_adaptor/test/test_trig.cpp 2009-06-30 16:47:14 EDT (Tue, 30 Jun 2009)
@@ -31,11 +31,11 @@
num n1 = 123.0;
num n2 = 456.0;
- BOOST_CHECK_CLOSE((double)boost::numeric_adaptor::cos(n1), ::cos(123.0), epsilon);
- BOOST_CHECK_CLOSE((double)boost::numeric_adaptor::sin(n1), ::sin(123.0), epsilon);
- BOOST_CHECK_CLOSE((double)boost::numeric_adaptor::tan(n1), ::tan(123.0), epsilon);
- BOOST_CHECK_CLOSE((double)boost::numeric_adaptor::atan(n1), ::atan(123.0), epsilon);
- BOOST_CHECK_CLOSE((double)boost::numeric_adaptor::hypot(n1, n2), ::hypot(123.0, 456.0), epsilon);
+ BOOST_CHECK_CLOSE((double)cos(n1), ::cos(123.0), epsilon);
+ BOOST_CHECK_CLOSE((double)sin(n1), ::sin(123.0), epsilon);
+ BOOST_CHECK_CLOSE((double)tan(n1), ::tan(123.0), epsilon);
+ BOOST_CHECK_CLOSE((double)atan(n1), ::atan(123.0), epsilon);
+ BOOST_CHECK_CLOSE((double)hypot(n1, n2), ::hypot(123.0, 456.0), epsilon);
}
int test_main(int, char*[])
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