diff --git a/include/boost/type_traits/is_abstract.hpp b/include/boost/type_traits/is_abstract.hpp index 49c67e4..3c8457f 100755 --- a/include/boost/type_traits/is_abstract.hpp +++ b/include/boost/type_traits/is_abstract.hpp @@ -64,7 +64,7 @@ namespace detail{ #ifndef BOOST_NO_IS_ABSTRACT template -struct is_abstract_imp +struct is_abstract_imp2 { // Deduction fails if T is void, function type, // reference type (14.8.2/2)or an abstract class type @@ -89,11 +89,38 @@ struct is_abstract_imp #endif BOOST_STATIC_CONSTANT(bool, value = - (::boost::type_traits::ice_and< - ::boost::is_class::value, - (s1 == sizeof(type_traits::yes_type)) - >::value)); + (s1 == sizeof(type_traits::yes_type))); }; + +template +struct is_abstract_select +{ + template + struct rebind + { + typedef is_abstract_imp2 type; + }; +}; +template <> +struct is_abstract_select +{ + template + struct rebind + { + typedef false_type type; + }; +}; + +template +struct is_abstract_imp +{ + typedef is_abstract_select< ::boost::is_class::value> selector; + typedef typename selector::template rebind binder; + typedef typename binder::type type; + + BOOST_STATIC_CONSTANT(bool, value = type::value); +}; + #endif }