File indexing completed on 2025-01-18 09:38:12
0001
0002
0003
0004
0005
0006
0007 #ifndef BOOST_HISTOGRAM_DETAIL_LIMITS_HPP
0008 #define BOOST_HISTOGRAM_DETAIL_LIMITS_HPP
0009
0010 #include <limits>
0011
0012 namespace boost {
0013 namespace histogram {
0014 namespace detail {
0015
0016 template <class T>
0017 constexpr T lowest() {
0018 return std::numeric_limits<T>::lowest();
0019 }
0020
0021 template <>
0022 constexpr double lowest() {
0023 return -std::numeric_limits<double>::infinity();
0024 }
0025
0026 template <>
0027 constexpr float lowest() {
0028 return -std::numeric_limits<float>::infinity();
0029 }
0030
0031 template <class T>
0032 constexpr T highest() {
0033 return (std::numeric_limits<T>::max)();
0034 }
0035
0036 template <>
0037 constexpr double highest() {
0038 return std::numeric_limits<double>::infinity();
0039 }
0040
0041 template <>
0042 constexpr float highest() {
0043 return std::numeric_limits<float>::infinity();
0044 }
0045
0046 }
0047 }
0048 }
0049
0050 #endif