diff --git a/include/boost/math/special_functions/zeta.hpp b/include/boost/math/special_functions/zeta.hpp index c10307542..4a374cdd5 100644 --- a/include/boost/math/special_functions/zeta.hpp +++ b/include/boost/math/special_functions/zeta.hpp @@ -949,7 +949,7 @@ T zeta_imp(T s, T sc, const Policy& pol, const Tag& tag) static const char* function = "boost::math::zeta<%1%>"; if(sc == 0) return policies::raise_pole_error(function, "Evaluation of zeta function at pole %1%", s, pol); - T result; + T result; // LCOV_EXCL_LINE // // Trivial case: // diff --git a/test/test_ulp.cpp b/test/test_ulp.cpp index fe0336469..f57ea2061 100644 --- a/test/test_ulp.cpp +++ b/test/test_ulp.cpp @@ -26,6 +26,8 @@ void test() BOOST_CHECK_THROW(boost::math::ulp(std::numeric_limits::infinity()), std::overflow_error); } BOOST_CHECK_THROW(boost::math::ulp(boost::math::tools::max_value()), std::overflow_error); + + BOOST_CHECK(boost::math::ulp(static_cast(0)) != 0); } BOOST_AUTO_TEST_CASE( test_main )