Files
cpp-thirdparty/winx64/include/boost/metaparse/v1/impl/push_front_c.hpp
Bassem Girgis 81b4b9e273 Initial commit
2018-12-20 17:34:07 -06:00

54 lines
1.3 KiB
C++

#ifndef BOOST_METAPARSE_V1_IMPL_PUSH_FRONT_C_HPP
#define BOOST_METAPARSE_V1_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/config.hpp>
#include <boost/metaparse/v1/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;
#ifdef BOOST_METAPARSE_VARIADIC_STRING
template <char... Cs, char C>
struct push_front_c<string<Cs...>, C> : string<C, Cs...> {};
#else
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
}
}
}
}
#endif