]> git.proxmox.com Git - ceph.git/blob - ceph/src/boost/boost/callable_traits/detail/pmf.hpp
update sources to v12.2.3
[ceph.git] / ceph / src / boost / boost / callable_traits / detail / pmf.hpp
1 /*
2
3 @Copyright Barrett Adair 2015-2017
4 Distributed under the Boost Software License, Version 1.0.
5 (See accompanying file LICENSE.md or copy at http://boost.org/LICENSE_1_0.txt)
6
7 */
8
9 #ifndef BOOST_CLBL_TRTS_DETAIL_PMF_HPP
10 #define BOOST_CLBL_TRTS_DETAIL_PMF_HPP
11
12 #include <boost/callable_traits/detail/forward_declarations.hpp>
13 #include <boost/callable_traits/detail/set_function_qualifiers.hpp>
14 #include <boost/callable_traits/detail/qualifier_flags.hpp>
15 #include <boost/callable_traits/detail/default_callable_traits.hpp>
16 #include <boost/callable_traits/detail/utility.hpp>
17
18 namespace boost { namespace callable_traits { namespace detail {
19
20 template<qualifier_flags Applied, bool IsTransactionSafe, bool IsNoExcept,
21 typename CallingConvention, typename T, typename Return,
22 typename... Args>
23 struct set_member_function_qualifiers_t;
24
25 template<qualifier_flags Applied, bool IsTransactionSafe, bool IsNoexcept,
26 typename CallingConvention, typename T, typename Return,
27 typename... Args>
28 struct set_varargs_member_function_qualifiers_t;
29
30 template<qualifier_flags Flags, bool IsTransactionSafe, bool IsNoexcept,
31 typename... Ts>
32 using set_member_function_qualifiers =
33 typename set_member_function_qualifiers_t<Flags, IsTransactionSafe,
34 IsNoexcept, Ts...>::type;
35
36 template<qualifier_flags Flags, bool IsTransactionSafe, bool IsNoexcept,
37 typename... Ts>
38 using set_varargs_member_function_qualifiers =
39 typename set_varargs_member_function_qualifiers_t<Flags,
40 IsTransactionSafe, IsNoexcept, Ts...>::type;
41
42 template<typename T>
43 struct pmf : default_callable_traits<T> {};
44
45 #define BOOST_CLBL_TRTS_CC_TAG dummy
46 #define BOOST_CLBL_TRTS_VARARGS_CC BOOST_CLBL_TRTS_DEFAULT_VARARGS_CC
47 #define BOOST_CLBL_TRTS_CC
48 #include <boost/callable_traits/detail/unguarded/pmf.hpp>
49 #undef BOOST_CLBL_TRTS_CC
50 #undef BOOST_CLBL_TRTS_CC_TAG
51 #undef BOOST_CLBL_TRTS_VARARGS_CC
52
53 #define BOOST_CLBL_TRTS_CC_TAG dummy
54 #define BOOST_CLBL_TRTS_VARARGS_CC BOOST_CLBL_TRTS_DEFAULT_VARARGS_CC
55 #define BOOST_CLBL_TRTS_CC
56 #include <boost/callable_traits/detail/unguarded/pmf_varargs.hpp>
57 #undef BOOST_CLBL_TRTS_CC
58 #undef BOOST_CLBL_TRTS_CC_TAG
59 #undef BOOST_CLBL_TRTS_VARARGS_CC
60
61 #ifdef BOOST_CLBL_TRTS_ENABLE_CDECL
62 #define BOOST_CLBL_TRTS_CC_TAG cdecl_tag
63 #define BOOST_CLBL_TRTS_VARARGS_CC __cdecl
64 #define BOOST_CLBL_TRTS_CC __cdecl
65 #include <boost/callable_traits/detail/unguarded/pmf.hpp>
66 #undef BOOST_CLBL_TRTS_CC
67 #undef BOOST_CLBL_TRTS_CC_TAG
68 #undef BOOST_CLBL_TRTS_VARARGS_CC
69 #endif // #ifdef BOOST_CLBL_TRTS_ENABLE_CDECL
70
71 // Defining this macro enables undocumented features, likely broken.
72 // Too much work to maintain, but knock yourself out
73 #ifdef BOOST_CLBL_TRTS_ENABLE_STDCALL
74 #define BOOST_CLBL_TRTS_CC_TAG stdcall_tag
75 #define BOOST_CLBL_TRTS_VARARGS_CC BOOST_CLBL_TRTS_DEFAULT_VARARGS_CC
76 #define BOOST_CLBL_TRTS_CC __stdcall
77 #include <boost/callable_traits/detail/unguarded/pmf.hpp>
78 #undef BOOST_CLBL_TRTS_CC
79 #undef BOOST_CLBL_TRTS_CC_TAG
80 #undef BOOST_CLBL_TRTS_VARARGS_CC
81 #endif // #ifdef BOOST_CLBL_TRTS_ENABLE_STDCALL
82
83 // Defining this macro enables undocumented features, likely broken.
84 // Too much work to officially maintain, but knock yourself out
85 #ifdef BOOST_CLBL_TRTS_ENABLE_FASTCALL
86 #define BOOST_CLBL_TRTS_CC_TAG fastcall_tag
87 #define BOOST_CLBL_TRTS_VARARGS_CC BOOST_CLBL_TRTS_DEFAULT_VARARGS_CC
88 #define BOOST_CLBL_TRTS_CC __fastcall
89 #include <boost/callable_traits/detail/unguarded/pmf.hpp>
90 #undef BOOST_CLBL_TRTS_CC
91 #undef BOOST_CLBL_TRTS_CC_TAG
92 #undef BOOST_CLBL_TRTS_VARARGS_CC
93 #endif // #ifdef BOOST_CLBL_TRTS_ENABLE_FASTCALL
94
95 }}} // namespace boost::callable_traits::detail
96
97 #endif // #ifndef BOOST_CLBL_TRTS_DETAIL_PMF_HPP