From 0bb9f97e12001d5f8bac153fdb54826ebaa84737 Mon Sep 17 00:00:00 2001 From: John Maddock Date: Sat, 5 May 2001 10:59:06 +0000 Subject: [PATCH] Removed use of member templates for MWCW 5.x compatiblilty [SVN r10010] --- include/boost/type_traits/function_traits.hpp | 26 +++++++------------ 1 file changed, 9 insertions(+), 17 deletions(-) diff --git a/include/boost/type_traits/function_traits.hpp b/include/boost/type_traits/function_traits.hpp index 5f11a46..b336c78 100644 --- a/include/boost/type_traits/function_traits.hpp +++ b/include/boost/type_traits/function_traits.hpp @@ -113,34 +113,26 @@ struct is_function_ref_helper BOOST_STATIC_CONSTANT(bool, value = false); }; - -template +#if !defined(BOOST_NO_TEMPLATE_PARTIAL_SPECIALIZATION) +template struct is_function_chooser { - template - struct rebind - { - typedef is_function_helper type; - }; + typedef is_function_helper type; }; -template <> -struct is_function_chooser +template +struct is_function_chooser { - template - struct rebind - { - typedef is_function_ref_helper type; - }; + typedef is_function_ref_helper type; }; +#endif } // namespace detail template struct is_function { private: -#if !defined(BOOST_NO_TEMPLATE_PARTIAL_SPECIALIZATION) && !defined(BOOST_NO_MEMBER_TEMPLATES) - typedef typename detail::is_function_chooser< ::boost::is_reference::value>::template rebind binder; - typedef typename binder::type m_type; +#if !defined(BOOST_NO_TEMPLATE_PARTIAL_SPECIALIZATION) + typedef typename detail::is_function_chooser::value>::type m_type; #else // without partial specialistaion we can't use is_reference on // function types, that leaves this template broken in the case that