17 #ifndef HH_SENF_Utils_type_traits_ 18 #define HH_SENF_Utils_type_traits_ 1 21 #include <boost/type_traits/function_traits.hpp> 22 #include <boost/type_traits/remove_pointer.hpp> 23 #include <boost/type_traits/is_function.hpp> 24 #include <boost/type_traits/remove_cv.hpp> 25 #include <boost/type_traits/remove_reference.hpp> 26 #include <boost/bind.hpp> 27 #include <senf/config.hh> 59 template <
class Traits,
unsigned arity = Traits::arity >
82 template <
class Traits,
int index,
bool flag = (index < Traits::arity) >
83 struct function_traits_arg_type {};
87 template <
class Traits,
int index >
216 :
public boost::is_function < typename senf::remove_any_pointer < T >::type >
234 :
public boost::remove_cv< typename boost::remove_reference<T>::type >
248 :
public boost::integral_constant<
250 boost::function_traits<
251 typename senf::remove_any_pointer<T>::type>::arity>
264 template <
class Pair>
266 :
public boost::false_type
270 template <
class First,
class Second>
271 struct is_pair< std::pair<First,Second> >
272 :
public boost::true_type
280 # define BOOST_PP_ITERATION_PARAMS_1 (4, (0, 10, \ 281 SENF_ABSOLUTE_INCLUDE_PATH(Utils/type_traits.mpp), \ 283 # include BOOST_PP_ITERATE()
Remove reference and CV qualification from type.
Test object if it is a function or member-function (pointer)
Strip first parameter from function traits.
Get class of a member pointer.
Remove any type of pointer from type.
Get argument type from function traits.
Remove member pointer from type.