36 #include <type_traits> 51 template<
class Functor,
class Argument>
60 private_type
const &operator,(
int)
const;
63 typedef char yes_type;
64 typedef char (&no_type)[2];
67 static no_type is_private_type(T
const &);
69 static yes_type is_private_type(private_type
const &);
71 template<
typename Fun>
75 typedef private_type
const &(*pointer_to_function)(dont_care);
76 operator pointer_to_function()
const;
79 static funwrap<Functor> & m_fun;
80 static Argument & m_arg;
83 sizeof(no_type) ==
sizeof(is_private_type( (m_fun(m_arg), 0) ))
86 typedef std::integral_constant<bool, value> type;
89 template<
class R,
class T,
class Argument>
91 typedef std::integral_constant<bool, std::is_convertible<T, Argument>::value > type;
92 static bool const value = type::value;
94 template<
class R,
class T,
class Argument>
96 typedef std::integral_constant<bool, std::is_convertible<T, Argument>::value > type;
97 static bool const value = type::value;