File indexing completed on 2025-01-30 10:01:22
0001
0002
0003
0004
0005
0006
0007
0008
0009
0010
0011 #ifndef BOOST_TYPE_ERASURE_MACRO_HPP_INCLUDED
0012 #define BOOST_TYPE_ERASURE_MACRO_HPP_INCLUDED
0013
0014 #include <boost/preprocessor/dec.hpp>
0015 #include <boost/preprocessor/if.hpp>
0016 #include <boost/preprocessor/comparison/not_equal.hpp>
0017 #include <boost/preprocessor/repetition/repeat.hpp>
0018 #include <boost/preprocessor/seq/for_each.hpp>
0019 #include <boost/preprocessor/seq/pop_back.hpp>
0020 #include <boost/preprocessor/seq/size.hpp>
0021 #include <boost/preprocessor/tuple/eat.hpp>
0022
0023
0024 #define BOOST_TYPE_ERASURE_OPEN_NAMESPACE_F(z, data, x) \
0025 namespace x {
0026
0027
0028 #define BOOST_TYPE_ERASURE_OPEN_NAMEPACE_I(seq)\
0029 BOOST_PP_SEQ_FOR_EACH(BOOST_TYPE_ERASURE_OPEN_NAMESPACE_F, ~, BOOST_PP_SEQ_POP_BACK(seq))
0030
0031
0032 #define BOOST_TYPE_ERASURE_OPEN_NAMESPACE(seq)\
0033 BOOST_PP_IF(BOOST_PP_NOT_EQUAL(BOOST_PP_SEQ_SIZE(seq), 1), BOOST_TYPE_ERASURE_OPEN_NAMEPACE_I, BOOST_PP_TUPLE_EAT(1))(seq)
0034
0035
0036 #define BOOST_TYPE_ERASURE_CLOSE_NAMESPACE(seq) \
0037 BOOST_PP_REPEAT(BOOST_PP_DEC(BOOST_PP_SEQ_SIZE(seq)), } BOOST_PP_TUPLE_EAT(3), ~)
0038
0039
0040 #define BOOST_TYPE_ERASURE_QUALIFIED_NAME_F(z, data, x)\
0041 ::x
0042
0043
0044 #define BOOST_TYPE_ERASURE_QUALIFIED_NAME(seq) \
0045 BOOST_PP_SEQ_FOR_EACH(BOOST_TYPE_ERASURE_QUALIFIED_NAME_F, ~, seq)
0046
0047 #endif