add boost on mac
This commit is contained in:
63
macx64/include/boost/metaparse/v1/impl/apply_parser.hpp
Normal file
63
macx64/include/boost/metaparse/v1/impl/apply_parser.hpp
Normal file
@@ -0,0 +1,63 @@
|
||||
#ifndef BOOST_METAPARSE_V1_IMPL_APPLY_PARSER_HPP
|
||||
#define BOOST_METAPARSE_V1_IMPL_APPLY_PARSER_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/unless_error.hpp>
|
||||
#include <boost/metaparse/v1/get_result.hpp>
|
||||
#include <boost/metaparse/v1/get_remaining.hpp>
|
||||
#include <boost/metaparse/v1/get_position.hpp>
|
||||
#include <boost/metaparse/v1/transform.hpp>
|
||||
|
||||
#include <boost/mpl/push_back.hpp>
|
||||
|
||||
namespace boost
|
||||
{
|
||||
namespace metaparse
|
||||
{
|
||||
namespace v1
|
||||
{
|
||||
namespace impl
|
||||
{
|
||||
struct apply_parser
|
||||
{
|
||||
private:
|
||||
template <class ListToAppend>
|
||||
struct do_append
|
||||
{
|
||||
template <class Item>
|
||||
struct apply : boost::mpl::push_back<ListToAppend, Item> {};
|
||||
};
|
||||
|
||||
template <class Accum, class S, class Pos, class Parser>
|
||||
struct apply_unchecked :
|
||||
transform<Parser,do_append<typename Accum::type> >::template apply<
|
||||
typename S::type,
|
||||
typename Pos::type
|
||||
>
|
||||
{};
|
||||
|
||||
public:
|
||||
template <class State, class Parser>
|
||||
struct apply :
|
||||
unless_error<
|
||||
State,
|
||||
apply_unchecked<
|
||||
get_result<State>,
|
||||
get_remaining<State>,
|
||||
get_position<State>,
|
||||
Parser
|
||||
>
|
||||
>
|
||||
{};
|
||||
};
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
#endif
|
||||
|
||||
@@ -0,0 +1,31 @@
|
||||
#ifndef BOOST_METAPARSE_V1_IMPL_ASSERT_STRING_LENGTH_HPP
|
||||
#define BOOST_METAPARSE_V1_IMPL_ASSERT_STRING_LENGTH_HPP
|
||||
|
||||
// Copyright Abel Sinkovics (abel@sinkovics.hu) 2014.
|
||||
// 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/static_assert.hpp>
|
||||
|
||||
namespace boost
|
||||
{
|
||||
namespace metaparse
|
||||
{
|
||||
namespace v1
|
||||
{
|
||||
namespace impl
|
||||
{
|
||||
template <int Len, class S>
|
||||
struct assert_string_length : S
|
||||
{
|
||||
BOOST_STATIC_ASSERT((Len <= BOOST_METAPARSE_LIMIT_STRING_SIZE));
|
||||
};
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
#endif
|
||||
|
||||
|
||||
18
macx64/include/boost/metaparse/v1/impl/at_c.hpp
Normal file
18
macx64/include/boost/metaparse/v1/impl/at_c.hpp
Normal file
@@ -0,0 +1,18 @@
|
||||
#ifndef BOOST_METAPARSE_V1_IMPL_AT_C_HPP
|
||||
#define BOOST_METAPARSE_V1_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>
|
||||
|
||||
#if BOOST_METAPARSE_STD >= 2011
|
||||
# include <boost/metaparse/v1/cpp11/impl/at_c.hpp>
|
||||
#else
|
||||
# include <boost/metaparse/v1/cpp98/impl/at_c.hpp>
|
||||
#endif
|
||||
|
||||
#endif
|
||||
|
||||
32
macx64/include/boost/metaparse/v1/impl/back_inserter.hpp
Normal file
32
macx64/include/boost/metaparse/v1/impl/back_inserter.hpp
Normal file
@@ -0,0 +1,32 @@
|
||||
#ifndef BOOST_METAPARSE_V1_IMPL_BACK_INSERTER_HPP
|
||||
#define BOOST_METAPARSE_V1_IMPL_BACK_INSERTER_HPP
|
||||
|
||||
// Copyright Abel Sinkovics (abel@sinkovics.hu) 2015.
|
||||
// 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/mpl/push_back.hpp>
|
||||
|
||||
namespace boost
|
||||
{
|
||||
namespace metaparse
|
||||
{
|
||||
namespace v1
|
||||
{
|
||||
namespace impl
|
||||
{
|
||||
struct back_inserter
|
||||
{
|
||||
typedef back_inserter type;
|
||||
|
||||
template <class T0, class T1>
|
||||
struct apply : boost::mpl::push_back<T0, T1> {};
|
||||
};
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
#endif
|
||||
|
||||
32
macx64/include/boost/metaparse/v1/impl/front_inserter.hpp
Normal file
32
macx64/include/boost/metaparse/v1/impl/front_inserter.hpp
Normal file
@@ -0,0 +1,32 @@
|
||||
#ifndef BOOST_METAPARSE_V1_IMPL_FRONT_INSERTER_HPP
|
||||
#define BOOST_METAPARSE_V1_IMPL_FRONT_INSERTER_HPP
|
||||
|
||||
// Copyright Abel Sinkovics (abel@sinkovics.hu) 2015.
|
||||
// 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/mpl/push_front.hpp>
|
||||
|
||||
namespace boost
|
||||
{
|
||||
namespace metaparse
|
||||
{
|
||||
namespace v1
|
||||
{
|
||||
namespace impl
|
||||
{
|
||||
struct front_inserter
|
||||
{
|
||||
typedef front_inserter type;
|
||||
|
||||
template <class T0, class T1>
|
||||
struct apply : boost::mpl::push_front<T0, T1> {};
|
||||
};
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
#endif
|
||||
|
||||
34
macx64/include/boost/metaparse/v1/impl/fwd/iterate_impl.hpp
Normal file
34
macx64/include/boost/metaparse/v1/impl/fwd/iterate_impl.hpp
Normal file
@@ -0,0 +1,34 @@
|
||||
#ifndef BOOST_METAPARSE_V1_IMPL_FWD_ITERATE_IMPL_HPP
|
||||
#define BOOST_METAPARSE_V1_IMPL_FWD_ITERATE_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/is_error.hpp>
|
||||
#include <boost/metaparse/v1/get_result.hpp>
|
||||
#include <boost/metaparse/v1/get_remaining.hpp>
|
||||
#include <boost/metaparse/v1/get_position.hpp>
|
||||
|
||||
#include <boost/mpl/deque.hpp>
|
||||
#include <boost/mpl/eval_if.hpp>
|
||||
#include <boost/mpl/push_back.hpp>
|
||||
|
||||
namespace boost
|
||||
{
|
||||
namespace metaparse
|
||||
{
|
||||
namespace v1
|
||||
{
|
||||
namespace impl
|
||||
{
|
||||
template <int N, class P, class Accum>
|
||||
struct iterate_impl;
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
#endif
|
||||
|
||||
26
macx64/include/boost/metaparse/v1/impl/has_type.hpp
Normal file
26
macx64/include/boost/metaparse/v1/impl/has_type.hpp
Normal file
@@ -0,0 +1,26 @@
|
||||
#ifndef BOOST_METAPARSE_V1_IMPL_HAS_TYPE_HPP
|
||||
#define BOOST_METAPARSE_V1_IMPL_HAS_TYPE_HPP
|
||||
|
||||
// Copyright Abel Sinkovics (abel@sinkovics.hu) 2014.
|
||||
// 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/mpl/has_xxx.hpp>
|
||||
|
||||
namespace boost
|
||||
{
|
||||
namespace metaparse
|
||||
{
|
||||
namespace v1
|
||||
{
|
||||
namespace impl
|
||||
{
|
||||
BOOST_MPL_HAS_XXX_TRAIT_DEF(type)
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
#endif
|
||||
|
||||
70
macx64/include/boost/metaparse/v1/impl/is_any.hpp
Normal file
70
macx64/include/boost/metaparse/v1/impl/is_any.hpp
Normal file
@@ -0,0 +1,70 @@
|
||||
#ifndef BOOST_METAPARSE_V1_IMPL_IS_ANY_HPP
|
||||
#define BOOST_METAPARSE_V1_IMPL_IS_ANY_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/limit_one_char_except_size.hpp>
|
||||
|
||||
#include <boost/mpl/eval_if.hpp>
|
||||
#include <boost/mpl/bool.hpp>
|
||||
|
||||
#include <boost/preprocessor/cat.hpp>
|
||||
#include <boost/preprocessor/arithmetic/dec.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 Stub = int>
|
||||
struct is_any0
|
||||
{
|
||||
template <class C>
|
||||
struct apply : boost::mpl::true_ {};
|
||||
};
|
||||
|
||||
#ifdef BOOST_METAPARSE_DEFINE_IS_ANY
|
||||
# error BOOST_METAPARSE_DEFINE_IS_ANY already defined
|
||||
#endif
|
||||
#define BOOST_METAPARSE_DEFINE_IS_ANY(z, n, unused) \
|
||||
template <BOOST_PP_ENUM_PARAMS(n, class T)> \
|
||||
struct BOOST_PP_CAT(is_any, n) \
|
||||
{ \
|
||||
template <class C> \
|
||||
struct apply : \
|
||||
boost::mpl::eval_if< \
|
||||
boost::mpl::bool_< \
|
||||
C::type::value \
|
||||
== BOOST_PP_CAT(T, BOOST_PP_DEC(n))::type::value \
|
||||
>, \
|
||||
boost::mpl::false_, \
|
||||
typename BOOST_PP_CAT(is_any, BOOST_PP_DEC(n))< \
|
||||
BOOST_PP_ENUM_PARAMS(BOOST_PP_DEC(n), T) \
|
||||
>::template apply<C> \
|
||||
> \
|
||||
{}; \
|
||||
};
|
||||
|
||||
BOOST_PP_REPEAT_FROM_TO(
|
||||
1,
|
||||
BOOST_METAPARSE_LIMIT_ONE_CHAR_EXCEPT_SIZE,
|
||||
BOOST_METAPARSE_DEFINE_IS_ANY,
|
||||
~
|
||||
)
|
||||
|
||||
#undef BOOST_METAPARSE_DEFINE_IS_ANY
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
#endif
|
||||
|
||||
33
macx64/include/boost/metaparse/v1/impl/is_char_c.hpp
Normal file
33
macx64/include/boost/metaparse/v1/impl/is_char_c.hpp
Normal file
@@ -0,0 +1,33 @@
|
||||
#ifndef BOOST_METAPARSE_V1_IMPL_IS_CHAR_C_HPP
|
||||
#define BOOST_METAPARSE_V1_IMPL_IS_CHAR_C_HPP
|
||||
|
||||
// Copyright Abel Sinkovics (abel@sinkovics.hu) 2015.
|
||||
// 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/mpl/bool.hpp>
|
||||
|
||||
namespace boost
|
||||
{
|
||||
namespace metaparse
|
||||
{
|
||||
namespace v1
|
||||
{
|
||||
namespace impl
|
||||
{
|
||||
template <char C>
|
||||
struct is_char_c
|
||||
{
|
||||
typedef is_char_c type;
|
||||
|
||||
template <class Ch>
|
||||
struct apply : boost::mpl::bool_<Ch::type::value == C> {};
|
||||
};
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
#endif
|
||||
|
||||
46
macx64/include/boost/metaparse/v1/impl/iterate_impl.hpp
Normal file
46
macx64/include/boost/metaparse/v1/impl/iterate_impl.hpp
Normal file
@@ -0,0 +1,46 @@
|
||||
#ifndef BOOST_METAPARSE_V1_IMPL_ITERATE_IMPL_HPP
|
||||
#define BOOST_METAPARSE_V1_IMPL_ITERATE_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/impl/iterate_impl_unchecked.hpp>
|
||||
#include <boost/metaparse/v1/return_.hpp>
|
||||
#include <boost/metaparse/v1/is_error.hpp>
|
||||
|
||||
#include <boost/mpl/eval_if.hpp>
|
||||
|
||||
namespace boost
|
||||
{
|
||||
namespace metaparse
|
||||
{
|
||||
namespace v1
|
||||
{
|
||||
namespace impl
|
||||
{
|
||||
template <int N, class P, class Accum>
|
||||
struct iterate_impl
|
||||
{
|
||||
typedef iterate_impl type;
|
||||
|
||||
template <class S, class Pos>
|
||||
struct apply :
|
||||
boost::mpl::eval_if<
|
||||
typename is_error<typename P::template apply<S, Pos> >::type,
|
||||
typename P::template apply<S, Pos>,
|
||||
iterate_impl_unchecked<N, P, Accum, S, Pos>
|
||||
>
|
||||
{};
|
||||
};
|
||||
|
||||
template <class P, class Accum>
|
||||
struct iterate_impl<0, P, Accum> : return_<Accum> {};
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
#endif
|
||||
|
||||
@@ -0,0 +1,44 @@
|
||||
#ifndef BOOST_METAPARSE_V1_IMPL_ITERATE_IMPL_UNCHECKED_HPP
|
||||
#define BOOST_METAPARSE_V1_IMPL_ITERATE_IMPL_UNCHECKED_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/impl/fwd/iterate_impl.hpp>
|
||||
#include <boost/metaparse/v1/get_result.hpp>
|
||||
#include <boost/metaparse/v1/get_remaining.hpp>
|
||||
#include <boost/metaparse/v1/get_position.hpp>
|
||||
|
||||
#include <boost/mpl/push_back.hpp>
|
||||
|
||||
namespace boost
|
||||
{
|
||||
namespace metaparse
|
||||
{
|
||||
namespace v1
|
||||
{
|
||||
namespace impl
|
||||
{
|
||||
template <int N, class P, class Accum, class S, class Pos>
|
||||
struct iterate_impl_unchecked :
|
||||
iterate_impl<
|
||||
N - 1,
|
||||
P,
|
||||
typename boost::mpl::push_back<
|
||||
Accum,
|
||||
typename get_result<typename P::template apply<S, Pos> >::type
|
||||
>::type
|
||||
>::template apply<
|
||||
typename get_remaining<typename P::template apply<S, Pos> >::type,
|
||||
typename get_position<typename P::template apply<S, Pos> >::type
|
||||
>
|
||||
{};
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
#endif
|
||||
|
||||
39
macx64/include/boost/metaparse/v1/impl/later_result.hpp
Normal file
39
macx64/include/boost/metaparse/v1/impl/later_result.hpp
Normal file
@@ -0,0 +1,39 @@
|
||||
#ifndef BOOST_METAPARSE_V1_IMPL_LATER_RESULT_HPP
|
||||
#define BOOST_METAPARSE_V1_IMPL_LATER_RESULT_HPP
|
||||
|
||||
// Copyright Abel Sinkovics (abel@sinkovics.hu) 2015.
|
||||
// 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/get_position.hpp>
|
||||
|
||||
#include <boost/mpl/if.hpp>
|
||||
#include <boost/mpl/less.hpp>
|
||||
|
||||
namespace boost
|
||||
{
|
||||
namespace metaparse
|
||||
{
|
||||
namespace v1
|
||||
{
|
||||
namespace impl
|
||||
{
|
||||
template <class R1, class R2>
|
||||
struct later_result :
|
||||
boost::mpl::if_<
|
||||
typename boost::mpl::less<
|
||||
typename get_position<R2>::type,
|
||||
typename get_position<R1>::type
|
||||
>::type,
|
||||
R1,
|
||||
R2
|
||||
>
|
||||
{};
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
#endif
|
||||
|
||||
36
macx64/include/boost/metaparse/v1/impl/next_digit.hpp
Normal file
36
macx64/include/boost/metaparse/v1/impl/next_digit.hpp
Normal file
@@ -0,0 +1,36 @@
|
||||
#ifndef BOOST_METAPARSE_V1_IMPL_NEXT_DIGIT_HPP
|
||||
#define BOOST_METAPARSE_V1_IMPL_NEXT_DIGIT_HPP
|
||||
|
||||
// Copyright Abel Sinkovics (abel@sinkovics.hu) 2015.
|
||||
// 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/mpl/int.hpp>
|
||||
|
||||
namespace boost
|
||||
{
|
||||
namespace metaparse
|
||||
{
|
||||
namespace v1
|
||||
{
|
||||
namespace impl
|
||||
{
|
||||
struct next_digit
|
||||
{
|
||||
typedef next_digit type;
|
||||
|
||||
template <class PartialResult, class NextDigit>
|
||||
struct apply :
|
||||
boost::mpl::int_<
|
||||
PartialResult::type::value * 10 + NextDigit::type::value
|
||||
>
|
||||
{};
|
||||
};
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
#endif
|
||||
|
||||
17
macx64/include/boost/metaparse/v1/impl/no_char.hpp
Normal file
17
macx64/include/boost/metaparse/v1/impl/no_char.hpp
Normal file
@@ -0,0 +1,17 @@
|
||||
#ifndef BOOST_METAPARSE_V1_IMPL_NO_CHAR_HPP
|
||||
#define BOOST_METAPARSE_V1_IMPL_NO_CHAR_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 <cstdio>
|
||||
|
||||
#ifdef BOOST_NO_CHAR
|
||||
# error BOOST_NO_CHAR already defined
|
||||
#endif
|
||||
#define BOOST_NO_CHAR EOF
|
||||
|
||||
#endif
|
||||
|
||||
@@ -0,0 +1,24 @@
|
||||
#ifndef BOOST_METAPARSE_V1_IMPL_ONE_CHAR_EXCEPT_NOT_USED_HPP
|
||||
#define BOOST_METAPARSE_V1_IMPL_ONE_CHAR_EXCEPT_NOT_USED_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
|
||||
{
|
||||
struct one_char_except_not_used {};
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
#endif
|
||||
|
||||
44
macx64/include/boost/metaparse/v1/impl/one_of.hpp
Normal file
44
macx64/include/boost/metaparse/v1/impl/one_of.hpp
Normal file
@@ -0,0 +1,44 @@
|
||||
#ifndef BOOST_METAPARSE_V1_IMPL_ONE_OF_HPP
|
||||
#define BOOST_METAPARSE_V1_IMPL_ONE_OF_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/error/none_of_the_expected_cases_found.hpp>
|
||||
#include <boost/metaparse/v1/fail.hpp>
|
||||
|
||||
#include <boost/metaparse/v1/impl/one_of_fwd_op.hpp>
|
||||
|
||||
#include <boost/mpl/fold.hpp>
|
||||
|
||||
namespace boost
|
||||
{
|
||||
namespace metaparse
|
||||
{
|
||||
namespace v1
|
||||
{
|
||||
namespace impl
|
||||
{
|
||||
template <class Parsers>
|
||||
struct one_of
|
||||
{
|
||||
typedef one_of type;
|
||||
|
||||
template <class S, class Pos>
|
||||
struct apply :
|
||||
boost::mpl::fold<
|
||||
Parsers,
|
||||
fail<error::none_of_the_expected_cases_found>::apply<S, Pos>,
|
||||
one_of_fwd_op<S, Pos>
|
||||
>::type
|
||||
{};
|
||||
};
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
#endif
|
||||
|
||||
46
macx64/include/boost/metaparse/v1/impl/one_of_fwd_op.hpp
Normal file
46
macx64/include/boost/metaparse/v1/impl/one_of_fwd_op.hpp
Normal file
@@ -0,0 +1,46 @@
|
||||
#ifndef BOOST_METAPARSE_V1_IMPL_ONE_OF_FWD_OP_HPP
|
||||
#define BOOST_METAPARSE_V1_IMPL_ONE_OF_FWD_OP_HPP
|
||||
|
||||
// Copyright Abel Sinkovics (abel@sinkovics.hu) 2015.
|
||||
// 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/impl/later_result.hpp>
|
||||
|
||||
#include <boost/mpl/eval_if.hpp>
|
||||
|
||||
namespace boost
|
||||
{
|
||||
namespace metaparse
|
||||
{
|
||||
namespace v1
|
||||
{
|
||||
namespace impl
|
||||
{
|
||||
template <class S, class Pos>
|
||||
struct one_of_fwd_op
|
||||
{
|
||||
typedef one_of_fwd_op type;
|
||||
|
||||
template <class State, class P>
|
||||
struct apply :
|
||||
boost::mpl::eval_if<
|
||||
typename is_error<State>::type,
|
||||
boost::mpl::eval_if<
|
||||
typename is_error<typename P::template apply<S, Pos> >::type,
|
||||
later_result<State, typename P::template apply<S, Pos> >,
|
||||
typename P::template apply<S, Pos>
|
||||
>,
|
||||
State
|
||||
>
|
||||
{};
|
||||
};
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
#endif
|
||||
|
||||
28
macx64/include/boost/metaparse/v1/impl/returns.hpp
Normal file
28
macx64/include/boost/metaparse/v1/impl/returns.hpp
Normal file
@@ -0,0 +1,28 @@
|
||||
#ifndef BOOST_METAPARSE_V1_IMPL_RETURNS_HPP
|
||||
#define BOOST_METAPARSE_V1_IMPL_RETURNS_HPP
|
||||
|
||||
// Copyright Abel Sinkovics (abel@sinkovics.hu) 2014.
|
||||
// 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 T>
|
||||
struct returns
|
||||
{
|
||||
typedef T type;
|
||||
};
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
#endif
|
||||
|
||||
59
macx64/include/boost/metaparse/v1/impl/sequence.hpp
Normal file
59
macx64/include/boost/metaparse/v1/impl/sequence.hpp
Normal file
@@ -0,0 +1,59 @@
|
||||
#ifndef BOOST_METAPARSE_V1_IMPL_SEQUENCE_HPP
|
||||
#define BOOST_METAPARSE_V1_IMPL_SEQUENCE_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/impl/sequence_impl.hpp>
|
||||
#include <boost/metaparse/limit_sequence_size.hpp>
|
||||
|
||||
#include <boost/mpl/vector.hpp>
|
||||
|
||||
#include <boost/preprocessor/repetition/repeat_from_to.hpp>
|
||||
#include <boost/preprocessor/repetition/enum_params.hpp>
|
||||
#include <boost/preprocessor/cat.hpp>
|
||||
|
||||
namespace boost
|
||||
{
|
||||
namespace metaparse
|
||||
{
|
||||
namespace v1
|
||||
{
|
||||
namespace impl
|
||||
{
|
||||
#ifdef BOOST_METAPARSE_SEQUENCE_CASE
|
||||
# error BOOST_METAPARSE_SEQUENCE_CASE already defined
|
||||
#endif
|
||||
#define BOOST_METAPARSE_SEQUENCE_CASE(z, n, unused) \
|
||||
template <BOOST_PP_ENUM_PARAMS(n, class P)> \
|
||||
struct BOOST_PP_CAT(sequence, n) \
|
||||
{ \
|
||||
typedef BOOST_PP_CAT(sequence, n) type; \
|
||||
\
|
||||
template <class S, class Pos> \
|
||||
struct apply : \
|
||||
sequence_impl< \
|
||||
boost::mpl::vector<BOOST_PP_ENUM_PARAMS(n, P)>, \
|
||||
S, \
|
||||
Pos \
|
||||
> \
|
||||
{}; \
|
||||
};
|
||||
|
||||
BOOST_PP_REPEAT_FROM_TO(
|
||||
1,
|
||||
BOOST_METAPARSE_LIMIT_SEQUENCE_SIZE,
|
||||
BOOST_METAPARSE_SEQUENCE_CASE,
|
||||
~
|
||||
)
|
||||
|
||||
#undef BOOST_METAPARSE_SEQUENCE_CASE
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
#endif
|
||||
|
||||
37
macx64/include/boost/metaparse/v1/impl/sequence_impl.hpp
Normal file
37
macx64/include/boost/metaparse/v1/impl/sequence_impl.hpp
Normal file
@@ -0,0 +1,37 @@
|
||||
#ifndef BOOST_METAPARSE_V1_IMPL_SEQUENCE_IMPL_HPP
|
||||
#define BOOST_METAPARSE_V1_IMPL_SEQUENCE_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/impl/apply_parser.hpp>
|
||||
#include <boost/metaparse/v1/accept.hpp>
|
||||
|
||||
#include <boost/mpl/deque.hpp>
|
||||
#include <boost/mpl/fold.hpp>
|
||||
|
||||
namespace boost
|
||||
{
|
||||
namespace metaparse
|
||||
{
|
||||
namespace v1
|
||||
{
|
||||
namespace impl
|
||||
{
|
||||
template <class Ps, class S, class Pos>
|
||||
struct sequence_impl :
|
||||
boost::mpl::fold<
|
||||
Ps,
|
||||
accept<boost::mpl::deque<>, S, Pos>,
|
||||
apply_parser
|
||||
>
|
||||
{};
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
#endif
|
||||
|
||||
159
macx64/include/boost/metaparse/v1/impl/string_iterator.hpp
Normal file
159
macx64/include/boost/metaparse/v1/impl/string_iterator.hpp
Normal file
@@ -0,0 +1,159 @@
|
||||
#ifndef BOOST_METAPARSE_V1_IMPL_STRING_ITERATOR_HPP
|
||||
#define BOOST_METAPARSE_V1_IMPL_STRING_ITERATOR_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/impl/string_iterator_tag.hpp>
|
||||
#include <boost/metaparse/v1/impl/at_c.hpp>
|
||||
|
||||
|
||||
#include <boost/mpl/iterator_tags.hpp>
|
||||
#include <boost/mpl/int.hpp>
|
||||
#include <boost/mpl/bool.hpp>
|
||||
|
||||
#include <boost/type_traits/is_same.hpp>
|
||||
|
||||
namespace boost
|
||||
{
|
||||
namespace metaparse
|
||||
{
|
||||
namespace v1
|
||||
{
|
||||
namespace impl
|
||||
{
|
||||
// string_iterator
|
||||
template <class S, int N>
|
||||
struct string_iterator
|
||||
{
|
||||
typedef string_iterator type;
|
||||
typedef string_iterator_tag tag;
|
||||
typedef boost::mpl::random_access_iterator_tag category;
|
||||
};
|
||||
|
||||
// advance_c
|
||||
|
||||
template <class S, int N>
|
||||
struct advance_c;
|
||||
|
||||
template <class S, int N, int P>
|
||||
struct advance_c<string_iterator<S, N>, P> :
|
||||
string_iterator<S, N + P>
|
||||
{};
|
||||
|
||||
// distance
|
||||
|
||||
template <class A, class B>
|
||||
struct distance;
|
||||
|
||||
template <class S, int A, int B>
|
||||
struct distance<string_iterator<S, A>, string_iterator<S, B> > :
|
||||
boost::mpl::int_<B - A>
|
||||
{};
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
namespace boost
|
||||
{
|
||||
namespace mpl
|
||||
{
|
||||
// advance
|
||||
template <class S>
|
||||
struct advance_impl;
|
||||
|
||||
template <>
|
||||
struct advance_impl<boost::metaparse::v1::impl::string_iterator_tag>
|
||||
{
|
||||
typedef advance_impl type;
|
||||
|
||||
template <class S, class N>
|
||||
struct apply :
|
||||
boost::metaparse::v1::impl::advance_c<
|
||||
typename S::type, N::type::value
|
||||
>
|
||||
{};
|
||||
};
|
||||
|
||||
// distance
|
||||
template <class S>
|
||||
struct distance_impl;
|
||||
|
||||
template <>
|
||||
struct distance_impl<boost::metaparse::v1::impl::string_iterator_tag>
|
||||
{
|
||||
typedef distance_impl type;
|
||||
|
||||
template <class A, class B>
|
||||
struct apply :
|
||||
boost::metaparse::v1::impl::distance<
|
||||
typename A::type,
|
||||
typename B::type
|
||||
>
|
||||
{};
|
||||
};
|
||||
|
||||
// next
|
||||
template <class S>
|
||||
struct next;
|
||||
|
||||
template <class S, int N>
|
||||
struct next<boost::metaparse::v1::impl::string_iterator<S, N> > :
|
||||
boost::metaparse::v1::impl::string_iterator<S, N + 1>
|
||||
{};
|
||||
|
||||
// prior
|
||||
template <class S>
|
||||
struct prior;
|
||||
|
||||
template <class S, int N>
|
||||
struct prior<boost::metaparse::v1::impl::string_iterator<S, N> > :
|
||||
boost::metaparse::v1::impl::string_iterator<S, N - 1>
|
||||
{};
|
||||
|
||||
// deref
|
||||
template <class S>
|
||||
struct deref;
|
||||
|
||||
template <class S, int N>
|
||||
struct deref<boost::metaparse::v1::impl::string_iterator<S, N> > :
|
||||
boost::metaparse::v1::impl::at_c<S, N>
|
||||
{};
|
||||
|
||||
// equal_to
|
||||
template <class A, class B>
|
||||
struct equal_to_impl;
|
||||
|
||||
template <>
|
||||
struct equal_to_impl<
|
||||
boost::metaparse::v1::impl::string_iterator_tag,
|
||||
boost::metaparse::v1::impl::string_iterator_tag
|
||||
>
|
||||
{
|
||||
typedef equal_to_impl type;
|
||||
|
||||
template <class A, class B>
|
||||
struct apply : is_same<typename A::type, typename B::type> {};
|
||||
};
|
||||
|
||||
template <class T>
|
||||
struct equal_to_impl<boost::metaparse::v1::impl::string_iterator_tag, T>
|
||||
{
|
||||
typedef equal_to_impl type;
|
||||
|
||||
template <class, class>
|
||||
struct apply : false_ {};
|
||||
};
|
||||
|
||||
template <class T>
|
||||
struct equal_to_impl<T, boost::metaparse::v1::impl::string_iterator_tag> :
|
||||
equal_to_impl<boost::metaparse::v1::impl::string_iterator_tag, T>
|
||||
{};
|
||||
}
|
||||
}
|
||||
|
||||
#endif
|
||||
|
||||
@@ -0,0 +1,27 @@
|
||||
#ifndef BOOST_METAPARSE_V1_IMPL_STRING_ITERATOR_TAG_HPP
|
||||
#define BOOST_METAPARSE_V1_IMPL_STRING_ITERATOR_TAG_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
|
||||
{
|
||||
struct string_iterator_tag
|
||||
{
|
||||
typedef string_iterator_tag type;
|
||||
};
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
#endif
|
||||
|
||||
25
macx64/include/boost/metaparse/v1/impl/void_.hpp
Normal file
25
macx64/include/boost/metaparse/v1/impl/void_.hpp
Normal file
@@ -0,0 +1,25 @@
|
||||
#ifndef BOOST_METAPARSE_V1_IMPL_VOID_HPP
|
||||
#define BOOST_METAPARSE_V1_IMPL_VOID_HPP
|
||||
|
||||
// Copyright Abel Sinkovics (abel@sinkovics.hu) 2015.
|
||||
// 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
|
||||
{
|
||||
struct void_ { typedef void_ type; };
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
#endif
|
||||
|
||||
Reference in New Issue
Block a user