diff --git a/include/boost/mpl/aux_/has_xxx.hpp b/include/boost/mpl/aux_/has_xxx.hpp index 08b259b..00131ec 100644 --- a/include/boost/mpl/aux_/has_xxx.hpp +++ b/include/boost/mpl/aux_/has_xxx.hpp @@ -33,23 +33,25 @@ # define BOOST_MPL_HAS_XXX_TRAIT_NAMED_DEF(trait, name, unused) \ template< typename T > \ -boost::mpl::aux::yes_tag \ -trait##_helper( \ - boost::mpl::aux::type_wrapper const volatile* \ - , boost::mpl::aux::type_wrapper* = 0 \ - ); \ - \ -boost::mpl::aux::no_tag \ -trait##_helper(...); \ - \ -template< typename T > \ struct trait \ { \ + template< typename U > \ + static boost::mpl::aux::yes_tag \ + helper( \ + boost::mpl::aux::type_wrapper const volatile* \ + , boost::mpl::aux::type_wrapper* = 0 \ + ); \ + \ + static boost::mpl::aux::no_tag \ + helper(...); \ + \ typedef boost::mpl::aux::type_wrapper t_; \ - BOOST_STATIC_CONSTANT(bool, value = \ - sizeof((trait##_helper)(static_cast(0))) \ - == sizeof(boost::mpl::aux::yes_tag) \ - ); \ + \ + BOOST_STATIC_CONSTANT( \ + bool, value = \ + sizeof(trait::helper(static_cast(0))) \ + == sizeof(boost::mpl::aux::yes_tag) \ + ); \ }; \ /**/