]> git.proxmox.com Git - ceph.git/blobdiff - ceph/src/boost/boost/math/tools/series.hpp
update ceph source to reef 18.1.2
[ceph.git] / ceph / src / boost / boost / math / tools / series.hpp
index 8816f47a90bcf23fcbb807c36c4274ad15d8a5e0..1809dfab113c2dfd6a666182bb7e58c8813d8483 100644 (file)
@@ -10,9 +10,9 @@
 #pragma once
 #endif
 
-#include <boost/config/no_tr1/cmath.hpp>
-#include <boost/cstdint.hpp>
-#include <boost/limits.hpp>
+#include <cmath>
+#include <cstdint>
+#include <limits>
 #include <boost/math/tools/config.hpp>
 
 namespace boost{ namespace math{ namespace tools{
@@ -21,13 +21,13 @@ namespace boost{ namespace math{ namespace tools{
 // Simple series summation come first:
 //
 template <class Functor, class U, class V>
-inline typename Functor::result_type sum_series(Functor& func, const U& factor, boost::uintmax_t& max_terms, const V& init_value) BOOST_NOEXCEPT_IF(BOOST_MATH_IS_FLOAT(typename Functor::result_type) && noexcept(std::declval<Functor>()()))
+inline typename Functor::result_type sum_series(Functor& func, const U& factor, std::uintmax_t& max_terms, const V& init_value) noexcept(BOOST_MATH_IS_FLOAT(typename Functor::result_type) && noexcept(std::declval<Functor>()()))
 {
    BOOST_MATH_STD_USING
 
    typedef typename Functor::result_type result_type;
 
-   boost::uintmax_t counter = max_terms;
+   std::uintmax_t counter = max_terms;
 
    result_type result = init_value;
    result_type next_term;
@@ -44,14 +44,14 @@ inline typename Functor::result_type sum_series(Functor& func, const U& factor,
 }
 
 template <class Functor, class U>
-inline typename Functor::result_type sum_series(Functor& func, const U& factor, boost::uintmax_t& max_terms) BOOST_NOEXCEPT_IF(BOOST_MATH_IS_FLOAT(typename Functor::result_type) && noexcept(std::declval<Functor>()()))
+inline typename Functor::result_type sum_series(Functor& func, const U& factor, std::uintmax_t& max_terms) noexcept(BOOST_MATH_IS_FLOAT(typename Functor::result_type) && noexcept(std::declval<Functor>()()))
 {
    typename Functor::result_type init_value = 0;
    return sum_series(func, factor, max_terms, init_value);
 }
 
 template <class Functor, class U>
-inline typename Functor::result_type sum_series(Functor& func, int bits, boost::uintmax_t& max_terms, const U& init_value) BOOST_NOEXCEPT_IF(BOOST_MATH_IS_FLOAT(typename Functor::result_type) && noexcept(std::declval<Functor>()()))
+inline typename Functor::result_type sum_series(Functor& func, int bits, std::uintmax_t& max_terms, const U& init_value) noexcept(BOOST_MATH_IS_FLOAT(typename Functor::result_type) && noexcept(std::declval<Functor>()()))
 {
    BOOST_MATH_STD_USING
    typedef typename Functor::result_type result_type;
@@ -60,17 +60,17 @@ inline typename Functor::result_type sum_series(Functor& func, int bits, boost::
 }
 
 template <class Functor>
-inline typename Functor::result_type sum_series(Functor& func, int bits) BOOST_NOEXCEPT_IF(BOOST_MATH_IS_FLOAT(typename Functor::result_type) && noexcept(std::declval<Functor>()()))
+inline typename Functor::result_type sum_series(Functor& func, int bits) noexcept(BOOST_MATH_IS_FLOAT(typename Functor::result_type) && noexcept(std::declval<Functor>()()))
 {
    BOOST_MATH_STD_USING
    typedef typename Functor::result_type result_type;
-   boost::uintmax_t iters = (std::numeric_limits<boost::uintmax_t>::max)();
+   std::uintmax_t iters = (std::numeric_limits<std::uintmax_t>::max)();
    result_type init_val = 0;
    return sum_series(func, bits, iters, init_val);
 }
 
 template <class Functor>
-inline typename Functor::result_type sum_series(Functor& func, int bits, boost::uintmax_t& max_terms) BOOST_NOEXCEPT_IF(BOOST_MATH_IS_FLOAT(typename Functor::result_type) && noexcept(std::declval<Functor>()()))
+inline typename Functor::result_type sum_series(Functor& func, int bits, std::uintmax_t& max_terms) noexcept(BOOST_MATH_IS_FLOAT(typename Functor::result_type) && noexcept(std::declval<Functor>()()))
 {
    BOOST_MATH_STD_USING
    typedef typename Functor::result_type result_type;
@@ -79,23 +79,23 @@ inline typename Functor::result_type sum_series(Functor& func, int bits, boost::
 }
 
 template <class Functor, class U>
-inline typename Functor::result_type sum_series(Functor& func, int bits, const U& init_value) BOOST_NOEXCEPT_IF(BOOST_MATH_IS_FLOAT(typename Functor::result_type) && noexcept(std::declval<Functor>()()))
+inline typename Functor::result_type sum_series(Functor& func, int bits, const U& init_value) noexcept(BOOST_MATH_IS_FLOAT(typename Functor::result_type) && noexcept(std::declval<Functor>()()))
 {
    BOOST_MATH_STD_USING
-   boost::uintmax_t iters = (std::numeric_limits<boost::uintmax_t>::max)();
+   std::uintmax_t iters = (std::numeric_limits<std::uintmax_t>::max)();
    return sum_series(func, bits, iters, init_value);
 }
 //
 // Checked summation:
 //
 template <class Functor, class U, class V>
-inline typename Functor::result_type checked_sum_series(Functor& func, const U& factor, boost::uintmax_t& max_terms, const V& init_value, V& norm) BOOST_NOEXCEPT_IF(BOOST_MATH_IS_FLOAT(typename Functor::result_type) && noexcept(std::declval<Functor>()()))
+inline typename Functor::result_type checked_sum_series(Functor& func, const U& factor, std::uintmax_t& max_terms, const V& init_value, V& norm) noexcept(BOOST_MATH_IS_FLOAT(typename Functor::result_type) && noexcept(std::declval<Functor>()()))
 {
    BOOST_MATH_STD_USING
 
    typedef typename Functor::result_type result_type;
 
-   boost::uintmax_t counter = max_terms;
+   std::uintmax_t counter = max_terms;
 
    result_type result = init_value;
    result_type next_term;
@@ -125,7 +125,7 @@ inline typename Functor::result_type checked_sum_series(Functor& func, const U&
 // in any case the result is still much better than a naive summation.
 //
 template <class Functor>
-inline typename Functor::result_type kahan_sum_series(Functor& func, int bits) BOOST_NOEXCEPT_IF(BOOST_MATH_IS_FLOAT(typename Functor::result_type) && noexcept(std::declval<Functor>()()))
+inline typename Functor::result_type kahan_sum_series(Functor& func, int bits) noexcept(BOOST_MATH_IS_FLOAT(typename Functor::result_type) && noexcept(std::declval<Functor>()()))
 {
    BOOST_MATH_STD_USING
 
@@ -148,13 +148,13 @@ inline typename Functor::result_type kahan_sum_series(Functor& func, int bits) B
 }
 
 template <class Functor>
-inline typename Functor::result_type kahan_sum_series(Functor& func, int bits, boost::uintmax_t& max_terms) BOOST_NOEXCEPT_IF(BOOST_MATH_IS_FLOAT(typename Functor::result_type) && noexcept(std::declval<Functor>()()))
+inline typename Functor::result_type kahan_sum_series(Functor& func, int bits, std::uintmax_t& max_terms) noexcept(BOOST_MATH_IS_FLOAT(typename Functor::result_type) && noexcept(std::declval<Functor>()()))
 {
    BOOST_MATH_STD_USING
 
    typedef typename Functor::result_type result_type;
 
-   boost::uintmax_t counter = max_terms;
+   std::uintmax_t counter = max_terms;
 
    result_type factor = ldexp(result_type(1), bits);
    result_type result = func();