2
// (C) Copyright Dave Abrahams, Steve Cleary, Beman Dawes, Howard
3
// Hinnant & John Maddock 2000. Permission to copy, use, modify,
4
// sell and distribute this software is granted provided this
5
// copyright notice appears in all copies. This software is provided
6
// "as is" without express or implied warranty, and with no claim as
7
// to its suitability for any purpose.
9
// See http://www.boost.org for most recent version including documentation.
11
#ifndef BOOST_TT_IS_MEMBER_FUNCTION_POINTER_HPP_INCLUDED
12
#define BOOST_TT_IS_MEMBER_FUNCTION_POINTER_HPP_INCLUDED
14
#include "boost/type_traits/config.hpp"
16
#if !defined(BOOST_NO_TEMPLATE_PARTIAL_SPECIALIZATION) && !defined(__BORLANDC__)
17
# include "boost/type_traits/detail/is_mem_fun_pointer_impl.hpp"
19
# include "boost/type_traits/is_reference.hpp"
20
# include "boost/type_traits/is_array.hpp"
21
# include "boost/type_traits/detail/is_mem_fun_pointer_tester.hpp"
22
# include "boost/type_traits/detail/yes_no_type.hpp"
23
# include "boost/type_traits/detail/false_result.hpp"
24
# include "boost/type_traits/detail/ice_or.hpp"
27
// should be the last #include
28
#include "boost/type_traits/detail/bool_trait_def.hpp"
32
#if !defined(BOOST_NO_TEMPLATE_PARTIAL_SPECIALIZATION) && !defined(__BORLANDC__)
34
BOOST_TT_AUX_BOOL_TRAIT_DEF1(
35
is_member_function_pointer
37
, ::boost::type_traits::is_mem_fun_pointer_impl<T>::value
47
struct is_mem_fun_pointer_select
48
: ::boost::type_traits::false_result
53
struct is_mem_fun_pointer_select<false>
55
template <typename T> struct result_
58
typedef result_<T> self_type;
60
BOOST_STATIC_CONSTANT(
62
1 == sizeof(::boost::type_traits::is_mem_fun_pointer_tester(self_type::make_t))
68
struct is_member_function_pointer_impl
69
: is_mem_fun_pointer_select<
70
::boost::type_traits::ice_or<
71
::boost::is_reference<T>::value
72
, ::boost::is_array<T>::value
74
>::template result_<T>
81
struct is_member_function_pointer_impl
84
BOOST_STATIC_CONSTANT(
86
(1 == sizeof(type_traits::is_mem_fun_pointer_tester(m_t))) );
90
struct is_member_function_pointer_impl<T&>
92
BOOST_STATIC_CONSTANT(bool, value = false);
97
BOOST_TT_AUX_BOOL_TRAIT_IMPL_SPEC1(is_member_function_pointer,void,false)
98
#ifndef BOOST_NO_CV_VOID_SPECIALIZATIONS
99
BOOST_TT_AUX_BOOL_TRAIT_IMPL_SPEC1(is_member_function_pointer,void const,false)
100
BOOST_TT_AUX_BOOL_TRAIT_IMPL_SPEC1(is_member_function_pointer,void volatile,false)
101
BOOST_TT_AUX_BOOL_TRAIT_IMPL_SPEC1(is_member_function_pointer,void const volatile,false)
104
} // namespace detail
106
BOOST_TT_AUX_BOOL_TRAIT_DEF1(is_member_function_pointer,T,::boost::detail::is_member_function_pointer_impl<T>::value)
108
#endif // BOOST_NO_TEMPLATE_PARTIAL_SPECIALIZATION
112
#include "boost/type_traits/detail/bool_trait_undef.hpp"
114
#endif // BOOST_TT_IS_MEMBER_FUNCTION_POINTER_HPP_INCLUDED