diff --git a/include/boost/decimal/decimal128_t.hpp b/include/boost/decimal/decimal128_t.hpp index 41c7bfcfd..d0e646ec6 100644 --- a/include/boost/decimal/decimal128_t.hpp +++ b/include/boost/decimal/decimal128_t.hpp @@ -2159,16 +2159,10 @@ constexpr auto scalbnd128(decimal128_t num, const int expval) noexcept -> decima namespace std { template<> -#ifdef _MSC_VER class numeric_limits -#else -struct numeric_limits -#endif { -#ifdef _MSC_VER - public: -#endif +public: static constexpr bool is_specialized = true; static constexpr bool is_signed = true; diff --git a/include/boost/decimal/decimal32_t.hpp b/include/boost/decimal/decimal32_t.hpp index 18963f799..b1c3866b0 100644 --- a/include/boost/decimal/decimal32_t.hpp +++ b/include/boost/decimal/decimal32_t.hpp @@ -2229,16 +2229,10 @@ constexpr auto copysignd32(decimal32_t mag, const decimal32_t sgn) noexcept -> d namespace std { template <> -#ifdef _MSC_VER class numeric_limits -#else -struct numeric_limits -#endif { -#ifdef _MSC_VER public: -#endif static constexpr bool is_specialized = true; static constexpr bool is_signed = true; diff --git a/include/boost/decimal/decimal64_t.hpp b/include/boost/decimal/decimal64_t.hpp index 7391c5730..dd0910976 100644 --- a/include/boost/decimal/decimal64_t.hpp +++ b/include/boost/decimal/decimal64_t.hpp @@ -2107,16 +2107,10 @@ constexpr auto copysignd64(decimal64_t mag, const decimal64_t sgn) noexcept -> d namespace std { template <> -#ifdef _MSC_VER class numeric_limits -#else -struct numeric_limits -#endif { -#ifdef _MSC_VER - public: -#endif +public: static constexpr bool is_specialized = true; static constexpr bool is_signed = true; diff --git a/include/boost/decimal/decimal_fast128_t.hpp b/include/boost/decimal/decimal_fast128_t.hpp index cf32914c2..f5e4a315f 100644 --- a/include/boost/decimal/decimal_fast128_t.hpp +++ b/include/boost/decimal/decimal_fast128_t.hpp @@ -1564,17 +1564,11 @@ constexpr auto quantized128f(const decimal_fast128_t& lhs, const decimal_fast128 namespace std { -template<> -#ifdef _MSC_VER +template <> class numeric_limits -#else -struct numeric_limits -#endif { -#ifdef _MSC_VER - public: -#endif +public: static constexpr bool is_specialized = true; static constexpr bool is_signed = true; diff --git a/include/boost/decimal/decimal_fast32_t.hpp b/include/boost/decimal/decimal_fast32_t.hpp index 113241b92..f59be81fc 100644 --- a/include/boost/decimal/decimal_fast32_t.hpp +++ b/include/boost/decimal/decimal_fast32_t.hpp @@ -1527,16 +1527,11 @@ constexpr auto quantized32f(const decimal_fast32_t lhs, const decimal_fast32_t r namespace std { template <> -#ifdef _MSC_VER class numeric_limits -#else -struct numeric_limits -#endif { -#ifdef _MSC_VER - public: -#endif +public: + static constexpr bool is_specialized = true; static constexpr bool is_signed = true; diff --git a/include/boost/decimal/decimal_fast64_t.hpp b/include/boost/decimal/decimal_fast64_t.hpp index 5474e43ca..5aaa9e9b6 100644 --- a/include/boost/decimal/decimal_fast64_t.hpp +++ b/include/boost/decimal/decimal_fast64_t.hpp @@ -1486,15 +1486,10 @@ constexpr auto copysignd64f(decimal_fast64_t mag, const decimal_fast64_t sgn) no namespace std { template <> -#ifdef _MSC_VER class numeric_limits -#else -struct numeric_limits -#endif { -#ifdef _MSC_VER - public: -#endif + +public: static constexpr bool is_specialized = true; static constexpr bool is_signed = true; diff --git a/include/boost/decimal/detail/u256.hpp b/include/boost/decimal/detail/u256.hpp index f65ac96bb..690248a8d 100644 --- a/include/boost/decimal/detail/u256.hpp +++ b/include/boost/decimal/detail/u256.hpp @@ -1221,6 +1221,7 @@ struct numeric_limits class numeric_limits #endif { + public: // Member constants diff --git a/include/boost/decimal/fwd.hpp b/include/boost/decimal/fwd.hpp index 3a519b1c2..06a55811c 100644 --- a/include/boost/decimal/fwd.hpp +++ b/include/boost/decimal/fwd.hpp @@ -26,46 +26,22 @@ class decimal_fast128_t; namespace std { template <> -#ifdef _MSC_VER class numeric_limits; -#else -struct numeric_limits; -#endif template <> -#ifdef _MSC_VER -class numeric_limits; -#else -struct numeric_limits; -#endif +class numeric_limits; template <> -#ifdef _MSC_VER -class numeric_limits; -#else -struct numeric_limits; -#endif +class numeric_limits; template <> -#ifdef _MSC_VER -class numeric_limits; -#else -struct numeric_limits; -#endif +class numeric_limits; template <> -#ifdef _MSC_VER -class numeric_limits; -#else -struct numeric_limits; -#endif +class numeric_limits; template <> -#ifdef _MSC_VER class numeric_limits; -#else -struct numeric_limits; -#endif } // Namespace std diff --git a/modules/decimal.cxx b/modules/decimal.cxx index d77f323f2..811912743 100644 --- a/modules/decimal.cxx +++ b/modules/decimal.cxx @@ -81,46 +81,22 @@ class decimal_fast128_t; export namespace std { template <> -#ifdef _MSC_VER class numeric_limits; -#else -struct numeric_limits; -#endif template <> -#ifdef _MSC_VER class numeric_limits; -#else -struct numeric_limits; -#endif template <> -#ifdef _MSC_VER class numeric_limits; -#else -struct numeric_limits; -#endif template <> -#ifdef _MSC_VER class numeric_limits; -#else -struct numeric_limits; -#endif template <> -#ifdef _MSC_VER class numeric_limits; -#else -struct numeric_limits; -#endif template <> -#ifdef _MSC_VER class numeric_limits; -#else -struct numeric_limits; -#endif } // Namespace std