[Boost.Math special functions] Critical error in zeta.hpp, Boost 1.54.0

I'm getting compile errors when including "boost/math/special_functions/zeta.hpp" (which in turn is included indirectly by "boost/random.hpp"). This is in the recently released "boost_1_54_0.tar.bz2" under Linux Mint 16 for amd64, gcc 4.7.3. Minimal test case: #include "boost/math/special_functions/zeta.hpp" int main() {} Exact error message: In file included from source/eldwood/test/zeta.cpp:1:0: intermediate/usr_x86_64-pc-linux-gnu/include/boost/math/special_functions/zeta.hpp: In function ‘T boost::math::detail::zeta_imp(T, T, const Policy&, const Tag&)’: intermediate/usr_x86_64-pc-linux-gnu/include/boost/math/special_functions/zeta.hpp:877:24: error: ‘log_root_two_pi’ is not a member of ‘boost::math::constants’ intermediate/usr_x86_64-pc-linux-gnu/include/boost/math/special_functions/zeta.hpp:877:52: error: expected primary-expression before ‘,’ token intermediate/usr_x86_64-pc-linux-gnu/include/boost/math/special_functions/zeta.hpp:877:60: error: expected primary-expression before ‘>’ token intermediate/usr_x86_64-pc-linux-gnu/include/boost/math/special_functions/zeta.hpp:877:62: error: expected primary-expression before ‘)’ token The same error also manifests under clang. -- Rainer Deyke (rainerd@eldwood.com)

log_root_two_pi is defined in constants.hpp on boost-trunk BOOST_DEFINE_MATH_CONSTANT(log_root_two_pi, 9.189385332046727417803297364056176398e-01, "9.18938533204672741780329736405617639861397473637783412817151540482765695927260397694743298635954197622005646625e-01") So I suspect we may have failed to get this into the release. Meanwhile using this file from boost-trunk may get you going? https://svn.boost.org/svn/boost/trunk/boost/math/constants/constants.hpp Yours in haste... Paul PS If this fails, we have some other problem :-( --- Paul A. Bristow, Prizet Farmhouse, Kendal LA8 8AB UK +44 1539 561830 07714330204 pbristow@hetp.u-net.com

Strange, I'm unable to reproduce here with Mingw-4.7.2 GCC. Perhaps more to the point, we actually have a test case that's very similar to yours (sf_zeta_include_test.cpp), which passes with all the compilers we're currently testing with in the online test matrix. Is it possible you have two different versions of Boost mixed up or some such SNAFU? John.
participants (3)
-
John Maddock
-
Paul A. Bristow
-
Rainer Deyke