diff --git a/include/boost/detail/limits.hpp b/include/boost/detail/limits.hpp index cb296ca8..21bc627c 100644 --- a/include/boost/detail/limits.hpp +++ b/include/boost/detail/limits.hpp @@ -274,24 +274,23 @@ class numeric_limits {}; #ifndef BOOST_NO_INTRINSIC_WCHAR_T +template<> +class numeric_limits #if !defined(WCHAR_MAX) || !defined(WCHAR_MIN) -#if !defined(_WIN32) && !defined(__CYGWIN__) -template<> -class numeric_limits - : public _Integer_limits -{}; -#else -template<> -class numeric_limits +#if defined(_WIN32) || defined(__CYGWIN__) : public _Integer_limits -{}; +#elif defined(__hppa) +// wchar_t has "unsigned int" as the underlying type + : public _Integer_limits +#else +// assume that wchar_t has "int" as the underlying type + : public _Integer_limits #endif #else -template<> -class numeric_limits +// we have WCHAR_MIN and WCHAR_MAX defined, so use it : public _Integer_limits -{}; #endif +{}; #endif template<>