updated boost on windows
This commit is contained in:
58
winx64/include/boost/metaparse/v1/cpp98/impl/at_c.hpp
Normal file
58
winx64/include/boost/metaparse/v1/cpp98/impl/at_c.hpp
Normal file
@@ -0,0 +1,58 @@
|
||||
#ifndef BOOST_METAPARSE_V1_CPP98_IMPL_AT_C_HPP
|
||||
#define BOOST_METAPARSE_V1_CPP98_IMPL_AT_C_HPP
|
||||
|
||||
// Copyright Abel Sinkovics (abel@sinkovics.hu) 2013.
|
||||
// Distributed under the Boost Software License, Version 1.0.
|
||||
// (See accompanying file LICENSE_1_0.txt or copy at
|
||||
// http://www.boost.org/LICENSE_1_0.txt)
|
||||
|
||||
#include <boost/metaparse/config.hpp>
|
||||
#include <boost/metaparse/v1/cpp98/fwd/string.hpp>
|
||||
|
||||
#include <boost/mpl/char.hpp>
|
||||
|
||||
#include <boost/preprocessor/repetition/enum_params.hpp>
|
||||
#include <boost/preprocessor/repetition/repeat.hpp>
|
||||
|
||||
namespace boost
|
||||
{
|
||||
namespace metaparse
|
||||
{
|
||||
namespace v1
|
||||
{
|
||||
namespace impl
|
||||
{
|
||||
template <class S, int N>
|
||||
struct at_c;
|
||||
|
||||
#ifdef BOOST_METAPARSE_STRING_CASE
|
||||
# error BOOST_METAPARSE_STRING_CASE is already defined
|
||||
#endif
|
||||
#define BOOST_METAPARSE_STRING_CASE(z, n, unused) \
|
||||
template < \
|
||||
BOOST_PP_ENUM_PARAMS(BOOST_METAPARSE_LIMIT_STRING_SIZE, int C) \
|
||||
> \
|
||||
struct \
|
||||
at_c< \
|
||||
string< \
|
||||
BOOST_PP_ENUM_PARAMS(BOOST_METAPARSE_LIMIT_STRING_SIZE, C) \
|
||||
>, \
|
||||
n \
|
||||
> : \
|
||||
boost::mpl::char_<BOOST_PP_CAT(C, n)> \
|
||||
{};
|
||||
|
||||
BOOST_PP_REPEAT(
|
||||
BOOST_METAPARSE_LIMIT_STRING_SIZE,
|
||||
BOOST_METAPARSE_STRING_CASE,
|
||||
~
|
||||
)
|
||||
|
||||
#undef BOOST_METAPARSE_STRING_CASE
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
#endif
|
||||
|
||||
@@ -0,0 +1,33 @@
|
||||
#ifndef BOOST_METAPARSE_V1_CPP98_IMPL_EMPTY_STRING_HPP
|
||||
#define BOOST_METAPARSE_V1_CPP98_IMPL_EMPTY_STRING_HPP
|
||||
|
||||
// Copyright Abel Sinkovics (abel@sinkovics.hu) 2013.
|
||||
// Distributed under the Boost Software License, Version 1.0.
|
||||
// (See accompanying file LICENSE_1_0.txt or copy at
|
||||
// http://www.boost.org/LICENSE_1_0.txt)
|
||||
|
||||
namespace boost
|
||||
{
|
||||
namespace metaparse
|
||||
{
|
||||
namespace v1
|
||||
{
|
||||
namespace impl
|
||||
{
|
||||
template <class Ignore = int>
|
||||
struct empty_string
|
||||
{
|
||||
typedef empty_string type;
|
||||
|
||||
static const char value[1];
|
||||
};
|
||||
|
||||
template <class Ignore>
|
||||
const char empty_string<Ignore>::value[1] = {0};
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
#endif
|
||||
|
||||
61
winx64/include/boost/metaparse/v1/cpp98/impl/nth_of_c.hpp
Normal file
61
winx64/include/boost/metaparse/v1/cpp98/impl/nth_of_c.hpp
Normal file
@@ -0,0 +1,61 @@
|
||||
#ifndef BOOST_METAPARSE_V1_CPP98_IMPL_NTH_OF_C_HPP
|
||||
#define BOOST_METAPARSE_V1_CPP98_IMPL_NTH_OF_C_HPP
|
||||
|
||||
// Copyright Abel Sinkovics (abel@sinkovics.hu) 2013.
|
||||
// Distributed under the Boost Software License, Version 1.0.
|
||||
// (See accompanying file LICENSE_1_0.txt or copy at
|
||||
// http://www.boost.org/LICENSE_1_0.txt)
|
||||
|
||||
#include <boost/metaparse/v1/cpp98/impl/nth_of_c_impl.hpp>
|
||||
#include <boost/metaparse/v1/error/index_out_of_range.hpp>
|
||||
#include <boost/metaparse/v1/fail.hpp>
|
||||
#include <boost/metaparse/limit_sequence_size.hpp>
|
||||
|
||||
#include <boost/mpl/list.hpp>
|
||||
|
||||
#include <boost/preprocessor/repetition/repeat.hpp>
|
||||
#include <boost/preprocessor/punctuation/comma_if.hpp>
|
||||
#include <boost/preprocessor/repetition/enum_params.hpp>
|
||||
#include <boost/preprocessor/cat.hpp>
|
||||
|
||||
namespace boost
|
||||
{
|
||||
namespace metaparse
|
||||
{
|
||||
namespace v1
|
||||
{
|
||||
namespace impl
|
||||
{
|
||||
#ifdef BOOST_METAPARSE_NTH_OF_CASE
|
||||
# error BOOST_METAPARSE_NTH_OF_CASE already defined
|
||||
#endif
|
||||
#define BOOST_METAPARSE_NTH_OF_CASE(z, n, unused) \
|
||||
template < \
|
||||
int K BOOST_PP_COMMA_IF(n) \
|
||||
BOOST_PP_ENUM_PARAMS(n, class P) \
|
||||
> \
|
||||
struct BOOST_PP_CAT(nth_of_c, n) : \
|
||||
boost::mpl::if_< \
|
||||
boost::mpl::bool_<(0 <= K && K < n)>, \
|
||||
nth_of_c_impl< \
|
||||
K, \
|
||||
boost::mpl::list<BOOST_PP_ENUM_PARAMS(n, P)> \
|
||||
>, \
|
||||
fail<error::index_out_of_range<0, n - 1, K> > \
|
||||
>::type \
|
||||
{};
|
||||
|
||||
BOOST_PP_REPEAT(
|
||||
BOOST_METAPARSE_LIMIT_SEQUENCE_SIZE,
|
||||
BOOST_METAPARSE_NTH_OF_CASE,
|
||||
~
|
||||
)
|
||||
|
||||
#undef BOOST_METAPARSE_NTH_OF_CASE
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
#endif
|
||||
|
||||
@@ -0,0 +1,77 @@
|
||||
#ifndef BOOST_METAPARSE_V1_CPP98_IMPL_NTH_OF_C_IMPL_HPP
|
||||
#define BOOST_METAPARSE_V1_CPP98_IMPL_NTH_OF_C_IMPL_HPP
|
||||
|
||||
// Copyright Abel Sinkovics (abel@sinkovics.hu) 2013.
|
||||
// Distributed under the Boost Software License, Version 1.0.
|
||||
// (See accompanying file LICENSE_1_0.txt or copy at
|
||||
// http://www.boost.org/LICENSE_1_0.txt)
|
||||
|
||||
#include <boost/metaparse/v1/cpp98/impl/skip_seq.hpp>
|
||||
|
||||
#include <boost/mpl/front.hpp>
|
||||
#include <boost/mpl/pop_front.hpp>
|
||||
#include <boost/mpl/fold.hpp>
|
||||
|
||||
namespace boost
|
||||
{
|
||||
namespace metaparse
|
||||
{
|
||||
namespace v1
|
||||
{
|
||||
namespace impl
|
||||
{
|
||||
template <int N, class Seq>
|
||||
struct nth_of_c_impl
|
||||
{
|
||||
private:
|
||||
template <class NextResult>
|
||||
struct apply_unchecked :
|
||||
nth_of_c_impl<
|
||||
N - 1,
|
||||
typename boost::mpl::pop_front<Seq>::type
|
||||
>::template apply<
|
||||
typename get_remaining<NextResult>::type,
|
||||
typename get_position<NextResult>::type
|
||||
>
|
||||
{};
|
||||
public:
|
||||
typedef nth_of_c_impl type;
|
||||
|
||||
template <class S, class Pos>
|
||||
struct apply :
|
||||
boost::mpl::eval_if<
|
||||
typename is_error<
|
||||
typename boost::mpl::front<Seq>::type::template apply<S, Pos>
|
||||
>::type,
|
||||
typename boost::mpl::front<Seq>::type::template apply<S, Pos>,
|
||||
apply_unchecked<
|
||||
typename boost::mpl::front<Seq>::type::template apply<S, Pos>
|
||||
>
|
||||
>
|
||||
{};
|
||||
};
|
||||
|
||||
template <class Seq>
|
||||
struct nth_of_c_impl<0, Seq>
|
||||
{
|
||||
typedef nth_of_c_impl type;
|
||||
|
||||
template <class S, class Pos>
|
||||
struct apply :
|
||||
boost::mpl::fold<
|
||||
typename boost::mpl::pop_front<Seq>::type,
|
||||
typename boost::mpl::front<Seq>::type::template apply<
|
||||
S,
|
||||
Pos
|
||||
>::type,
|
||||
skip_seq
|
||||
>
|
||||
{};
|
||||
};
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
#endif
|
||||
|
||||
39
winx64/include/boost/metaparse/v1/cpp98/impl/pop_back.hpp
Normal file
39
winx64/include/boost/metaparse/v1/cpp98/impl/pop_back.hpp
Normal file
@@ -0,0 +1,39 @@
|
||||
#ifndef BOOST_METAPARSE_V1_CPP98_IMPL_POP_BACK_HPP
|
||||
#define BOOST_METAPARSE_V1_CPP98_IMPL_POP_BACK_HPP
|
||||
|
||||
// Copyright Abel Sinkovics (abel@sinkovics.hu) 2013.
|
||||
// Distributed under the Boost Software License, Version 1.0.
|
||||
// (See accompanying file LICENSE_1_0.txt or copy at
|
||||
// http://www.boost.org/LICENSE_1_0.txt)
|
||||
|
||||
#include <boost/metaparse/v1/cpp98/fwd/string.hpp>
|
||||
#include <boost/metaparse/v1/cpp98/impl/push_front_c.hpp>
|
||||
#include <boost/metaparse/v1/cpp98/impl/size.hpp>
|
||||
#include <boost/metaparse/v1/cpp98/impl/update_c.hpp>
|
||||
|
||||
namespace boost
|
||||
{
|
||||
namespace metaparse
|
||||
{
|
||||
namespace v1
|
||||
{
|
||||
namespace impl
|
||||
{
|
||||
template <class S>
|
||||
struct pop_back;
|
||||
|
||||
template <class S>
|
||||
struct pop_back :
|
||||
update_c<
|
||||
typename S::type,
|
||||
size<typename S::type>::type::value - 1,
|
||||
BOOST_NO_CHAR
|
||||
>
|
||||
{};
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
#endif
|
||||
|
||||
56
winx64/include/boost/metaparse/v1/cpp98/impl/pop_front.hpp
Normal file
56
winx64/include/boost/metaparse/v1/cpp98/impl/pop_front.hpp
Normal file
@@ -0,0 +1,56 @@
|
||||
#ifndef BOOST_METAPARSE_V1_CPP98_IMPL_POP_FRONT_HPP
|
||||
#define BOOST_METAPARSE_V1_CPP98_IMPL_POP_FRONT_HPP
|
||||
|
||||
// Copyright Abel Sinkovics (abel@sinkovics.hu) 2013.
|
||||
// Distributed under the Boost Software License, Version 1.0.
|
||||
// (See accompanying file LICENSE_1_0.txt or copy at
|
||||
// http://www.boost.org/LICENSE_1_0.txt)
|
||||
|
||||
#include <boost/metaparse/v1/cpp98/fwd/string.hpp>
|
||||
|
||||
#include <boost/preprocessor/repetition/enum_params.hpp>
|
||||
#include <boost/preprocessor/repetition/repeat_from_to.hpp>
|
||||
|
||||
namespace boost
|
||||
{
|
||||
namespace metaparse
|
||||
{
|
||||
namespace v1
|
||||
{
|
||||
namespace impl
|
||||
{
|
||||
template <class S>
|
||||
struct pop_front;
|
||||
|
||||
#ifdef BOOST_METAPARSE_POP_FRONT
|
||||
# error BOOST_METAPARSE_POP_FRONT already defined
|
||||
#endif
|
||||
#define BOOST_METAPARSE_POP_FRONT(z, n, unused) \
|
||||
BOOST_PP_COMMA_IF(BOOST_PP_DEC(n)) BOOST_PP_CAT(C, n)
|
||||
|
||||
template < \
|
||||
BOOST_PP_ENUM_PARAMS(BOOST_METAPARSE_LIMIT_STRING_SIZE, int C) \
|
||||
>
|
||||
struct
|
||||
pop_front<
|
||||
string<BOOST_PP_ENUM_PARAMS(BOOST_METAPARSE_LIMIT_STRING_SIZE, C)>
|
||||
> :
|
||||
string<
|
||||
BOOST_PP_REPEAT_FROM_TO(
|
||||
1,
|
||||
BOOST_METAPARSE_LIMIT_STRING_SIZE,
|
||||
BOOST_METAPARSE_POP_FRONT,
|
||||
~
|
||||
),
|
||||
BOOST_NO_CHAR
|
||||
>
|
||||
{};
|
||||
|
||||
#undef BOOST_METAPARSE_POP_FRONT
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
#endif
|
||||
|
||||
34
winx64/include/boost/metaparse/v1/cpp98/impl/push_back_c.hpp
Normal file
34
winx64/include/boost/metaparse/v1/cpp98/impl/push_back_c.hpp
Normal file
@@ -0,0 +1,34 @@
|
||||
#ifndef BOOST_METAPARSE_V1_CPP98_IMPL_PUSH_BACK_C_HPP
|
||||
#define BOOST_METAPARSE_V1_CPP98_IMPL_PUSH_BACK_C_HPP
|
||||
|
||||
// Copyright Abel Sinkovics (abel@sinkovics.hu) 2013.
|
||||
// Distributed under the Boost Software License, Version 1.0.
|
||||
// (See accompanying file LICENSE_1_0.txt or copy at
|
||||
// http://www.boost.org/LICENSE_1_0.txt)
|
||||
|
||||
#include <boost/metaparse/v1/cpp98/fwd/string.hpp>
|
||||
#include <boost/metaparse/v1/cpp98/impl/update_c.hpp>
|
||||
#include <boost/metaparse/v1/cpp98/impl/size.hpp>
|
||||
|
||||
namespace boost
|
||||
{
|
||||
namespace metaparse
|
||||
{
|
||||
namespace v1
|
||||
{
|
||||
namespace impl
|
||||
{
|
||||
template <class S, char C>
|
||||
struct push_back_c;
|
||||
|
||||
template <class S, char C>
|
||||
struct push_back_c :
|
||||
update_c<typename S::type, size<typename S::type>::type::value, C>
|
||||
{};
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
#endif
|
||||
|
||||
@@ -0,0 +1,47 @@
|
||||
#ifndef BOOST_METAPARSE_V1_CPP98_IMPL_PUSH_FRONT_C_HPP
|
||||
#define BOOST_METAPARSE_V1_CPP98_IMPL_PUSH_FRONT_C_HPP
|
||||
|
||||
// Copyright Abel Sinkovics (abel@sinkovics.hu) 2013.
|
||||
// Distributed under the Boost Software License, Version 1.0.
|
||||
// (See accompanying file LICENSE_1_0.txt or copy at
|
||||
// http://www.boost.org/LICENSE_1_0.txt)
|
||||
|
||||
#include <boost/metaparse/v1/cpp98/fwd/string.hpp>
|
||||
|
||||
#include <boost/preprocessor/arithmetic/dec.hpp>
|
||||
#include <boost/preprocessor/repetition/enum_params.hpp>
|
||||
|
||||
namespace boost
|
||||
{
|
||||
namespace metaparse
|
||||
{
|
||||
namespace v1
|
||||
{
|
||||
namespace impl
|
||||
{
|
||||
template <class S, char C>
|
||||
struct push_front_c;
|
||||
|
||||
template <
|
||||
BOOST_PP_ENUM_PARAMS(BOOST_METAPARSE_LIMIT_STRING_SIZE, int C),
|
||||
char Ch
|
||||
>
|
||||
struct push_front_c<
|
||||
string<BOOST_PP_ENUM_PARAMS(BOOST_METAPARSE_LIMIT_STRING_SIZE, C)>,
|
||||
Ch
|
||||
> :
|
||||
string<
|
||||
Ch,
|
||||
BOOST_PP_ENUM_PARAMS(
|
||||
BOOST_PP_DEC(BOOST_METAPARSE_LIMIT_STRING_SIZE),
|
||||
C
|
||||
)
|
||||
>
|
||||
{};
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
#endif
|
||||
|
||||
63
winx64/include/boost/metaparse/v1/cpp98/impl/size.hpp
Normal file
63
winx64/include/boost/metaparse/v1/cpp98/impl/size.hpp
Normal file
@@ -0,0 +1,63 @@
|
||||
#ifndef BOOST_METAPARSE_V1_CPP98_IMPL_SIZE_HPP
|
||||
#define BOOST_METAPARSE_V1_CPP98_IMPL_SIZE_HPP
|
||||
|
||||
// Copyright Abel Sinkovics (abel@sinkovics.hu) 2013.
|
||||
// Distributed under the Boost Software License, Version 1.0.
|
||||
// (See accompanying file LICENSE_1_0.txt or copy at
|
||||
// http://www.boost.org/LICENSE_1_0.txt)
|
||||
|
||||
#include <boost/metaparse/v1/cpp98/fwd/string.hpp>
|
||||
|
||||
#include <boost/mpl/int.hpp>
|
||||
|
||||
#include <boost/preprocessor/arithmetic/sub.hpp>
|
||||
#include <boost/preprocessor/punctuation/comma_if.hpp>
|
||||
#include <boost/preprocessor/repetition/enum.hpp>
|
||||
#include <boost/preprocessor/repetition/enum_params.hpp>
|
||||
#include <boost/preprocessor/repetition/repeat.hpp>
|
||||
#include <boost/preprocessor/tuple/eat.hpp>
|
||||
|
||||
namespace boost
|
||||
{
|
||||
namespace metaparse
|
||||
{
|
||||
namespace v1
|
||||
{
|
||||
namespace impl
|
||||
{
|
||||
template <class S>
|
||||
struct size;
|
||||
|
||||
#ifdef BOOST_METAPARSE_STRING_CASE
|
||||
# error BOOST_METAPARSE_STRING_CASE
|
||||
#endif
|
||||
#define BOOST_METAPARSE_STRING_CASE(z, n, unused) \
|
||||
template <BOOST_PP_ENUM_PARAMS(n, int C)> \
|
||||
struct \
|
||||
size< \
|
||||
string< \
|
||||
BOOST_PP_ENUM_PARAMS(n, C) BOOST_PP_COMMA_IF(n) \
|
||||
BOOST_PP_ENUM( \
|
||||
BOOST_PP_SUB(BOOST_METAPARSE_LIMIT_STRING_SIZE, n), \
|
||||
BOOST_NO_CHAR BOOST_PP_TUPLE_EAT(3), \
|
||||
~ \
|
||||
) \
|
||||
> \
|
||||
> : \
|
||||
boost::mpl::int_<n> \
|
||||
{};
|
||||
|
||||
BOOST_PP_REPEAT(
|
||||
BOOST_METAPARSE_LIMIT_STRING_SIZE,
|
||||
BOOST_METAPARSE_STRING_CASE,
|
||||
~
|
||||
)
|
||||
|
||||
#undef BOOST_METAPARSE_STRING_CASE
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
#endif
|
||||
|
||||
74
winx64/include/boost/metaparse/v1/cpp98/impl/skip_seq.hpp
Normal file
74
winx64/include/boost/metaparse/v1/cpp98/impl/skip_seq.hpp
Normal file
@@ -0,0 +1,74 @@
|
||||
#ifndef BOOST_METAPARSE_V1_CPP98_IMPL_SKIP_SEQ_HPP
|
||||
#define BOOST_METAPARSE_V1_CPP98_IMPL_SKIP_SEQ_HPP
|
||||
|
||||
// Copyright Abel Sinkovics (abel@sinkovics.hu) 2013.
|
||||
// Distributed under the Boost Software License, Version 1.0.
|
||||
// (See accompanying file LICENSE_1_0.txt or copy at
|
||||
// http://www.boost.org/LICENSE_1_0.txt)
|
||||
|
||||
#include <boost/metaparse/v1/is_error.hpp>
|
||||
#include <boost/metaparse/v1/accept.hpp>
|
||||
#include <boost/metaparse/v1/get_remaining.hpp>
|
||||
#include <boost/metaparse/v1/get_position.hpp>
|
||||
#include <boost/metaparse/v1/get_result.hpp>
|
||||
|
||||
namespace boost
|
||||
{
|
||||
namespace metaparse
|
||||
{
|
||||
namespace v1
|
||||
{
|
||||
namespace impl
|
||||
{
|
||||
struct skip_seq
|
||||
{
|
||||
private:
|
||||
template <class ParsingResult, class NewResultValue>
|
||||
struct change_result :
|
||||
accept<
|
||||
NewResultValue,
|
||||
typename get_remaining<ParsingResult>::type,
|
||||
typename get_position<ParsingResult>::type
|
||||
>
|
||||
{};
|
||||
|
||||
template <class Result, class P>
|
||||
struct apply_unchecked :
|
||||
boost::mpl::eval_if<
|
||||
typename is_error<
|
||||
typename P::template apply<
|
||||
typename get_remaining<Result>::type,
|
||||
typename get_position<Result>::type
|
||||
>
|
||||
>::type,
|
||||
typename P::template apply<
|
||||
typename get_remaining<Result>::type,
|
||||
typename get_position<Result>::type
|
||||
>,
|
||||
change_result<
|
||||
typename P::template apply<
|
||||
typename get_remaining<Result>::type,
|
||||
typename get_position<Result>::type
|
||||
>,
|
||||
typename get_result<Result>::type
|
||||
>
|
||||
>
|
||||
{};
|
||||
|
||||
public:
|
||||
template <class Result, class P>
|
||||
struct apply :
|
||||
boost::mpl::eval_if<
|
||||
is_error<Result>,
|
||||
Result,
|
||||
apply_unchecked<Result, P>
|
||||
>
|
||||
{};
|
||||
};
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
#endif
|
||||
|
||||
74
winx64/include/boost/metaparse/v1/cpp98/impl/update_c.hpp
Normal file
74
winx64/include/boost/metaparse/v1/cpp98/impl/update_c.hpp
Normal file
@@ -0,0 +1,74 @@
|
||||
#ifndef BOOST_METAPARSE_V1_CPP98_IMPL_UPDATE_C_HPP
|
||||
#define BOOST_METAPARSE_V1_CPP98_IMPL_UPDATE_C_HPP
|
||||
|
||||
// Copyright Abel Sinkovics (abel@sinkovics.hu) 2013.
|
||||
// Distributed under the Boost Software License, Version 1.0.
|
||||
// (See accompanying file LICENSE_1_0.txt or copy at
|
||||
// http://www.boost.org/LICENSE_1_0.txt)
|
||||
|
||||
#include <boost/metaparse/v1/cpp98/fwd/string.hpp>
|
||||
|
||||
#include <boost/preprocessor/arithmetic/dec.hpp>
|
||||
#include <boost/preprocessor/arithmetic/inc.hpp>
|
||||
#include <boost/preprocessor/cat.hpp>
|
||||
#include <boost/preprocessor/punctuation/comma_if.hpp>
|
||||
#include <boost/preprocessor/repetition/enum_params.hpp>
|
||||
#include <boost/preprocessor/repetition/repeat.hpp>
|
||||
#include <boost/preprocessor/repetition/repeat_from_to.hpp>
|
||||
|
||||
namespace boost
|
||||
{
|
||||
namespace metaparse
|
||||
{
|
||||
namespace v1
|
||||
{
|
||||
namespace impl
|
||||
{
|
||||
template <class S, int N, int C>
|
||||
struct update_c;
|
||||
|
||||
#ifdef BOOST_METAPARSE_ARGN
|
||||
# error BOOST_METAPARSE_ARGN already defined
|
||||
#endif
|
||||
#define BOOST_METAPARSE_ARGN(z, n, unused) , BOOST_PP_CAT(C, n)
|
||||
|
||||
#ifdef BOOST_METAPARSE_UPDATE
|
||||
# error BOOST_METAPARSE_UPDATE already defined
|
||||
#endif
|
||||
#define BOOST_METAPARSE_UPDATE(z, n, unused) \
|
||||
template < \
|
||||
BOOST_PP_ENUM_PARAMS(BOOST_METAPARSE_LIMIT_STRING_SIZE, int C), \
|
||||
int Ch \
|
||||
> \
|
||||
struct update_c< \
|
||||
string<BOOST_PP_ENUM_PARAMS(BOOST_METAPARSE_LIMIT_STRING_SIZE, C)>,\
|
||||
n, \
|
||||
Ch \
|
||||
> : \
|
||||
string< \
|
||||
BOOST_PP_ENUM_PARAMS(n, C) BOOST_PP_COMMA_IF(n) \
|
||||
Ch \
|
||||
BOOST_PP_REPEAT_FROM_TO( \
|
||||
BOOST_PP_INC(n), \
|
||||
BOOST_PP_DEC(BOOST_METAPARSE_LIMIT_STRING_SIZE), \
|
||||
BOOST_METAPARSE_ARGN, \
|
||||
~ \
|
||||
) \
|
||||
> \
|
||||
{};
|
||||
|
||||
BOOST_PP_REPEAT(
|
||||
BOOST_METAPARSE_LIMIT_STRING_SIZE,
|
||||
BOOST_METAPARSE_UPDATE,
|
||||
~
|
||||
)
|
||||
|
||||
#undef BOOST_METAPARSE_UPDATE
|
||||
#undef BOOST_METAPARSE_ARGN
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
#endif
|
||||
|
||||
Reference in New Issue
Block a user