bounds.hpp 844 B

12345678910111213141516171819202122232425262728
  1. // Boost.Geometry
  2. // Copyright (c) 2024 Barend Gehrels, Amsterdam, the Netherlands.
  3. // Use, modification and distribution is subject to the Boost Software License,
  4. // Version 1.0. (See accompanying file LICENSE_1_0.txt or copy at
  5. // http://www.boost.org/LICENSE_1_0.txt)
  6. #ifndef BOOST_GEOMETRY_UTIL_BOUNDS_HPP
  7. #define BOOST_GEOMETRY_UTIL_BOUNDS_HPP
  8. #include <boost/numeric/conversion/bounds.hpp>
  9. namespace boost { namespace geometry { namespace util
  10. {
  11. // Define a boost::geometry::util::bounds
  12. // It might be specialized for other numeric types, for example Boost.Rational
  13. template<class CT>
  14. struct bounds
  15. {
  16. static CT lowest () { return boost::numeric::bounds<CT>::lowest(); }
  17. static CT highest () { return boost::numeric::bounds<CT>::highest(); }
  18. };
  19. }}} // namespace boost::geometry::util
  20. #endif // BOOST_GEOMETRY_UTIL_BOUNDS_HPP