annotate DEPENDENCIES/generic/include/boost/mpl/arg.hpp @ 125:34e428693f5d vext

Vext -> Repoint
author Chris Cannam
date Thu, 14 Jun 2018 11:15:39 +0100
parents c530137014c0
children
rev   line source
Chris@16 1
Chris@16 2 #if !defined(BOOST_PP_IS_ITERATING)
Chris@16 3
Chris@16 4 ///// header body
Chris@16 5
Chris@16 6 #ifndef BOOST_MPL_ARG_HPP_INCLUDED
Chris@16 7 #define BOOST_MPL_ARG_HPP_INCLUDED
Chris@16 8
Chris@16 9 // Copyright Peter Dimov 2001-2002
Chris@16 10 // Copyright Aleksey Gurtovoy 2001-2004
Chris@16 11 //
Chris@16 12 // Distributed under the Boost Software License, Version 1.0.
Chris@16 13 // (See accompanying file LICENSE_1_0.txt or copy at
Chris@16 14 // http://www.boost.org/LICENSE_1_0.txt)
Chris@16 15 //
Chris@16 16 // See http://www.boost.org/libs/mpl for documentation.
Chris@16 17
Chris@101 18 // $Id$
Chris@101 19 // $Date$
Chris@101 20 // $Revision$
Chris@16 21
Chris@16 22 #if !defined(BOOST_MPL_PREPROCESSING_MODE)
Chris@16 23 # include <boost/mpl/arg_fwd.hpp>
Chris@16 24 # include <boost/mpl/aux_/na.hpp>
Chris@16 25 # include <boost/mpl/aux_/na_assert.hpp>
Chris@16 26 # include <boost/mpl/aux_/arity_spec.hpp>
Chris@16 27 # include <boost/mpl/aux_/arg_typedef.hpp>
Chris@16 28 #endif
Chris@16 29
Chris@16 30 #include <boost/mpl/aux_/config/static_constant.hpp>
Chris@16 31 #include <boost/mpl/aux_/config/use_preprocessed.hpp>
Chris@16 32
Chris@16 33 #if !defined(BOOST_MPL_CFG_NO_PREPROCESSED_HEADERS) \
Chris@16 34 && !defined(BOOST_MPL_PREPROCESSING_MODE)
Chris@16 35
Chris@16 36 # define BOOST_MPL_PREPROCESSED_HEADER arg.hpp
Chris@16 37 # include <boost/mpl/aux_/include_preprocessed.hpp>
Chris@16 38
Chris@16 39 #else
Chris@16 40
Chris@16 41 # include <boost/mpl/limits/arity.hpp>
Chris@16 42 # include <boost/mpl/aux_/preprocessor/default_params.hpp>
Chris@16 43 # include <boost/mpl/aux_/preprocessor/params.hpp>
Chris@16 44 # include <boost/mpl/aux_/config/lambda.hpp>
Chris@16 45 # include <boost/mpl/aux_/config/dtp.hpp>
Chris@16 46 # include <boost/mpl/aux_/nttp_decl.hpp>
Chris@16 47
Chris@16 48 # include <boost/preprocessor/iterate.hpp>
Chris@16 49 # include <boost/preprocessor/inc.hpp>
Chris@16 50 # include <boost/preprocessor/cat.hpp>
Chris@16 51
Chris@16 52 BOOST_MPL_AUX_ADL_BARRIER_NAMESPACE_OPEN
Chris@16 53
Chris@16 54 // local macro, #undef-ined at the end of the header
Chris@16 55 #if !defined(BOOST_MPL_CFG_NO_DEFAULT_PARAMETERS_IN_NESTED_TEMPLATES)
Chris@16 56 # define AUX778076_ARG_N_DEFAULT_PARAMS(param,value) \
Chris@16 57 BOOST_MPL_PP_DEFAULT_PARAMS( \
Chris@16 58 BOOST_MPL_LIMIT_METAFUNCTION_ARITY \
Chris@16 59 , param \
Chris@16 60 , value \
Chris@16 61 ) \
Chris@16 62 /**/
Chris@16 63 #else
Chris@16 64 # define AUX778076_ARG_N_DEFAULT_PARAMS(param,value) \
Chris@16 65 BOOST_MPL_PP_PARAMS( \
Chris@16 66 BOOST_MPL_LIMIT_METAFUNCTION_ARITY \
Chris@16 67 , param \
Chris@16 68 ) \
Chris@16 69 /**/
Chris@16 70 #endif
Chris@16 71
Chris@16 72 #define BOOST_PP_ITERATION_PARAMS_1 \
Chris@16 73 (3,(0, BOOST_MPL_LIMIT_METAFUNCTION_ARITY, <boost/mpl/arg.hpp>))
Chris@16 74 #include BOOST_PP_ITERATE()
Chris@16 75
Chris@16 76
Chris@16 77 # undef AUX778076_ARG_N_DEFAULT_PARAMS
Chris@16 78
Chris@16 79 BOOST_MPL_AUX_NONTYPE_ARITY_SPEC(1,int,arg)
Chris@16 80
Chris@16 81 BOOST_MPL_AUX_ADL_BARRIER_NAMESPACE_CLOSE
Chris@16 82
Chris@16 83 #endif // BOOST_MPL_CFG_NO_PREPROCESSED_HEADERS
Chris@16 84 #endif // BOOST_MPL_ARG_HPP_INCLUDED
Chris@16 85
Chris@16 86 ///// iteration
Chris@16 87
Chris@16 88 #else
Chris@16 89 #define i_ BOOST_PP_FRAME_ITERATION(1)
Chris@16 90
Chris@16 91 #if i_ > 0
Chris@16 92
Chris@16 93 template<> struct arg<i_>
Chris@16 94 {
Chris@16 95 BOOST_STATIC_CONSTANT(int, value = i_);
Chris@16 96 typedef arg<BOOST_PP_INC(i_)> next;
Chris@16 97 BOOST_MPL_AUX_ARG_TYPEDEF(na, tag)
Chris@16 98 BOOST_MPL_AUX_ARG_TYPEDEF(na, type)
Chris@16 99
Chris@16 100 template<
Chris@16 101 AUX778076_ARG_N_DEFAULT_PARAMS(typename U, na)
Chris@16 102 >
Chris@16 103 struct apply
Chris@16 104 {
Chris@16 105 typedef BOOST_PP_CAT(U,i_) type;
Chris@16 106 BOOST_MPL_AUX_ASSERT_NOT_NA(type);
Chris@16 107 };
Chris@16 108 };
Chris@16 109
Chris@16 110 #else
Chris@16 111
Chris@16 112 template<> struct arg<-1>
Chris@16 113 {
Chris@16 114 BOOST_STATIC_CONSTANT(int, value = -1);
Chris@16 115 BOOST_MPL_AUX_ARG_TYPEDEF(na, tag)
Chris@16 116 BOOST_MPL_AUX_ARG_TYPEDEF(na, type)
Chris@16 117
Chris@16 118 template<
Chris@16 119 AUX778076_ARG_N_DEFAULT_PARAMS(typename U, na)
Chris@16 120 >
Chris@16 121 struct apply
Chris@16 122 {
Chris@16 123 typedef U1 type;
Chris@16 124 BOOST_MPL_AUX_ASSERT_NOT_NA(type);
Chris@16 125 };
Chris@16 126 };
Chris@16 127
Chris@16 128 #endif // i_ > 0
Chris@16 129
Chris@16 130 #undef i_
Chris@16 131 #endif // BOOST_PP_IS_ITERATING