// (C) Copyright John Maddock 2005. // Use, modification and distribution are subject to the Boost Software License, // Version 1.0. (See accompanying file LICENSE_1_0.txt or copy at // http://www.boost.org/LICENSE_1_0.txt). // // See http://www.boost.org/libs/type_traits for most recent version including documentation. #ifndef BOOST_TT_IS_UNSIGNED_HPP_INCLUDED #define BOOST_TT_IS_UNSIGNED_HPP_INCLUDED #include #include #include #include // should be the last #include #include namespace boost { #if !defined( __CODEGEARC__ ) namespace detail{ #if !(defined(__EDG_VERSION__) && __EDG_VERSION__ <= 238) template struct is_ununsigned_helper { typedef typename remove_cv::type no_cv_t; BOOST_STATIC_CONSTANT(bool, value = (static_cast(-1) > 0)); }; template struct is_ununsigned_select_helper { template struct rebind { typedef is_ununsigned_helper type; }; }; template <> struct is_ununsigned_select_helper { template struct rebind { typedef false_type type; }; }; template struct is_unsigned_imp { typedef is_ununsigned_select_helper< ::boost::type_traits::ice_or< ::boost::is_integral::value, ::boost::is_enum::value>::value > selector; typedef typename selector::template rebind binder; typedef typename binder::type type; BOOST_STATIC_CONSTANT(bool, value = type::value); }; #else template struct is_unsigned_imp : public false_type{}; template <> struct is_unsigned_imp : public true_type{}; template <> struct is_unsigned_imp : public true_type{}; template <> struct is_unsigned_imp : public true_type{}; template <> struct is_unsigned_imp : public true_type{}; template <> struct is_unsigned_imp : public true_type{}; template <> struct is_unsigned_imp : public true_type{}; template <> struct is_unsigned_imp : public true_type{}; template <> struct is_unsigned_imp : public true_type{}; template <> struct is_unsigned_imp : public true_type{}; template <> struct is_unsigned_imp : public true_type{}; template <> struct is_unsigned_imp : public true_type{}; template <> struct is_unsigned_imp : public true_type{}; template <> struct is_unsigned_imp : public true_type{}; template <> struct is_unsigned_imp : public true_type{}; template <> struct is_unsigned_imp : public true_type{}; template <> struct is_unsigned_imp : public true_type{}; #ifdef BOOST_HAS_LONG_LONG template <> struct is_unsigned_imp : public true_type{}; template <> struct is_unsigned_imp : public true_type{}; template <> struct is_unsigned_imp : public true_type{}; template <> struct is_unsigned_imp : public true_type{}; #endif #if defined(CHAR_MIN) && (CHAR_MIN == 0) template <> struct is_unsigned_imp : public true_type{}; template <> struct is_unsigned_imp : public true_type{}; template <> struct is_unsigned_imp : public true_type{}; template <> struct is_unsigned_imp : public true_type{}; #endif #if defined(WCHAR_MIN) && (WCHAR_MIN == 0) template <> struct is_unsigned_imp : public true_type{}; template <> struct is_unsigned_imp : public true_type{}; template <> struct is_unsigned_imp : public true_type{}; template <> struct is_unsigned_imp : public true_type{}; #endif #endif } #endif // !defined( __CODEGEARC__ ) #if defined( __CODEGEARC__ ) BOOST_TT_AUX_BOOL_TRAIT_DEF1(is_unsigned,T,__is_unsigned(T)) #else BOOST_TT_AUX_BOOL_TRAIT_DEF1(is_unsigned,T,::boost::detail::is_unsigned_imp::value) #endif } // namespace boost #include #endif // BOOST_TT_IS_MEMBER_FUNCTION_POINTER_HPP_INCLUDED