Boost logo

Boost-Commit :

From: john_at_[hidden]
Date: 2007-09-22 05:17:27


Author: johnmaddock
Date: 2007-09-22 05:17:21 EDT (Sat, 22 Sep 2007)
New Revision: 39471
URL: http://svn.boost.org/trac/boost/changeset/39471

Log:
Added needed using declaration to cauchy.hpp.
Added needed #include to config.hpp.
Tightened up compile-tests.
Fixed compile tests so they build with VC++ earlier than VC8sp1.
Text files modified:
   sandbox/math_toolkit/boost/math/distributions/cauchy.hpp | 4 +
   sandbox/math_toolkit/boost/math/tools/config.hpp | 1
   sandbox/math_toolkit/libs/math/test/Jamfile.v2 | 1
   sandbox/math_toolkit/libs/math/test/compile_test/dist_bernoulli_incl_test.cpp | 10 ++++
   sandbox/math_toolkit/libs/math/test/compile_test/dist_beta_incl_test.cpp | 10 ++++
   sandbox/math_toolkit/libs/math/test/compile_test/dist_binomial_incl_test.cpp | 10 ++++
   sandbox/math_toolkit/libs/math/test/compile_test/dist_cauchy_incl_test.cpp | 11 ++++
   sandbox/math_toolkit/libs/math/test/compile_test/dist_chi_squared_incl_test.cpp | 10 ++++
   sandbox/math_toolkit/libs/math/test/compile_test/dist_complement_incl_test.cpp | 12 ++++
   sandbox/math_toolkit/libs/math/test/compile_test/dist_exponential_incl_test.cpp | 10 ++++
   sandbox/math_toolkit/libs/math/test/compile_test/dist_extreme_value_incl_test.cpp | 10 ++++
   sandbox/math_toolkit/libs/math/test/compile_test/dist_fisher_f_incl_test.cpp | 10 ++++
   sandbox/math_toolkit/libs/math/test/compile_test/dist_gamma_incl_test.cpp | 10 ++++
   sandbox/math_toolkit/libs/math/test/compile_test/dist_lognormal_incl_test.cpp | 10 ++++
   sandbox/math_toolkit/libs/math/test/compile_test/dist_neg_binom_incl_test.cpp | 10 ++++
   sandbox/math_toolkit/libs/math/test/compile_test/dist_normal_incl_test.cpp | 10 ++++
   sandbox/math_toolkit/libs/math/test/compile_test/dist_pareto_incl_test.cpp | 10 ++++
   sandbox/math_toolkit/libs/math/test/compile_test/dist_poisson_incl_test.cpp | 10 ++++
   sandbox/math_toolkit/libs/math/test/compile_test/dist_students_t_incl_test.cpp | 10 ++++
   sandbox/math_toolkit/libs/math/test/compile_test/dist_triangular_incl_test.cpp | 10 ++++
   sandbox/math_toolkit/libs/math/test/compile_test/dist_uniform_incl_test.cpp | 10 ++++
   sandbox/math_toolkit/libs/math/test/compile_test/dist_weibull_incl_test.cpp | 10 ++++
   sandbox/math_toolkit/libs/math/test/compile_test/sf_bessel_incl_test.cpp | 55 ++++++++++++---------
   sandbox/math_toolkit/libs/math/test/compile_test/sf_beta_incl_test.cpp | 1
   sandbox/math_toolkit/libs/math/test/compile_test/sf_binomial_incl_test.cpp | 14 ++++-
   sandbox/math_toolkit/libs/math/test/compile_test/sf_cbrt_incl_test.cpp | 14 ++++-
   sandbox/math_toolkit/libs/math/test/compile_test/sf_cos_pi_incl_test.cpp | 15 ++++-
   sandbox/math_toolkit/libs/math/test/compile_test/sf_digamma_incl_test.cpp | 14 ++++-
   sandbox/math_toolkit/libs/math/test/compile_test/sf_ellint_1_incl_test.cpp | 20 +++++--
   sandbox/math_toolkit/libs/math/test/compile_test/sf_ellint_2_incl_test.cpp | 20 +++++--
   sandbox/math_toolkit/libs/math/test/compile_test/sf_ellint_3_incl_test.cpp | 20 +++++--
   sandbox/math_toolkit/libs/math/test/compile_test/sf_ellint_rc_incl_test.cpp | 14 ++++-
   sandbox/math_toolkit/libs/math/test/compile_test/sf_ellint_rd_incl_test.cpp | 14 ++++-
   sandbox/math_toolkit/libs/math/test/compile_test/sf_ellint_rf_incl_test.cpp | 14 ++++-
   sandbox/math_toolkit/libs/math/test/compile_test/sf_ellint_rj_incl_test.cpp | 14 ++++-
   sandbox/math_toolkit/libs/math/test/compile_test/sf_erf_incl_test.cpp | 33 ++++++++-----
   sandbox/math_toolkit/libs/math/test/compile_test/sf_expm1_incl_test.cpp | 14 ++++-
   sandbox/math_toolkit/libs/math/test/compile_test/sf_factorials_incl_test.cpp | 39 +++++++++------
   sandbox/math_toolkit/libs/math/test/compile_test/sf_fpclassify_incl_test.cpp | 39 +++++++++------
   sandbox/math_toolkit/libs/math/test/compile_test/sf_gamma_incl_test.cpp | 95 ++++++++++++++++++++-----------------
   sandbox/math_toolkit/libs/math/test/compile_test/sf_hermite_incl_test.cpp | 14 ++++-
   sandbox/math_toolkit/libs/math/test/compile_test/sf_hypot_incl_test.cpp | 14 ++++-
   sandbox/math_toolkit/libs/math/test/compile_test/sf_laguerre_incl_test.cpp | 24 ++++++---
   sandbox/math_toolkit/libs/math/test/compile_test/sf_legendre_incl_test.cpp | 27 ++++++----
   sandbox/math_toolkit/libs/math/test/compile_test/sf_log1p_incl_test.cpp | 14 ++++-
   sandbox/math_toolkit/libs/math/test/compile_test/sf_powm1_incl_test.cpp | 14 ++++-
   sandbox/math_toolkit/libs/math/test/compile_test/sf_sign_incl_test.cpp | 27 ++++++----
   sandbox/math_toolkit/libs/math/test/compile_test/sf_sin_pi_incl_test.cpp | 15 ++++-
   sandbox/math_toolkit/libs/math/test/compile_test/sf_sinc_incl_test.cpp | 14 ++++-
   sandbox/math_toolkit/libs/math/test/compile_test/sf_sinhc_incl_test.cpp | 14 ++++-
   sandbox/math_toolkit/libs/math/test/compile_test/sf_sph_harm_incl_test.cpp | 31 +++++++----
   sandbox/math_toolkit/libs/math/test/compile_test/sf_sqrt1pm1_incl_test.cpp | 14 ++++-
   sandbox/math_toolkit/libs/math/test/compile_test/test_compile_result.hpp | 98 +++++++++++++++++++++++++++++++++++++--
   sandbox/math_toolkit/libs/math/test/compile_test/tools_roots_inc_test.cpp | 33 ++++++++----
   sandbox/math_toolkit/libs/math/test/compile_test/tools_series_inc_test.cpp | 22 ++++++--
   sandbox/math_toolkit/libs/math/test/compile_test/tools_test_inc_test.cpp | 26 +++++++--
   56 files changed, 795 insertions(+), 254 deletions(-)

Modified: sandbox/math_toolkit/boost/math/distributions/cauchy.hpp
==============================================================================
--- sandbox/math_toolkit/boost/math/distributions/cauchy.hpp (original)
+++ sandbox/math_toolkit/boost/math/distributions/cauchy.hpp 2007-09-22 05:17:21 EDT (Sat, 22 Sep 2007)
@@ -194,7 +194,9 @@
 template <class RealType, class Policy>
 inline RealType pdf(const cauchy_distribution<RealType, Policy>& dist, const RealType& x)
 {
- static const char* function = "boost::math::pdf(cauchy<%1%>&, %1%)";
+ BOOST_MATH_STD_USING // for ADL of std functions
+
+ static const char* function = "boost::math::pdf(cauchy<%1%>&, %1%)";
    RealType result;
    RealType location = dist.location();
    RealType scale = dist.scale();

Modified: sandbox/math_toolkit/boost/math/tools/config.hpp
==============================================================================
--- sandbox/math_toolkit/boost/math/tools/config.hpp (original)
+++ sandbox/math_toolkit/boost/math/tools/config.hpp 2007-09-22 05:17:21 EDT (Sat, 22 Sep 2007)
@@ -4,6 +4,7 @@
 #include <boost/cstdint.hpp> // for boost::uintmax_t
 #include <boost/config.hpp>
 #include <algorithm> // for min and max
+#include <cmath>
 
 #include <boost/math/tools/user.hpp>
 

Modified: sandbox/math_toolkit/libs/math/test/Jamfile.v2
==============================================================================
--- sandbox/math_toolkit/libs/math/test/Jamfile.v2 (original)
+++ sandbox/math_toolkit/libs/math/test/Jamfile.v2 2007-09-22 05:17:21 EDT (Sat, 22 Sep 2007)
@@ -195,3 +195,4 @@
 
 
 
+

Modified: sandbox/math_toolkit/libs/math/test/compile_test/dist_bernoulli_incl_test.cpp
==============================================================================
--- sandbox/math_toolkit/libs/math/test/compile_test/dist_bernoulli_incl_test.cpp (original)
+++ sandbox/math_toolkit/libs/math/test/compile_test/dist_bernoulli_incl_test.cpp 2007-09-22 05:17:21 EDT (Sat, 22 Sep 2007)
@@ -7,6 +7,16 @@
 // #includes all the files that it needs to.
 //
 #include <boost/math/distributions/bernoulli.hpp>
+//
+// Note this header includes no other headers, this is
+// important if this test is to be meaningful:
+//
+#include "test_compile_result.hpp"
+
+void check()
+{
+ TEST_DIST_FUNC(bernoulli)
+}
 
 template class boost::math::bernoulli_distribution<float, boost::math::policies::policy<> >;
 template class boost::math::bernoulli_distribution<double, boost::math::policies::policy<> >;

Modified: sandbox/math_toolkit/libs/math/test/compile_test/dist_beta_incl_test.cpp
==============================================================================
--- sandbox/math_toolkit/libs/math/test/compile_test/dist_beta_incl_test.cpp (original)
+++ sandbox/math_toolkit/libs/math/test/compile_test/dist_beta_incl_test.cpp 2007-09-22 05:17:21 EDT (Sat, 22 Sep 2007)
@@ -7,6 +7,16 @@
 // #includes all the files that it needs to.
 //
 #include <boost/math/distributions/beta.hpp>
+//
+// Note this header includes no other headers, this is
+// important if this test is to be meaningful:
+//
+#include "test_compile_result.hpp"
+
+void check()
+{
+ TEST_DIST_FUNC(beta)
+}
 
 template class boost::math::beta_distribution<double, boost::math::policies::policy<> >;
 template class boost::math::beta_distribution<float, boost::math::policies::policy<> >;

Modified: sandbox/math_toolkit/libs/math/test/compile_test/dist_binomial_incl_test.cpp
==============================================================================
--- sandbox/math_toolkit/libs/math/test/compile_test/dist_binomial_incl_test.cpp (original)
+++ sandbox/math_toolkit/libs/math/test/compile_test/dist_binomial_incl_test.cpp 2007-09-22 05:17:21 EDT (Sat, 22 Sep 2007)
@@ -7,6 +7,16 @@
 // #includes all the files that it needs to.
 //
 #include <boost/math/distributions/binomial.hpp>
+//
+// Note this header includes no other headers, this is
+// important if this test is to be meaningful:
+//
+#include "test_compile_result.hpp"
+
+void check()
+{
+ TEST_DIST_FUNC(binomial)
+}
 
 template class boost::math::binomial_distribution<float, boost::math::policies::policy<> >;
 template class boost::math::binomial_distribution<double, boost::math::policies::policy<> >;

Modified: sandbox/math_toolkit/libs/math/test/compile_test/dist_cauchy_incl_test.cpp
==============================================================================
--- sandbox/math_toolkit/libs/math/test/compile_test/dist_cauchy_incl_test.cpp (original)
+++ sandbox/math_toolkit/libs/math/test/compile_test/dist_cauchy_incl_test.cpp 2007-09-22 05:17:21 EDT (Sat, 22 Sep 2007)
@@ -6,7 +6,18 @@
 // Basic sanity check that header <boost/math/distributions/cauchy.hpp>
 // #includes all the files that it needs to.
 //
+#define BOOST_MATH_ASSERT_UNDEFINED_POLICY false
 #include <boost/math/distributions/cauchy.hpp>
+//
+// Note this header includes no other headers, this is
+// important if this test is to be meaningful:
+//
+#include "test_compile_result.hpp"
+
+void check()
+{
+ TEST_DIST_FUNC(cauchy)
+}
 
 template class boost::math::cauchy_distribution<float, boost::math::policies::policy<> >;
 template class boost::math::cauchy_distribution<double, boost::math::policies::policy<> >;

Modified: sandbox/math_toolkit/libs/math/test/compile_test/dist_chi_squared_incl_test.cpp
==============================================================================
--- sandbox/math_toolkit/libs/math/test/compile_test/dist_chi_squared_incl_test.cpp (original)
+++ sandbox/math_toolkit/libs/math/test/compile_test/dist_chi_squared_incl_test.cpp 2007-09-22 05:17:21 EDT (Sat, 22 Sep 2007)
@@ -7,6 +7,16 @@
 // #includes all the files that it needs to.
 //
 #include <boost/math/distributions/chi_squared.hpp>
+//
+// Note this header includes no other headers, this is
+// important if this test is to be meaningful:
+//
+#include "test_compile_result.hpp"
+
+void check()
+{
+ TEST_DIST_FUNC(chi_squared)
+}
 
 template class boost::math::chi_squared_distribution<float, boost::math::policies::policy<> >;
 template class boost::math::chi_squared_distribution<double, boost::math::policies::policy<> >;

Modified: sandbox/math_toolkit/libs/math/test/compile_test/dist_complement_incl_test.cpp
==============================================================================
--- sandbox/math_toolkit/libs/math/test/compile_test/dist_complement_incl_test.cpp (original)
+++ sandbox/math_toolkit/libs/math/test/compile_test/dist_complement_incl_test.cpp 2007-09-22 05:17:21 EDT (Sat, 22 Sep 2007)
@@ -7,4 +7,16 @@
 // #includes all the files that it needs to.
 //
 #include <boost/math/distributions/complement.hpp>
+//
+// Note this header includes no other headers, this is
+// important if this test is to be meaningful:
+//
+#include "test_compile_result.hpp"
 
+void check()
+{
+ boost::math::complement(f, f);
+ boost::math::complement(f, f, d);
+ boost::math::complement(f, f, d, l);
+ boost::math::complement(f, f, d, l, i);
+}

Modified: sandbox/math_toolkit/libs/math/test/compile_test/dist_exponential_incl_test.cpp
==============================================================================
--- sandbox/math_toolkit/libs/math/test/compile_test/dist_exponential_incl_test.cpp (original)
+++ sandbox/math_toolkit/libs/math/test/compile_test/dist_exponential_incl_test.cpp 2007-09-22 05:17:21 EDT (Sat, 22 Sep 2007)
@@ -7,6 +7,16 @@
 // #includes all the files that it needs to.
 //
 #include <boost/math/distributions/exponential.hpp>
+//
+// Note this header includes no other headers, this is
+// important if this test is to be meaningful:
+//
+#include "test_compile_result.hpp"
+
+void check()
+{
+ TEST_DIST_FUNC(exponential)
+}
 
 template class boost::math::exponential_distribution<float, boost::math::policies::policy<> >;
 template class boost::math::exponential_distribution<double, boost::math::policies::policy<> >;

Modified: sandbox/math_toolkit/libs/math/test/compile_test/dist_extreme_value_incl_test.cpp
==============================================================================
--- sandbox/math_toolkit/libs/math/test/compile_test/dist_extreme_value_incl_test.cpp (original)
+++ sandbox/math_toolkit/libs/math/test/compile_test/dist_extreme_value_incl_test.cpp 2007-09-22 05:17:21 EDT (Sat, 22 Sep 2007)
@@ -7,6 +7,16 @@
 // #includes all the files that it needs to.
 //
 #include <boost/math/distributions/extreme_value.hpp>
+//
+// Note this header includes no other headers, this is
+// important if this test is to be meaningful:
+//
+#include "test_compile_result.hpp"
+
+void check()
+{
+ TEST_DIST_FUNC(extreme_value)
+}
 
 template class boost::math::extreme_value_distribution<float, boost::math::policies::policy<> >;
 template class boost::math::extreme_value_distribution<double, boost::math::policies::policy<> >;

Modified: sandbox/math_toolkit/libs/math/test/compile_test/dist_fisher_f_incl_test.cpp
==============================================================================
--- sandbox/math_toolkit/libs/math/test/compile_test/dist_fisher_f_incl_test.cpp (original)
+++ sandbox/math_toolkit/libs/math/test/compile_test/dist_fisher_f_incl_test.cpp 2007-09-22 05:17:21 EDT (Sat, 22 Sep 2007)
@@ -7,6 +7,16 @@
 // #includes all the files that it needs to.
 //
 #include <boost/math/distributions/fisher_f.hpp>
+//
+// Note this header includes no other headers, this is
+// important if this test is to be meaningful:
+//
+#include "test_compile_result.hpp"
+
+void check()
+{
+ TEST_DIST_FUNC(fisher_f)
+}
 
 template class boost::math::fisher_f_distribution<float, boost::math::policies::policy<> >;
 template class boost::math::fisher_f_distribution<double, boost::math::policies::policy<> >;

Modified: sandbox/math_toolkit/libs/math/test/compile_test/dist_gamma_incl_test.cpp
==============================================================================
--- sandbox/math_toolkit/libs/math/test/compile_test/dist_gamma_incl_test.cpp (original)
+++ sandbox/math_toolkit/libs/math/test/compile_test/dist_gamma_incl_test.cpp 2007-09-22 05:17:21 EDT (Sat, 22 Sep 2007)
@@ -7,6 +7,16 @@
 // #includes all the files that it needs to.
 //
 #include <boost/math/distributions/gamma.hpp>
+//
+// Note this header includes no other headers, this is
+// important if this test is to be meaningful:
+//
+#include "test_compile_result.hpp"
+
+void check()
+{
+ TEST_DIST_FUNC(gamma)
+}
 
 template class boost::math::gamma_distribution<float, boost::math::policies::policy<> >;
 template class boost::math::gamma_distribution<double, boost::math::policies::policy<> >;

Modified: sandbox/math_toolkit/libs/math/test/compile_test/dist_lognormal_incl_test.cpp
==============================================================================
--- sandbox/math_toolkit/libs/math/test/compile_test/dist_lognormal_incl_test.cpp (original)
+++ sandbox/math_toolkit/libs/math/test/compile_test/dist_lognormal_incl_test.cpp 2007-09-22 05:17:21 EDT (Sat, 22 Sep 2007)
@@ -7,6 +7,16 @@
 // #includes all the files that it needs to.
 //
 #include <boost/math/distributions/lognormal.hpp>
+//
+// Note this header includes no other headers, this is
+// important if this test is to be meaningful:
+//
+#include "test_compile_result.hpp"
+
+void check()
+{
+ TEST_DIST_FUNC(lognormal)
+}
 
 template class boost::math::lognormal_distribution<float, boost::math::policies::policy<> >;
 template class boost::math::lognormal_distribution<double, boost::math::policies::policy<> >;

Modified: sandbox/math_toolkit/libs/math/test/compile_test/dist_neg_binom_incl_test.cpp
==============================================================================
--- sandbox/math_toolkit/libs/math/test/compile_test/dist_neg_binom_incl_test.cpp (original)
+++ sandbox/math_toolkit/libs/math/test/compile_test/dist_neg_binom_incl_test.cpp 2007-09-22 05:17:21 EDT (Sat, 22 Sep 2007)
@@ -7,6 +7,16 @@
 // #includes all the files that it needs to.
 //
 #include <boost/math/distributions/negative_binomial.hpp>
+//
+// Note this header includes no other headers, this is
+// important if this test is to be meaningful:
+//
+#include "test_compile_result.hpp"
+
+void check()
+{
+ TEST_DIST_FUNC(negative_binomial)
+}
 
 template class boost::math::negative_binomial_distribution<float, boost::math::policies::policy<> >;
 template class boost::math::negative_binomial_distribution<double, boost::math::policies::policy<> >;

Modified: sandbox/math_toolkit/libs/math/test/compile_test/dist_normal_incl_test.cpp
==============================================================================
--- sandbox/math_toolkit/libs/math/test/compile_test/dist_normal_incl_test.cpp (original)
+++ sandbox/math_toolkit/libs/math/test/compile_test/dist_normal_incl_test.cpp 2007-09-22 05:17:21 EDT (Sat, 22 Sep 2007)
@@ -7,6 +7,16 @@
 // #includes all the files that it needs to.
 //
 #include <boost/math/distributions/normal.hpp>
+//
+// Note this header includes no other headers, this is
+// important if this test is to be meaningful:
+//
+#include "test_compile_result.hpp"
+
+void check()
+{
+ TEST_DIST_FUNC(normal)
+}
 
 template class boost::math::normal_distribution<float, boost::math::policies::policy<> >;
 template class boost::math::normal_distribution<double, boost::math::policies::policy<> >;

Modified: sandbox/math_toolkit/libs/math/test/compile_test/dist_pareto_incl_test.cpp
==============================================================================
--- sandbox/math_toolkit/libs/math/test/compile_test/dist_pareto_incl_test.cpp (original)
+++ sandbox/math_toolkit/libs/math/test/compile_test/dist_pareto_incl_test.cpp 2007-09-22 05:17:21 EDT (Sat, 22 Sep 2007)
@@ -7,6 +7,16 @@
 // #includes all the files that it needs to.
 //
 #include <boost/math/distributions/pareto.hpp>
+//
+// Note this header includes no other headers, this is
+// important if this test is to be meaningful:
+//
+#include "test_compile_result.hpp"
+
+void check()
+{
+ TEST_DIST_FUNC(pareto)
+}
 
 template class boost::math::pareto_distribution<float, boost::math::policies::policy<> >;
 template class boost::math::pareto_distribution<double, boost::math::policies::policy<> >;

Modified: sandbox/math_toolkit/libs/math/test/compile_test/dist_poisson_incl_test.cpp
==============================================================================
--- sandbox/math_toolkit/libs/math/test/compile_test/dist_poisson_incl_test.cpp (original)
+++ sandbox/math_toolkit/libs/math/test/compile_test/dist_poisson_incl_test.cpp 2007-09-22 05:17:21 EDT (Sat, 22 Sep 2007)
@@ -7,6 +7,16 @@
 // #includes all the files that it needs to.
 //
 #include <boost/math/distributions/poisson.hpp>
+//
+// Note this header includes no other headers, this is
+// important if this test is to be meaningful:
+//
+#include "test_compile_result.hpp"
+
+void check()
+{
+ TEST_DIST_FUNC(poisson)
+}
 
 template class boost::math::poisson_distribution<float, boost::math::policies::policy<> >;
 template class boost::math::poisson_distribution<double, boost::math::policies::policy<> >;

Modified: sandbox/math_toolkit/libs/math/test/compile_test/dist_students_t_incl_test.cpp
==============================================================================
--- sandbox/math_toolkit/libs/math/test/compile_test/dist_students_t_incl_test.cpp (original)
+++ sandbox/math_toolkit/libs/math/test/compile_test/dist_students_t_incl_test.cpp 2007-09-22 05:17:21 EDT (Sat, 22 Sep 2007)
@@ -7,6 +7,16 @@
 // #includes all the files that it needs to.
 //
 #include <boost/math/distributions/students_t.hpp>
+//
+// Note this header includes no other headers, this is
+// important if this test is to be meaningful:
+//
+#include "test_compile_result.hpp"
+
+void check()
+{
+ TEST_DIST_FUNC(students_t)
+}
 
 template class boost::math::students_t_distribution<float, boost::math::policies::policy<> >;
 template class boost::math::students_t_distribution<double, boost::math::policies::policy<> >;

Modified: sandbox/math_toolkit/libs/math/test/compile_test/dist_triangular_incl_test.cpp
==============================================================================
--- sandbox/math_toolkit/libs/math/test/compile_test/dist_triangular_incl_test.cpp (original)
+++ sandbox/math_toolkit/libs/math/test/compile_test/dist_triangular_incl_test.cpp 2007-09-22 05:17:21 EDT (Sat, 22 Sep 2007)
@@ -7,6 +7,16 @@
 // #includes all the files that it needs to.
 //
 #include <boost/math/distributions/triangular.hpp>
+//
+// Note this header includes no other headers, this is
+// important if this test is to be meaningful:
+//
+#include "test_compile_result.hpp"
+
+void check()
+{
+ TEST_DIST_FUNC(triangular)
+}
 
 template class boost::math::triangular_distribution<float, boost::math::policies::policy<> >;
 template class boost::math::triangular_distribution<double, boost::math::policies::policy<> >;

Modified: sandbox/math_toolkit/libs/math/test/compile_test/dist_uniform_incl_test.cpp
==============================================================================
--- sandbox/math_toolkit/libs/math/test/compile_test/dist_uniform_incl_test.cpp (original)
+++ sandbox/math_toolkit/libs/math/test/compile_test/dist_uniform_incl_test.cpp 2007-09-22 05:17:21 EDT (Sat, 22 Sep 2007)
@@ -7,6 +7,16 @@
 // #includes all the files that it needs to.
 //
 #include <boost/math/distributions/uniform.hpp>
+//
+// Note this header includes no other headers, this is
+// important if this test is to be meaningful:
+//
+#include "test_compile_result.hpp"
+
+void check()
+{
+ TEST_DIST_FUNC(uniform)
+}
 
 template class boost::math::uniform_distribution<float, boost::math::policies::policy<> >;
 template class boost::math::uniform_distribution<double, boost::math::policies::policy<> >;

Modified: sandbox/math_toolkit/libs/math/test/compile_test/dist_weibull_incl_test.cpp
==============================================================================
--- sandbox/math_toolkit/libs/math/test/compile_test/dist_weibull_incl_test.cpp (original)
+++ sandbox/math_toolkit/libs/math/test/compile_test/dist_weibull_incl_test.cpp 2007-09-22 05:17:21 EDT (Sat, 22 Sep 2007)
@@ -7,6 +7,16 @@
 // #includes all the files that it needs to.
 //
 #include <boost/math/distributions/weibull.hpp>
+//
+// Note this header includes no other headers, this is
+// important if this test is to be meaningful:
+//
+#include "test_compile_result.hpp"
+
+void check()
+{
+ TEST_DIST_FUNC(weibull)
+}
 
 template class boost::math::weibull_distribution<float, boost::math::policies::policy<> >;
 template class boost::math::weibull_distribution<double, boost::math::policies::policy<> >;

Modified: sandbox/math_toolkit/libs/math/test/compile_test/sf_bessel_incl_test.cpp
==============================================================================
--- sandbox/math_toolkit/libs/math/test/compile_test/sf_bessel_incl_test.cpp (original)
+++ sandbox/math_toolkit/libs/math/test/compile_test/sf_bessel_incl_test.cpp 2007-09-22 05:17:21 EDT (Sat, 22 Sep 2007)
@@ -7,28 +7,35 @@
 // #includes all the files that it needs to.
 //
 #include <boost/math/special_functions/bessel.hpp>
+//
+// Note this header includes no other headers, this is
+// important if this test is to be meaningful:
+//
+#include "test_compile_result.hpp"
 
-template float boost::math::cyl_bessel_j<float>(float, float);
-template double boost::math::cyl_bessel_j<double>(double, double);
-template long double boost::math::cyl_bessel_j<long double>(long double, long double);
-
-template float boost::math::cyl_neumann<float>(float, float);
-template double boost::math::cyl_neumann<double>(double, double);
-template long double boost::math::cyl_neumann<long double>(long double, long double);
-
-template float boost::math::cyl_bessel_i<float>(float, float);
-template double boost::math::cyl_bessel_i<double>(double, double);
-template long double boost::math::cyl_bessel_i<long double>(long double, long double);
-
-template float boost::math::cyl_bessel_k<float>(float, float);
-template double boost::math::cyl_bessel_k<double>(double, double);
-template long double boost::math::cyl_bessel_k<long double>(long double, long double);
-
-template float boost::math::sph_bessel<float>(unsigned, float);
-template double boost::math::sph_bessel<double>(unsigned, double);
-template long double boost::math::sph_bessel<long double>(unsigned, long double);
-
-template float boost::math::sph_neumann<float>(unsigned, float);
-template double boost::math::sph_neumann<double>(unsigned, double);
-template long double boost::math::sph_neumann<long double>(unsigned, long double);
-
+void check()
+{
+ check_result<float>(boost::math::cyl_bessel_j<float>(f, f));
+ check_result<double>(boost::math::cyl_bessel_j<double>(d, d));
+ check_result<long double>(boost::math::cyl_bessel_j<long double>(l, l));
+
+ check_result<float>(boost::math::cyl_neumann<float>(f, f));
+ check_result<double>(boost::math::cyl_neumann<double>(d, d));
+ check_result<long double>(boost::math::cyl_neumann<long double>(l, l));
+
+ check_result<float>(boost::math::cyl_bessel_i<float>(f, f));
+ check_result<double>(boost::math::cyl_bessel_i<double>(d, d));
+ check_result<long double>(boost::math::cyl_bessel_i<long double>(l, l));
+
+ check_result<float>(boost::math::cyl_bessel_k<float>(f, f));
+ check_result<double>(boost::math::cyl_bessel_k<double>(d, d));
+ check_result<long double>(boost::math::cyl_bessel_k<long double>(l, l));
+
+ check_result<float>(boost::math::sph_bessel<float>(u, f));
+ check_result<double>(boost::math::sph_bessel<double>(u, d));
+ check_result<long double>(boost::math::sph_bessel<long double>(u, l));
+
+ check_result<float>(boost::math::sph_neumann<float>(u, f));
+ check_result<double>(boost::math::sph_neumann<double>(u, d));
+ check_result<long double>(boost::math::sph_neumann<long double>(u, l));
+}

Modified: sandbox/math_toolkit/libs/math/test/compile_test/sf_beta_incl_test.cpp
==============================================================================
--- sandbox/math_toolkit/libs/math/test/compile_test/sf_beta_incl_test.cpp (original)
+++ sandbox/math_toolkit/libs/math/test/compile_test/sf_beta_incl_test.cpp 2007-09-22 05:17:21 EDT (Sat, 22 Sep 2007)
@@ -31,3 +31,4 @@
    check_result<double>(boost::math::ibeta_inva<double>(d, d, d));
    check_result<long double>(boost::math::ibeta_inva<long double>(l, l, l));
 }
+

Modified: sandbox/math_toolkit/libs/math/test/compile_test/sf_binomial_incl_test.cpp
==============================================================================
--- sandbox/math_toolkit/libs/math/test/compile_test/sf_binomial_incl_test.cpp (original)
+++ sandbox/math_toolkit/libs/math/test/compile_test/sf_binomial_incl_test.cpp 2007-09-22 05:17:21 EDT (Sat, 22 Sep 2007)
@@ -7,7 +7,15 @@
 // #includes all the files that it needs to.
 //
 #include <boost/math/special_functions/binomial.hpp>
+//
+// Note this header includes no other headers, this is
+// important if this test is to be meaningful:
+//
+#include "test_compile_result.hpp"
 
-template float boost::math::binomial_coefficient<float>(unsigned, unsigned);
-template double boost::math::binomial_coefficient<double>(unsigned, unsigned);
-template long double boost::math::binomial_coefficient<long double>(unsigned, unsigned);
+void check()
+{
+ check_result<float>(boost::math::binomial_coefficient<float>(u, u));
+ check_result<double>(boost::math::binomial_coefficient<double>(u, u));
+ check_result<long double>(boost::math::binomial_coefficient<long double>(u, u));
+}

Modified: sandbox/math_toolkit/libs/math/test/compile_test/sf_cbrt_incl_test.cpp
==============================================================================
--- sandbox/math_toolkit/libs/math/test/compile_test/sf_cbrt_incl_test.cpp (original)
+++ sandbox/math_toolkit/libs/math/test/compile_test/sf_cbrt_incl_test.cpp 2007-09-22 05:17:21 EDT (Sat, 22 Sep 2007)
@@ -7,7 +7,15 @@
 // #includes all the files that it needs to.
 //
 #include <boost/math/special_functions/cbrt.hpp>
+//
+// Note this header includes no other headers, this is
+// important if this test is to be meaningful:
+//
+#include "test_compile_result.hpp"
 
-template float boost::math::cbrt<float>(float);
-template double boost::math::cbrt<double>(double);
-template long double boost::math::cbrt<long double>(long double);
+void check()
+{
+ check_result<float>(boost::math::cbrt<float>(f));
+ check_result<double>(boost::math::cbrt<double>(d));
+ check_result<long double>(boost::math::cbrt<long double>(l));
+}

Modified: sandbox/math_toolkit/libs/math/test/compile_test/sf_cos_pi_incl_test.cpp
==============================================================================
--- sandbox/math_toolkit/libs/math/test/compile_test/sf_cos_pi_incl_test.cpp (original)
+++ sandbox/math_toolkit/libs/math/test/compile_test/sf_cos_pi_incl_test.cpp 2007-09-22 05:17:21 EDT (Sat, 22 Sep 2007)
@@ -7,8 +7,15 @@
 // #includes all the files that it needs to.
 //
 #include <boost/math/special_functions/cos_pi.hpp>
+//
+// Note this header includes no other headers, this is
+// important if this test is to be meaningful:
+//
+#include "test_compile_result.hpp"
 
-template float boost::math::cos_pi<float>(float);
-template double boost::math::cos_pi<double>(double);
-template long double boost::math::cos_pi<long double>(long double);
-
+void check()
+{
+ check_result<float>(boost::math::cos_pi<float>(f));
+ check_result<double>(boost::math::cos_pi<double>(d));
+ check_result<long double>(boost::math::cos_pi<long double>(l));
+}

Modified: sandbox/math_toolkit/libs/math/test/compile_test/sf_digamma_incl_test.cpp
==============================================================================
--- sandbox/math_toolkit/libs/math/test/compile_test/sf_digamma_incl_test.cpp (original)
+++ sandbox/math_toolkit/libs/math/test/compile_test/sf_digamma_incl_test.cpp 2007-09-22 05:17:21 EDT (Sat, 22 Sep 2007)
@@ -7,7 +7,15 @@
 // #includes all the files that it needs to.
 //
 #include <boost/math/special_functions/digamma.hpp>
+//
+// Note this header includes no other headers, this is
+// important if this test is to be meaningful:
+//
+#include "test_compile_result.hpp"
 
-template float boost::math::digamma<float>(float);
-template double boost::math::digamma<double>(double);
-template long double boost::math::digamma<long double>(long double);
+void check()
+{
+ check_result<float>(boost::math::digamma<float>(f));
+ check_result<double>(boost::math::digamma<double>(d));
+ check_result<long double>(boost::math::digamma<long double>(l));
+}
\ No newline at end of file

Modified: sandbox/math_toolkit/libs/math/test/compile_test/sf_ellint_1_incl_test.cpp
==============================================================================
--- sandbox/math_toolkit/libs/math/test/compile_test/sf_ellint_1_incl_test.cpp (original)
+++ sandbox/math_toolkit/libs/math/test/compile_test/sf_ellint_1_incl_test.cpp 2007-09-22 05:17:21 EDT (Sat, 22 Sep 2007)
@@ -7,11 +7,19 @@
 // #includes all the files that it needs to.
 //
 #include <boost/math/special_functions/ellint_1.hpp>
+//
+// Note this header includes no other headers, this is
+// important if this test is to be meaningful:
+//
+#include "test_compile_result.hpp"
 
-template float boost::math::ellint_1<float>(float, float);
-template double boost::math::ellint_1<double>(double, double);
-template long double boost::math::ellint_1<long double>(long double, long double);
+void check()
+{
+ check_result<float>(boost::math::ellint_1<float>(f, f));
+ check_result<double>(boost::math::ellint_1<double>(d, d));
+ check_result<long double>(boost::math::ellint_1<long double>(l, l));
 
-template float boost::math::ellint_1<float>(float);
-template double boost::math::ellint_1<double>(double);
-template long double boost::math::ellint_1<long double>(long double);
+ check_result<float>(boost::math::ellint_1<float>(f));
+ check_result<double>(boost::math::ellint_1<double>(d));
+ check_result<long double>(boost::math::ellint_1<long double>(l));
+}

Modified: sandbox/math_toolkit/libs/math/test/compile_test/sf_ellint_2_incl_test.cpp
==============================================================================
--- sandbox/math_toolkit/libs/math/test/compile_test/sf_ellint_2_incl_test.cpp (original)
+++ sandbox/math_toolkit/libs/math/test/compile_test/sf_ellint_2_incl_test.cpp 2007-09-22 05:17:21 EDT (Sat, 22 Sep 2007)
@@ -7,11 +7,19 @@
 // #includes all the files that it needs to.
 //
 #include <boost/math/special_functions/ellint_2.hpp>
+//
+// Note this header includes no other headers, this is
+// important if this test is to be meaningful:
+//
+#include "test_compile_result.hpp"
 
-template float boost::math::ellint_2<float>(float, float);
-template double boost::math::ellint_2<double>(double, double);
-template long double boost::math::ellint_2<long double>(long double, long double);
+void check()
+{
+ check_result<float>(boost::math::ellint_2<float>(f, f));
+ check_result<double>(boost::math::ellint_2<double>(d, d));
+ check_result<long double>(boost::math::ellint_2<long double>(l, l));
 
-template float boost::math::ellint_2<float>(float);
-template double boost::math::ellint_2<double>(double);
-template long double boost::math::ellint_2<long double>(long double);
+ check_result<float>(boost::math::ellint_2<float>(f));
+ check_result<double>(boost::math::ellint_2<double>(d));
+ check_result<long double>(boost::math::ellint_2<long double>(l));
+}

Modified: sandbox/math_toolkit/libs/math/test/compile_test/sf_ellint_3_incl_test.cpp
==============================================================================
--- sandbox/math_toolkit/libs/math/test/compile_test/sf_ellint_3_incl_test.cpp (original)
+++ sandbox/math_toolkit/libs/math/test/compile_test/sf_ellint_3_incl_test.cpp 2007-09-22 05:17:21 EDT (Sat, 22 Sep 2007)
@@ -7,11 +7,19 @@
 // #includes all the files that it needs to.
 //
 #include <boost/math/special_functions/ellint_3.hpp>
+//
+// Note this header includes no other headers, this is
+// important if this test is to be meaningful:
+//
+#include "test_compile_result.hpp"
 
-template float boost::math::ellint_3<float>(float, float);
-template double boost::math::ellint_3<double>(double, double);
-template long double boost::math::ellint_3<long double>(long double, long double);
+void check()
+{
+ check_result<float>(boost::math::ellint_3<float>(f, f));
+ check_result<double>(boost::math::ellint_3<double>(d, d));
+ check_result<long double>(boost::math::ellint_3<long double>(l, l));
 
-template float boost::math::ellint_3<float>(float, float, float);
-template double boost::math::ellint_3<double>(double, double, double);
-template long double boost::math::ellint_3<long double>(long double, long double, long double);
+ check_result<float>(boost::math::ellint_3<float>(f, f, f));
+ check_result<double>(boost::math::ellint_3<double>(d, d, d));
+ check_result<long double>(boost::math::ellint_3<long double>(l, l, l));
+}

Modified: sandbox/math_toolkit/libs/math/test/compile_test/sf_ellint_rc_incl_test.cpp
==============================================================================
--- sandbox/math_toolkit/libs/math/test/compile_test/sf_ellint_rc_incl_test.cpp (original)
+++ sandbox/math_toolkit/libs/math/test/compile_test/sf_ellint_rc_incl_test.cpp 2007-09-22 05:17:21 EDT (Sat, 22 Sep 2007)
@@ -7,7 +7,15 @@
 // #includes all the files that it needs to.
 //
 #include <boost/math/special_functions/ellint_rc.hpp>
+//
+// Note this header includes no other headers, this is
+// important if this test is to be meaningful:
+//
+#include "test_compile_result.hpp"
 
-template float boost::math::ellint_rc<float>(float, float);
-template double boost::math::ellint_rc<double>(double, double);
-template long double boost::math::ellint_rc<long double>(long double, long double);
+void check()
+{
+ check_result<float>(boost::math::ellint_rc<float>(f, f));
+ check_result<double>(boost::math::ellint_rc<double>(d, d));
+ check_result<long double>(boost::math::ellint_rc<long double>(l, l));
+}

Modified: sandbox/math_toolkit/libs/math/test/compile_test/sf_ellint_rd_incl_test.cpp
==============================================================================
--- sandbox/math_toolkit/libs/math/test/compile_test/sf_ellint_rd_incl_test.cpp (original)
+++ sandbox/math_toolkit/libs/math/test/compile_test/sf_ellint_rd_incl_test.cpp 2007-09-22 05:17:21 EDT (Sat, 22 Sep 2007)
@@ -7,7 +7,15 @@
 // #includes all the files that it needs to.
 //
 #include <boost/math/special_functions/ellint_rd.hpp>
+//
+// Note this header includes no other headers, this is
+// important if this test is to be meaningful:
+//
+#include "test_compile_result.hpp"
 
-template float boost::math::ellint_rd<float>(float, float, float);
-template double boost::math::ellint_rd<double>(double, double, double);
-template long double boost::math::ellint_rd<long double>(long double, long double, long double);
+void check()
+{
+ check_result<float>(boost::math::ellint_rd<float>(f, f, f));
+ check_result<double>(boost::math::ellint_rd<double>(d, d, d));
+ check_result<long double>(boost::math::ellint_rd<long double>(l, l, l));
+}

Modified: sandbox/math_toolkit/libs/math/test/compile_test/sf_ellint_rf_incl_test.cpp
==============================================================================
--- sandbox/math_toolkit/libs/math/test/compile_test/sf_ellint_rf_incl_test.cpp (original)
+++ sandbox/math_toolkit/libs/math/test/compile_test/sf_ellint_rf_incl_test.cpp 2007-09-22 05:17:21 EDT (Sat, 22 Sep 2007)
@@ -7,7 +7,15 @@
 // #includes all the files that it needs to.
 //
 #include <boost/math/special_functions/ellint_rf.hpp>
+//
+// Note this header includes no other headers, this is
+// important if this test is to be meaningful:
+//
+#include "test_compile_result.hpp"
 
-template float boost::math::ellint_rf<float>(float, float, float);
-template double boost::math::ellint_rf<double>(double, double, double);
-template long double boost::math::ellint_rf<long double>(long double, long double, long double);
+void check()
+{
+ check_result<float>(boost::math::ellint_rf<float>(f, f, f));
+ check_result<double>(boost::math::ellint_rf<double>(d, d, d));
+ check_result<long double>(boost::math::ellint_rf<long double>(l, l, l));
+}

Modified: sandbox/math_toolkit/libs/math/test/compile_test/sf_ellint_rj_incl_test.cpp
==============================================================================
--- sandbox/math_toolkit/libs/math/test/compile_test/sf_ellint_rj_incl_test.cpp (original)
+++ sandbox/math_toolkit/libs/math/test/compile_test/sf_ellint_rj_incl_test.cpp 2007-09-22 05:17:21 EDT (Sat, 22 Sep 2007)
@@ -7,7 +7,15 @@
 // #includes all the files that it needs to.
 //
 #include <boost/math/special_functions/ellint_rj.hpp>
+//
+// Note this header includes no other headers, this is
+// important if this test is to be meaningful:
+//
+#include "test_compile_result.hpp"
 
-template float boost::math::ellint_rj<float>(float, float, float, float);
-template double boost::math::ellint_rj<double>(double, double, double, double);
-template long double boost::math::ellint_rj<long double>(long double, long double, long double, long double);
+void check()
+{
+ check_result<float>(boost::math::ellint_rj<float>(f, f, f, f));
+ check_result<double>(boost::math::ellint_rj<double>(d, d, d, d));
+ check_result<long double>(boost::math::ellint_rj<long double>(l, l, l, l));
+}

Modified: sandbox/math_toolkit/libs/math/test/compile_test/sf_erf_incl_test.cpp
==============================================================================
--- sandbox/math_toolkit/libs/math/test/compile_test/sf_erf_incl_test.cpp (original)
+++ sandbox/math_toolkit/libs/math/test/compile_test/sf_erf_incl_test.cpp 2007-09-22 05:17:21 EDT (Sat, 22 Sep 2007)
@@ -7,20 +7,27 @@
 // #includes all the files that it needs to.
 //
 #include <boost/math/special_functions/erf.hpp>
+//
+// Note this header includes no other headers, this is
+// important if this test is to be meaningful:
+//
+#include "test_compile_result.hpp"
 
-template float boost::math::erf<float>(float);
-template double boost::math::erf<double>(double);
-template long double boost::math::erf<long double>(long double);
-
-template float boost::math::erfc<float>(float);
-template double boost::math::erfc<double>(double);
-template long double boost::math::erfc<long double>(long double);
+void check()
+{
+ check_result<float>(boost::math::erf<float>(f));
+ check_result<double>(boost::math::erf<double>(d));
+ check_result<long double>(boost::math::erf<long double>(l));
 
-template float boost::math::erf_inv<float>(float);
-template double boost::math::erf_inv<double>(double);
-template long double boost::math::erf_inv<long double>(long double);
+ check_result<float>(boost::math::erfc<float>(f));
+ check_result<double>(boost::math::erfc<double>(d));
+ check_result<long double>(boost::math::erfc<long double>(l));
 
-template float boost::math::erfc_inv<float>(float);
-template double boost::math::erfc_inv<double>(double);
-template long double boost::math::erfc_inv<long double>(long double);
+ check_result<float>(boost::math::erf_inv<float>(f));
+ check_result<double>(boost::math::erf_inv<double>(d));
+ check_result<long double>(boost::math::erf_inv<long double>(l));
 
+ check_result<float>(boost::math::erfc_inv<float>(f));
+ check_result<double>(boost::math::erfc_inv<double>(d));
+ check_result<long double>(boost::math::erfc_inv<long double>(l));
+}

Modified: sandbox/math_toolkit/libs/math/test/compile_test/sf_expm1_incl_test.cpp
==============================================================================
--- sandbox/math_toolkit/libs/math/test/compile_test/sf_expm1_incl_test.cpp (original)
+++ sandbox/math_toolkit/libs/math/test/compile_test/sf_expm1_incl_test.cpp 2007-09-22 05:17:21 EDT (Sat, 22 Sep 2007)
@@ -7,7 +7,15 @@
 // #includes all the files that it needs to.
 //
 #include <boost/math/special_functions/expm1.hpp>
+//
+// Note this header includes no other headers, this is
+// important if this test is to be meaningful:
+//
+#include "test_compile_result.hpp"
 
-template float boost::math::expm1<float>(float);
-template double boost::math::expm1<double>(double);
-template long double boost::math::expm1<long double>(long double);
+void check()
+{
+ check_result<float>(boost::math::expm1<float>(f));
+ check_result<double>(boost::math::expm1<double>(d));
+ check_result<long double>(boost::math::expm1<long double>(l));
+}

Modified: sandbox/math_toolkit/libs/math/test/compile_test/sf_factorials_incl_test.cpp
==============================================================================
--- sandbox/math_toolkit/libs/math/test/compile_test/sf_factorials_incl_test.cpp (original)
+++ sandbox/math_toolkit/libs/math/test/compile_test/sf_factorials_incl_test.cpp 2007-09-22 05:17:21 EDT (Sat, 22 Sep 2007)
@@ -7,21 +7,28 @@
 // #includes all the files that it needs to.
 //
 #include <boost/math/special_functions/factorials.hpp>
+//
+// Note this header includes no other headers, this is
+// important if this test is to be meaningful:
+//
+#include "test_compile_result.hpp"
 
-template float boost::math::factorial<float>(unsigned);
-template double boost::math::factorial<double>(unsigned);
-template long double boost::math::factorial<long double>(unsigned);
-
-template float boost::math::double_factorial<float>(unsigned);
-template double boost::math::double_factorial<double>(unsigned);
-template long double boost::math::double_factorial<long double>(unsigned);
-
-template float boost::math::rising_factorial<float>(float, int);
-template double boost::math::rising_factorial<double>(double, int);
-template long double boost::math::rising_factorial<long double>(long double, int);
-
-template float boost::math::falling_factorial<float>(float, unsigned int);
-template double boost::math::falling_factorial<double>(double, unsigned int);
-template long double boost::math::falling_factorial<long double>(long double, unsigned int);
-
+void check()
+{
+ check_result<float>(boost::math::factorial<float>(u));
+ check_result<double>(boost::math::factorial<double>(u));
+ check_result<long double>(boost::math::factorial<long double>(u));
+
+ check_result<float>(boost::math::double_factorial<float>(u));
+ check_result<double>(boost::math::double_factorial<double>(u));
+ check_result<long double>(boost::math::double_factorial<long double>(u));
+
+ check_result<float>(boost::math::rising_factorial<float>(f, i));
+ check_result<double>(boost::math::rising_factorial<double>(d, i));
+ check_result<long double>(boost::math::rising_factorial<long double>(l, i));
+
+ check_result<float>(boost::math::falling_factorial<float>(f, u));
+ check_result<double>(boost::math::falling_factorial<double>(d, u));
+ check_result<long double>(boost::math::falling_factorial<long double>(l, u));
+}
 

Modified: sandbox/math_toolkit/libs/math/test/compile_test/sf_fpclassify_incl_test.cpp
==============================================================================
--- sandbox/math_toolkit/libs/math/test/compile_test/sf_fpclassify_incl_test.cpp (original)
+++ sandbox/math_toolkit/libs/math/test/compile_test/sf_fpclassify_incl_test.cpp 2007-09-22 05:17:21 EDT (Sat, 22 Sep 2007)
@@ -7,22 +7,29 @@
 // #includes all the files that it needs to.
 //
 #include <boost/math/special_functions/fpclassify.hpp>
+//
+// Note this header includes no other headers, this is
+// important if this test is to be meaningful:
+//
+#include "test_compile_result.hpp"
 
-template int boost::math::fpclassify<float>(float);
-template int boost::math::fpclassify<double>(double);
-template int boost::math::fpclassify<long double>(long double);
-
-template bool boost::math::isfinite<float>(float);
-template bool boost::math::isfinite<double>(double);
-template bool boost::math::isfinite<long double>(long double);
-
-template bool boost::math::isinf<float>(float);
-template bool boost::math::isinf<double>(double);
-template bool boost::math::isinf<long double>(long double);
-
-template bool boost::math::isnormal<float>(float);
-template bool boost::math::isnormal<double>(double);
-template bool boost::math::isnormal<long double>(long double);
-
+void check()
+{
+ check_result<int>(boost::math::fpclassify<float>(f));
+ check_result<int>(boost::math::fpclassify<double>(d));
+ check_result<int>(boost::math::fpclassify<long double>(l));
+
+ check_result<bool>(boost::math::isfinite<float>(f));
+ check_result<bool>(boost::math::isfinite<double>(d));
+ check_result<bool>(boost::math::isfinite<long double>(l));
+
+ check_result<bool>(boost::math::isinf<float>(f));
+ check_result<bool>(boost::math::isinf<double>(d));
+ check_result<bool>(boost::math::isinf<long double>(l));
+
+ check_result<bool>(boost::math::isnormal<float>(f));
+ check_result<bool>(boost::math::isnormal<double>(d));
+ check_result<bool>(boost::math::isnormal<long double>(l));
+}
 
 

Modified: sandbox/math_toolkit/libs/math/test/compile_test/sf_gamma_incl_test.cpp
==============================================================================
--- sandbox/math_toolkit/libs/math/test/compile_test/sf_gamma_incl_test.cpp (original)
+++ sandbox/math_toolkit/libs/math/test/compile_test/sf_gamma_incl_test.cpp 2007-09-22 05:17:21 EDT (Sat, 22 Sep 2007)
@@ -7,48 +7,55 @@
 // #includes all the files that it needs to.
 //
 #include <boost/math/special_functions/gamma.hpp>
+//
+// Note this header includes no other headers, this is
+// important if this test is to be meaningful:
+//
+#include "test_compile_result.hpp"
 
-template float boost::math::tgamma<float>(float);
-template double boost::math::tgamma<double>(double);
-template long double boost::math::tgamma<long double>(long double);
-
-template float boost::math::lgamma<float>(float);
-template double boost::math::lgamma<double>(double);
-template long double boost::math::lgamma<long double>(long double);
-
-template float boost::math::gamma_p<float>(float, float);
-template double boost::math::gamma_p<double>(double, double);
-template long double boost::math::gamma_p<long double>(long double, long double);
-
-template float boost::math::gamma_q<float>(float, float);
-template double boost::math::gamma_q<double>(double, double);
-template long double boost::math::gamma_q<long double>(long double, long double);
-
-template float boost::math::gamma_p_inv<float>(float, float);
-template double boost::math::gamma_p_inv<double>(double, double);
-template long double boost::math::gamma_p_inv<long double>(long double, long double);
-
-template float boost::math::gamma_q_inv<float>(float, float);
-template double boost::math::gamma_q_inv<double>(double, double);
-template long double boost::math::gamma_q_inv<long double>(long double, long double);
-
-template float boost::math::gamma_p_inva<float>(float, float);
-template double boost::math::gamma_p_inva<double>(double, double);
-template long double boost::math::gamma_p_inva<long double>(long double, long double);
-
-template float boost::math::gamma_q_inva<float>(float, float);
-template double boost::math::gamma_q_inva<double>(double, double);
-template long double boost::math::gamma_q_inva<long double>(long double, long double);
-
-template float boost::math::gamma_p_derivative<float>(float, float);
-template double boost::math::gamma_p_derivative<double>(double, double);
-template long double boost::math::gamma_p_derivative<long double>(long double, long double);
-
-template float boost::math::tgamma_ratio<float>(float, float);
-template double boost::math::tgamma_ratio<double>(double, double);
-template long double boost::math::tgamma_ratio<long double>(long double, long double);
-
-template float boost::math::tgamma_delta_ratio<float>(float, float);
-template double boost::math::tgamma_delta_ratio<double>(double, double);
-template long double boost::math::tgamma_delta_ratio<long double>(long double, long double);
-
+void check()
+{
+ check_result<float>(boost::math::tgamma<float>(f));
+ check_result<double>(boost::math::tgamma<double>(d));
+ check_result<long double>(boost::math::tgamma<long double>(l));
+
+ check_result<float>(boost::math::lgamma<float>(f));
+ check_result<double>(boost::math::lgamma<double>(d));
+ check_result<long double>(boost::math::lgamma<long double>(l));
+
+ check_result<float>(boost::math::gamma_p<float>(f, f));
+ check_result<double>(boost::math::gamma_p<double>(d, d));
+ check_result<long double>(boost::math::gamma_p<long double>(l, l));
+
+ check_result<float>(boost::math::gamma_q<float>(f, f));
+ check_result<double>(boost::math::gamma_q<double>(d, d));
+ check_result<long double>(boost::math::gamma_q<long double>(l, l));
+
+ check_result<float>(boost::math::gamma_p_inv<float>(f, f));
+ check_result<double>(boost::math::gamma_p_inv<double>(d, d));
+ check_result<long double>(boost::math::gamma_p_inv<long double>(l, l));
+
+ check_result<float>(boost::math::gamma_q_inv<float>(f, f));
+ check_result<double>(boost::math::gamma_q_inv<double>(d, d));
+ check_result<long double>(boost::math::gamma_q_inv<long double>(l, l));
+
+ check_result<float>(boost::math::gamma_p_inva<float>(f, f));
+ check_result<double>(boost::math::gamma_p_inva<double>(d, d));
+ check_result<long double>(boost::math::gamma_p_inva<long double>(l, l));
+
+ check_result<float>(boost::math::gamma_q_inva<float>(f, f));
+ check_result<double>(boost::math::gamma_q_inva<double>(d, d));
+ check_result<long double>(boost::math::gamma_q_inva<long double>(l, l));
+
+ check_result<float>(boost::math::gamma_p_derivative<float>(f, f));
+ check_result<double>(boost::math::gamma_p_derivative<double>(d, d));
+ check_result<long double>(boost::math::gamma_p_derivative<long double>(l, l));
+
+ check_result<float>(boost::math::tgamma_ratio<float>(f, f));
+ check_result<double>(boost::math::tgamma_ratio<double>(d, d));
+ check_result<long double>(boost::math::tgamma_ratio<long double>(l, l));
+
+ check_result<float>(boost::math::tgamma_delta_ratio<float>(f, f));
+ check_result<double>(boost::math::tgamma_delta_ratio<double>(d, d));
+ check_result<long double>(boost::math::tgamma_delta_ratio<long double>(l, l));
+}

Modified: sandbox/math_toolkit/libs/math/test/compile_test/sf_hermite_incl_test.cpp
==============================================================================
--- sandbox/math_toolkit/libs/math/test/compile_test/sf_hermite_incl_test.cpp (original)
+++ sandbox/math_toolkit/libs/math/test/compile_test/sf_hermite_incl_test.cpp 2007-09-22 05:17:21 EDT (Sat, 22 Sep 2007)
@@ -7,7 +7,15 @@
 // #includes all the files that it needs to.
 //
 #include <boost/math/special_functions/hermite.hpp>
+//
+// Note this header includes no other headers, this is
+// important if this test is to be meaningful:
+//
+#include "test_compile_result.hpp"
 
-template float boost::math::hermite<float>(unsigned, float);
-template double boost::math::hermite<double>(unsigned, double);
-template long double boost::math::hermite<long double>(unsigned, long double);
+void check()
+{
+ check_result<float>(boost::math::hermite<float>(u, f));
+ check_result<double>(boost::math::hermite<double>(u, d));
+ check_result<long double>(boost::math::hermite<long double>(u, l));
+}

Modified: sandbox/math_toolkit/libs/math/test/compile_test/sf_hypot_incl_test.cpp
==============================================================================
--- sandbox/math_toolkit/libs/math/test/compile_test/sf_hypot_incl_test.cpp (original)
+++ sandbox/math_toolkit/libs/math/test/compile_test/sf_hypot_incl_test.cpp 2007-09-22 05:17:21 EDT (Sat, 22 Sep 2007)
@@ -7,7 +7,15 @@
 // #includes all the files that it needs to.
 //
 #include <boost/math/special_functions/hypot.hpp>
+//
+// Note this header includes no other headers, this is
+// important if this test is to be meaningful:
+//
+#include "test_compile_result.hpp"
 
-template float boost::math::hypot<float>(float, float);
-template double boost::math::hypot<double>(double, double);
-template long double boost::math::hypot<long double>(long double, long double);
+void check()
+{
+ check_result<float>(boost::math::hypot<float>(f, f));
+ check_result<double>(boost::math::hypot<double>(d, d));
+ check_result<long double>(boost::math::hypot<long double>(l, l));
+}

Modified: sandbox/math_toolkit/libs/math/test/compile_test/sf_laguerre_incl_test.cpp
==============================================================================
--- sandbox/math_toolkit/libs/math/test/compile_test/sf_laguerre_incl_test.cpp (original)
+++ sandbox/math_toolkit/libs/math/test/compile_test/sf_laguerre_incl_test.cpp 2007-09-22 05:17:21 EDT (Sat, 22 Sep 2007)
@@ -7,14 +7,22 @@
 // #includes all the files that it needs to.
 //
 #include <boost/math/special_functions/laguerre.hpp>
+//
+// Note this header includes no other headers, this is
+// important if this test is to be meaningful:
+//
+#include "test_compile_result.hpp"
 
-template float boost::math::laguerre<float>(unsigned, float);
-template double boost::math::laguerre<double>(unsigned, double);
-template long double boost::math::laguerre<long double>(unsigned, long double);
-
-typedef boost::math::policies::policy<> def_pol;
+void check()
+{
+ check_result<float>(boost::math::laguerre<float>(u, f));
+ check_result<double>(boost::math::laguerre<double>(u, d));
+ check_result<long double>(boost::math::laguerre<long double>(u, l));
 
-template float boost::math::laguerre<float, def_pol>(unsigned, unsigned, float, const def_pol&);
-template double boost::math::laguerre<double, def_pol>(unsigned, unsigned, double, const def_pol&);
-template long double boost::math::laguerre<long double, def_pol>(unsigned, unsigned, long double, const def_pol&);
+ typedef boost::math::policies::policy<> def_pol;
+ def_pol p;
 
+ check_result<float>(boost::math::laguerre<float, def_pol>(u, u, f, p));
+ check_result<double>(boost::math::laguerre<double, def_pol>(u, u, d, p));
+ check_result<long double>(boost::math::laguerre<long double, def_pol>(u, u, l, p));
+}

Modified: sandbox/math_toolkit/libs/math/test/compile_test/sf_legendre_incl_test.cpp
==============================================================================
--- sandbox/math_toolkit/libs/math/test/compile_test/sf_legendre_incl_test.cpp (original)
+++ sandbox/math_toolkit/libs/math/test/compile_test/sf_legendre_incl_test.cpp 2007-09-22 05:17:21 EDT (Sat, 22 Sep 2007)
@@ -7,16 +7,23 @@
 // #includes all the files that it needs to.
 //
 #include <boost/math/special_functions/legendre.hpp>
+//
+// Note this header includes no other headers, this is
+// important if this test is to be meaningful:
+//
+#include "test_compile_result.hpp"
 
-template float boost::math::legendre_p<float>(int, float);
-template double boost::math::legendre_p<double>(int, double);
-template long double boost::math::legendre_p<long double>(int, long double);
-
-template float boost::math::legendre_p<float>(int, int, float);
-template double boost::math::legendre_p<double>(int, int, double);
-template long double boost::math::legendre_p<long double>(int, int, long double);
+void check()
+{
+ check_result<float>(boost::math::legendre_p<float>(i, f));
+ check_result<double>(boost::math::legendre_p<double>(i, d));
+ check_result<long double>(boost::math::legendre_p<long double>(i, l));
 
-template float boost::math::legendre_q<float>(unsigned, float);
-template double boost::math::legendre_q<double>(unsigned, double);
-template long double boost::math::legendre_q<long double>(unsigned, long double);
+ check_result<float>(boost::math::legendre_p<float>(i, i, f));
+ check_result<double>(boost::math::legendre_p<double>(i, i, d));
+ check_result<long double>(boost::math::legendre_p<long double>(i, i, l));
 
+ check_result<float>(boost::math::legendre_q<float>(u, f));
+ check_result<double>(boost::math::legendre_q<double>(u, d));
+ check_result<long double>(boost::math::legendre_q<long double>(u, l));
+}

Modified: sandbox/math_toolkit/libs/math/test/compile_test/sf_log1p_incl_test.cpp
==============================================================================
--- sandbox/math_toolkit/libs/math/test/compile_test/sf_log1p_incl_test.cpp (original)
+++ sandbox/math_toolkit/libs/math/test/compile_test/sf_log1p_incl_test.cpp 2007-09-22 05:17:21 EDT (Sat, 22 Sep 2007)
@@ -7,7 +7,15 @@
 // #includes all the files that it needs to.
 //
 #include <boost/math/special_functions/log1p.hpp>
+//
+// Note this header includes no other headers, this is
+// important if this test is to be meaningful:
+//
+#include "test_compile_result.hpp"
 
-template float boost::math::log1p<float>(float);
-template double boost::math::log1p<double>(double);
-template long double boost::math::log1p<long double>(long double);
+void check()
+{
+ check_result<float>(boost::math::log1p<float>(f));
+ check_result<double>(boost::math::log1p<double>(d));
+ check_result<long double>(boost::math::log1p<long double>(l));
+}

Modified: sandbox/math_toolkit/libs/math/test/compile_test/sf_powm1_incl_test.cpp
==============================================================================
--- sandbox/math_toolkit/libs/math/test/compile_test/sf_powm1_incl_test.cpp (original)
+++ sandbox/math_toolkit/libs/math/test/compile_test/sf_powm1_incl_test.cpp 2007-09-22 05:17:21 EDT (Sat, 22 Sep 2007)
@@ -7,7 +7,15 @@
 // #includes all the files that it needs to.
 //
 #include <boost/math/special_functions/powm1.hpp>
+//
+// Note this header includes no other headers, this is
+// important if this test is to be meaningful:
+//
+#include "test_compile_result.hpp"
 
-template float boost::math::powm1<float>(float, float);
-template double boost::math::powm1<double>(double, double);
-template long double boost::math::powm1<long double>(long double, long double);
+void check()
+{
+ check_result<float>(boost::math::powm1<float>(f, f));
+ check_result<double>(boost::math::powm1<double>(d, d));
+ check_result<long double>(boost::math::powm1<long double>(l, l));
+}

Modified: sandbox/math_toolkit/libs/math/test/compile_test/sf_sign_incl_test.cpp
==============================================================================
--- sandbox/math_toolkit/libs/math/test/compile_test/sf_sign_incl_test.cpp (original)
+++ sandbox/math_toolkit/libs/math/test/compile_test/sf_sign_incl_test.cpp 2007-09-22 05:17:21 EDT (Sat, 22 Sep 2007)
@@ -7,16 +7,23 @@
 // #includes all the files that it needs to.
 //
 #include <boost/math/special_functions/sign.hpp>
+//
+// Note this header includes no other headers, this is
+// important if this test is to be meaningful:
+//
+#include "test_compile_result.hpp"
 
-template int boost::math::sign<float>(const float&);
-template int boost::math::sign<double>(const double&);
-template int boost::math::sign<long double>(const long double&);
-
-template int boost::math::signbit<float>(const float&);
-template int boost::math::signbit<double>(const double&);
-template int boost::math::signbit<long double>(const long double&);
+void check()
+{
+ check_result<int>(boost::math::sign<float>(f));
+ check_result<int>(boost::math::sign<double>(d));
+ check_result<int>(boost::math::sign<long double>(l));
 
-template float boost::math::copysign<float>(const float&, const float&);
-template double boost::math::copysign<double>(const double&, const double&);
-template long double boost::math::copysign<long double>(const long double&, const long double&);
+ check_result<int>(boost::math::signbit<float>(f));
+ check_result<int>(boost::math::signbit<double>(d));
+ check_result<int>(boost::math::signbit<long double>(l));
 
+ check_result<float>(boost::math::copysign<float>(f, f));
+ check_result<double>(boost::math::copysign<double>(d, d));
+ check_result<long double>(boost::math::copysign<long double>(l, l));
+}

Modified: sandbox/math_toolkit/libs/math/test/compile_test/sf_sin_pi_incl_test.cpp
==============================================================================
--- sandbox/math_toolkit/libs/math/test/compile_test/sf_sin_pi_incl_test.cpp (original)
+++ sandbox/math_toolkit/libs/math/test/compile_test/sf_sin_pi_incl_test.cpp 2007-09-22 05:17:21 EDT (Sat, 22 Sep 2007)
@@ -7,8 +7,15 @@
 // #includes all the files that it needs to.
 //
 #include <boost/math/special_functions/sin_pi.hpp>
+//
+// Note this header includes no other headers, this is
+// important if this test is to be meaningful:
+//
+#include "test_compile_result.hpp"
 
-template float boost::math::sin_pi<float>(float);
-template double boost::math::sin_pi<double>(double);
-template long double boost::math::sin_pi<long double>(long double);
-
+void check()
+{
+ check_result<float>(boost::math::sin_pi<float>(f));
+ check_result<double>(boost::math::sin_pi<double>(d));
+ check_result<long double>(boost::math::sin_pi<long double>(l));
+}

Modified: sandbox/math_toolkit/libs/math/test/compile_test/sf_sinc_incl_test.cpp
==============================================================================
--- sandbox/math_toolkit/libs/math/test/compile_test/sf_sinc_incl_test.cpp (original)
+++ sandbox/math_toolkit/libs/math/test/compile_test/sf_sinc_incl_test.cpp 2007-09-22 05:17:21 EDT (Sat, 22 Sep 2007)
@@ -7,7 +7,15 @@
 // #includes all the files that it needs to.
 //
 #include <boost/math/special_functions/sinc.hpp>
+//
+// Note this header includes no other headers, this is
+// important if this test is to be meaningful:
+//
+#include "test_compile_result.hpp"
 
-template float boost::math::sinc_pi<float>(float);
-template double boost::math::sinc_pi<double>(double);
-template long double boost::math::sinc_pi<long double>(long double);
+void check()
+{
+ check_result<float>(boost::math::sinc_pi<float>(f));
+ check_result<double>(boost::math::sinc_pi<double>(d));
+ check_result<long double>(boost::math::sinc_pi<long double>(l));
+}

Modified: sandbox/math_toolkit/libs/math/test/compile_test/sf_sinhc_incl_test.cpp
==============================================================================
--- sandbox/math_toolkit/libs/math/test/compile_test/sf_sinhc_incl_test.cpp (original)
+++ sandbox/math_toolkit/libs/math/test/compile_test/sf_sinhc_incl_test.cpp 2007-09-22 05:17:21 EDT (Sat, 22 Sep 2007)
@@ -7,7 +7,15 @@
 // #includes all the files that it needs to.
 //
 #include <boost/math/special_functions/sinhc.hpp>
+//
+// Note this header includes no other headers, this is
+// important if this test is to be meaningful:
+//
+#include "test_compile_result.hpp"
 
-template float boost::math::sinhc_pi<float>(float);
-template double boost::math::sinhc_pi<double>(double);
-template long double boost::math::sinhc_pi<long double>(long double);
+void check()
+{
+ check_result<float>(boost::math::sinhc_pi<float>(f));
+ check_result<double>(boost::math::sinhc_pi<double>(d));
+ check_result<long double>(boost::math::sinhc_pi<long double>(l));
+}

Modified: sandbox/math_toolkit/libs/math/test/compile_test/sf_sph_harm_incl_test.cpp
==============================================================================
--- sandbox/math_toolkit/libs/math/test/compile_test/sf_sph_harm_incl_test.cpp (original)
+++ sandbox/math_toolkit/libs/math/test/compile_test/sf_sph_harm_incl_test.cpp 2007-09-22 05:17:21 EDT (Sat, 22 Sep 2007)
@@ -7,18 +7,25 @@
 // #includes all the files that it needs to.
 //
 #include <boost/math/special_functions/spherical_harmonic.hpp>
+//
+// Note this header includes no other headers, this is
+// important if this test is to be meaningful:
+//
+#include "test_compile_result.hpp"
 
-template std::complex<float> boost::math::spherical_harmonic<float>(unsigned, int, float, float);
-template std::complex<double> boost::math::spherical_harmonic<double>(unsigned, int, double, double);
-template std::complex<long double> boost::math::spherical_harmonic<long double>(unsigned, int, long double, long double);
-
-template float boost::math::spherical_harmonic_r<float>(unsigned, int, float, float);
-template double boost::math::spherical_harmonic_r<double>(unsigned, int, double, double);
-template long double boost::math::spherical_harmonic_r<long double>(unsigned, int, long double, long double);
-
-template float boost::math::spherical_harmonic_i<float>(unsigned, int, float, float);
-template double boost::math::spherical_harmonic_i<double>(unsigned, int, double, double);
-template long double boost::math::spherical_harmonic_i<long double>(unsigned, int, long double, long double);
-
+void check()
+{
+ check_result<std::complex<float> >(boost::math::spherical_harmonic<float>(u, i, f, f));
+ check_result<std::complex<double> >(boost::math::spherical_harmonic<double>(u, i, d, d));
+ check_result<std::complex<long double> >(boost::math::spherical_harmonic<long double>(u, i, l, l));
+
+ check_result<float>(boost::math::spherical_harmonic_r<float>(u, i, f, f));
+ check_result<double>(boost::math::spherical_harmonic_r<double>(u, i, d, d));
+ check_result<long double>(boost::math::spherical_harmonic_r<long double>(u, i, l, l));
+
+ check_result<float>(boost::math::spherical_harmonic_i<float>(u, i, f, f));
+ check_result<double>(boost::math::spherical_harmonic_i<double>(u, i, d, d));
+ check_result<long double>(boost::math::spherical_harmonic_i<long double>(u, i, l, l));
+}
 
 

Modified: sandbox/math_toolkit/libs/math/test/compile_test/sf_sqrt1pm1_incl_test.cpp
==============================================================================
--- sandbox/math_toolkit/libs/math/test/compile_test/sf_sqrt1pm1_incl_test.cpp (original)
+++ sandbox/math_toolkit/libs/math/test/compile_test/sf_sqrt1pm1_incl_test.cpp 2007-09-22 05:17:21 EDT (Sat, 22 Sep 2007)
@@ -7,7 +7,15 @@
 // #includes all the files that it needs to.
 //
 #include <boost/math/special_functions/sqrt1pm1.hpp>
+//
+// Note this header includes no other headers, this is
+// important if this test is to be meaningful:
+//
+#include "test_compile_result.hpp"
 
-template float boost::math::sqrt1pm1<float>(const float&);
-template double boost::math::sqrt1pm1<double>(const double&);
-template long double boost::math::sqrt1pm1<long double>(const long double&);
+void check()
+{
+ check_result<float>(boost::math::sqrt1pm1<float>(f));
+ check_result<double>(boost::math::sqrt1pm1<double>(d));
+ check_result<long double>(boost::math::sqrt1pm1<long double>(l));
+}

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 2007-09-22 05:17:21 EDT (Sat, 22 Sep 2007)
@@ -12,20 +12,108 @@
 static const float f = 0;
 static const double d = 0;
 static const long double l = 0;
+static const unsigned u = 0;
+static const int i = 0;
 
 template <class T>
-void check_result_imp(T, T){}
+inline void check_result_imp(T, T){}
 
 template <class T1, class T2>
-void check_result_imp(T1, T2)
+inline void check_result_imp(T1, T2)
 {
    typedef int static_assertion[sizeof(T1) == 0xFFFF];
 }
 
 template <class T1, class T2>
-void check_result(T2)
+inline void check_result(T2)
 {
- T1 a = 0;
- T2 b = 0;
+ T1 a = T1();
+ T2 b = T2();
    return check_result_imp(a, b);
 }
+
+
+template <class Distribution>
+struct DistributionConcept
+{
+ static void constraints()
+ {
+ typedef typename Distribution::value_type value_type;
+
+ const Distribution& dist = DistributionConcept<Distribution>::get_object();
+
+ value_type x = 0;
+ // The result values are ignored in all these checks.
+ check_result<value_type>(cdf(dist, x));
+ check_result<value_type>(cdf(complement(dist, x)));
+ check_result<value_type>(pdf(dist, x));
+ check_result<value_type>(quantile(dist, x));
+ check_result<value_type>(quantile(complement(dist, x)));
+ check_result<value_type>(mean(dist));
+ check_result<value_type>(mode(dist));
+ check_result<value_type>(standard_deviation(dist));
+ check_result<value_type>(variance(dist));
+ check_result<value_type>(hazard(dist, x));
+ check_result<value_type>(chf(dist, x));
+ check_result<value_type>(coefficient_of_variation(dist));
+ check_result<value_type>(skewness(dist));
+ check_result<value_type>(kurtosis(dist));
+ check_result<value_type>(kurtosis_excess(dist));
+ check_result<value_type>(median(dist));
+ //
+ // we can't actually test that at std::pair is returned from these
+ // because that would mean including some std lib headers....
+ //
+ range(dist);
+ support(dist);
+
+ check_result<value_type>(cdf(dist, f));
+ check_result<value_type>(cdf(complement(dist, f)));
+ check_result<value_type>(pdf(dist, f));
+ check_result<value_type>(quantile(dist, f));
+ check_result<value_type>(quantile(complement(dist, f)));
+ check_result<value_type>(hazard(dist, f));
+ check_result<value_type>(chf(dist, f));
+ check_result<value_type>(cdf(dist, d));
+ check_result<value_type>(cdf(complement(dist, d)));
+ check_result<value_type>(pdf(dist, d));
+ check_result<value_type>(quantile(dist, d));
+ check_result<value_type>(quantile(complement(dist, d)));
+ check_result<value_type>(hazard(dist, d));
+ check_result<value_type>(chf(dist, d));
+ check_result<value_type>(cdf(dist, l));
+ check_result<value_type>(cdf(complement(dist, l)));
+ check_result<value_type>(pdf(dist, l));
+ check_result<value_type>(quantile(dist, l));
+ check_result<value_type>(quantile(complement(dist, l)));
+ check_result<value_type>(hazard(dist, l));
+ check_result<value_type>(chf(dist, l));
+ check_result<value_type>(cdf(dist, i));
+ check_result<value_type>(cdf(complement(dist, i)));
+ check_result<value_type>(pdf(dist, i));
+ check_result<value_type>(quantile(dist, i));
+ check_result<value_type>(quantile(complement(dist, i)));
+ check_result<value_type>(hazard(dist, i));
+ check_result<value_type>(chf(dist, i));
+ unsigned long li = 1;
+ check_result<value_type>(cdf(dist, li));
+ check_result<value_type>(cdf(complement(dist, li)));
+ check_result<value_type>(pdf(dist, li));
+ check_result<value_type>(quantile(dist, li));
+ check_result<value_type>(quantile(complement(dist, li)));
+ check_result<value_type>(hazard(dist, li));
+ check_result<value_type>(chf(dist, li));
+ }
+private:
+ static Distribution& get_object()
+ {
+ // will never get called:
+ return * reinterpret_cast<Distribution*>(0);
+ }
+}; // struct DistributionConcept
+
+#define TEST_DIST_FUNC(dist)\
+ DistributionConcept< boost::math::dist##_distribution<float> >::constraints();\
+ DistributionConcept< boost::math::dist##_distribution<double> >::constraints();\
+ DistributionConcept< boost::math::dist##_distribution<long double> >::constraints();
+

Modified: sandbox/math_toolkit/libs/math/test/compile_test/tools_roots_inc_test.cpp
==============================================================================
--- sandbox/math_toolkit/libs/math/test/compile_test/tools_roots_inc_test.cpp (original)
+++ sandbox/math_toolkit/libs/math/test/compile_test/tools_roots_inc_test.cpp 2007-09-22 05:17:21 EDT (Sat, 22 Sep 2007)
@@ -7,17 +7,28 @@
 // #includes all the files that it needs to.
 //
 #include <boost/math/tools/roots.hpp>
+//
+// Note this header includes no other headers, this is
+// important if this test is to be meaningful:
+//
+#include "test_compile_result.hpp"
 
-typedef double (*F)(double);
-typedef std::pair<double, double> (*F2)(double);
-typedef std::tr1::tuple<double, double, double> (*F3)(double);
-#define T double
-typedef boost::math::tools::eps_tolerance<double> Tol;
-
-template std::pair<T, T> boost::math::tools::bisect<F, T, Tol>(F f, T min, T max, Tol tol, boost::uintmax_t& max_iter);
-template std::pair<T, T> boost::math::tools::bisect<F, T, Tol>(F f, T min, T max, Tol tol);
-template T boost::math::tools::newton_raphson_iterate<F2, T>(F2 f, T guess, T min, T max, int digits, boost::uintmax_t& max_iter);
-template T boost::math::tools::halley_iterate<F3, T>(F3 f, T guess, T min, T max, int digits, boost::uintmax_t& max_iter);
-template T boost::math::tools::schroeder_iterate<F3, T>(F3 f, T guess, T min, T max, int digits, boost::uintmax_t& max_iter);
+void check()
+{
+ typedef double (*F)(double);
+ typedef std::pair<double, double> (*F2)(double);
+ typedef std::tr1::tuple<double, double, double> (*F3)(double);
+ typedef boost::math::tools::eps_tolerance<double> Tol;
+ Tol tol(u);
+ boost::uintmax_t max_iter = 0;
+ F f = 0;
+ F2 f2 = 0;
+ F3 f3 = 0;
 
+ check_result<std::pair<double, double> >(boost::math::tools::bisect<F, double, Tol>(f, d, d, tol, max_iter));
+ check_result<std::pair<double, double> >(boost::math::tools::bisect<F, double, Tol>(f, d, d, tol));
+ check_result<double>(boost::math::tools::newton_raphson_iterate<F2, double>(f2, d, d, d, i, max_iter));
+ check_result<double>(boost::math::tools::halley_iterate<F3, double>(f3, d, d, d, i, max_iter));
+ check_result<double>(boost::math::tools::schroeder_iterate<F3, double>(f3, d, d, d, i, max_iter));
+}
 

Modified: sandbox/math_toolkit/libs/math/test/compile_test/tools_series_inc_test.cpp
==============================================================================
--- sandbox/math_toolkit/libs/math/test/compile_test/tools_series_inc_test.cpp (original)
+++ sandbox/math_toolkit/libs/math/test/compile_test/tools_series_inc_test.cpp 2007-09-22 05:17:21 EDT (Sat, 22 Sep 2007)
@@ -7,6 +7,11 @@
 // #includes all the files that it needs to.
 //
 #include <boost/math/tools/series.hpp>
+//
+// Note this header includes no other headers, this is
+// important if this test is to be meaningful:
+//
+#include "test_compile_result.hpp"
 
 struct Functor
 {
@@ -15,11 +20,16 @@
 };
 #define U double
 
-template Functor::result_type boost::math::tools::sum_series<Functor>(Functor& func, int bits);
-template Functor::result_type boost::math::tools::sum_series<Functor>(Functor& func, int bits, boost::uintmax_t& max_terms);
-template Functor::result_type boost::math::tools::sum_series<Functor, U>(Functor& func, int bits, U init_value);
-template Functor::result_type boost::math::tools::sum_series<Functor, U>(Functor& func, int bits, boost::uintmax_t& max_terms, U init_value);
-template Functor::result_type boost::math::tools::kahan_sum_series<Functor>(Functor& func, int bits);
-template Functor::result_type boost::math::tools::kahan_sum_series<Functor>(Functor& func, int bits, boost::uintmax_t& max_terms);
+Functor func;
+boost::uintmax_t uim = 0;
 
+void check()
+{
+ check_result<Functor::result_type>(boost::math::tools::sum_series<Functor>(func, i));
+ check_result<Functor::result_type>(boost::math::tools::sum_series<Functor>(func, i, uim));
+ check_result<Functor::result_type>(boost::math::tools::sum_series<Functor, U>(func, i, d));
+ check_result<Functor::result_type>(boost::math::tools::sum_series<Functor, U>(func, i, uim, d));
+ check_result<Functor::result_type>(boost::math::tools::kahan_sum_series<Functor>(func, i));
+ check_result<Functor::result_type>(boost::math::tools::kahan_sum_series<Functor>(func, i, uim));
+}
 

Modified: sandbox/math_toolkit/libs/math/test/compile_test/tools_test_inc_test.cpp
==============================================================================
--- sandbox/math_toolkit/libs/math/test/compile_test/tools_test_inc_test.cpp (original)
+++ sandbox/math_toolkit/libs/math/test/compile_test/tools_test_inc_test.cpp 2007-09-22 05:17:21 EDT (Sat, 22 Sep 2007)
@@ -8,14 +8,26 @@
 //
 #include <boost/math/tools/test.hpp>
 #include <boost/array.hpp>
+//
+// Note this header includes no other headers, this is
+// important if this test is to be meaningful:
+//
+#include "test_compile_result.hpp"
+
+void check()
+{
+ check_result<float>(boost::math::tools::relative_error<float>(f, f));
 
-template float boost::math::tools::relative_error<float>(float a, float b);
+ #define A boost::array<boost::array<double, 2>, 2>
+ typedef double (*F1)(const boost::array<double, 2>&);
+ typedef F1 F2;
+ A a;
+ F1 f1 = 0;
+ F2 f2 = 0;
 
-#define A boost::array<boost::array<double, 2>, 2>
-typedef double (*F1)(const boost::array<double, 2>&);
-typedef F1 F2;
+ check_result<boost::math::tools::test_result<
+ boost::math::tools::calculate_result_type<A>::value_type> >
+ (boost::math::tools::test<A, F1, F2>(a, f1, f2));
 
-template boost::math::tools::test_result<
- boost::math::tools::calculate_result_type<A>::value_type>
- boost::math::tools::test<A, F1, F2>(const A& a, F1 test_func, F2 expect_func);
+}
 


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