MessagePack for C++
for_each.hpp
Go to the documentation of this file.
1 # /* Copyright (C) 2001
2 # * Housemarque Oy
3 # * http://www.housemarque.com
4 # *
5 # * Distributed under the Boost Software License, Version 1.0. (See
6 # * accompanying file LICENSE_1_0.txt or copy at
7 # * http://www.boost.org/LICENSE_1_0.txt)
8 # */
9 #
10 # /* Revised by Paul Mensonides (2002) */
11 #
12 # /* See http://www.boost.org for most recent version. */
13 #
14 # ifndef MSGPACK_PREPROCESSOR_LIST_FOR_EACH_HPP
15 # define MSGPACK_PREPROCESSOR_LIST_FOR_EACH_HPP
16 #
21 #
22 # /* MSGPACK_PP_LIST_FOR_EACH */
23 #
24 # if ~MSGPACK_PP_CONFIG_FLAGS() & MSGPACK_PP_CONFIG_EDG()
25 # define MSGPACK_PP_LIST_FOR_EACH(macro, data, list) MSGPACK_PP_LIST_FOR_EACH_I(MSGPACK_PP_LIST_FOR_EACH_O, (macro, data), list)
26 # else
27 # define MSGPACK_PP_LIST_FOR_EACH(macro, data, list) MSGPACK_PP_LIST_FOR_EACH_X(macro, data, list)
28 # define MSGPACK_PP_LIST_FOR_EACH_X(macro, data, list) MSGPACK_PP_LIST_FOR_EACH_I(MSGPACK_PP_LIST_FOR_EACH_O, (macro, data), list)
29 # endif
30 #
31 # if ~MSGPACK_PP_CONFIG_FLAGS() & MSGPACK_PP_CONFIG_EDG()
32 # define MSGPACK_PP_LIST_FOR_EACH_O(r, md, i, elem) MSGPACK_PP_LIST_FOR_EACH_O_D(r, MSGPACK_PP_TUPLE_ELEM(2, 0, md), MSGPACK_PP_TUPLE_ELEM(2, 1, md), elem)
33 # else
34 # define MSGPACK_PP_LIST_FOR_EACH_O(r, md, i, elem) MSGPACK_PP_LIST_FOR_EACH_O_I(r, MSGPACK_PP_TUPLE_REM_2 md, elem)
35 # define MSGPACK_PP_LIST_FOR_EACH_O_I(r, im, elem) MSGPACK_PP_LIST_FOR_EACH_O_D(r, im, elem)
36 # endif
37 #
38 # define MSGPACK_PP_LIST_FOR_EACH_O_D(r, m, d, elem) m(r, d, elem)
39 #
40 # /* MSGPACK_PP_LIST_FOR_EACH_R */
41 #
42 # if ~MSGPACK_PP_CONFIG_FLAGS() & MSGPACK_PP_CONFIG_EDG()
43 # define MSGPACK_PP_LIST_FOR_EACH_R(r, macro, data, list) MSGPACK_PP_LIST_FOR_EACH_I_R(r, MSGPACK_PP_LIST_FOR_EACH_O, (macro, data), list)
44 # else
45 # define MSGPACK_PP_LIST_FOR_EACH_R(r, macro, data, list) MSGPACK_PP_LIST_FOR_EACH_R_X(r, macro, data, list)
46 # define MSGPACK_PP_LIST_FOR_EACH_R_X(r, macro, data, list) MSGPACK_PP_LIST_FOR_EACH_I_R(r, MSGPACK_PP_LIST_FOR_EACH_O, (macro, data), list)
47 # endif
48 #
49 # endif