- File:
-
- 1 edited
Legend:
- Unmodified
- Added
- Removed
-
src/Actions/Action_impl_python.hpp
rd628da r6ba9ba 18 18 #include <boost/preprocessor/facilities/expand.hpp> 19 19 #include <boost/preprocessor/iteration/local.hpp> 20 #include <boost/preprocessor/list/adt.hpp> 20 21 #include <boost/preprocessor/punctuation/comma_if.hpp> 21 22 #define NODEFAULT "" 22 #include <boost/preprocessor/punctuation/paren.hpp> 23 23 24 24 // some derived names: if CATEGORY is not given, we don't prefix with it … … 32 32 #define PARAMS BOOST_PP_CAT(ACTIONNAME, Parameters) 33 33 #endif 34 35 // for paramdefaults entries 36 #define PARAM_DEFAULT(x) \ 37 (x, BOOST_PP_NIL) 34 38 35 39 // check if no lists given … … 61 65 BOOST_PP_SEQ_ELEM(n, STRINGLIST) \ 62 66 ) \ 63 = BOOST_PP_SEQ_ELEM(n, DEFAULTLIST) 67 = \ 68 BOOST_PP_IF( \ 69 BOOST_PP_NOT( BOOST_PP_LIST_IS_NIL( BOOST_PP_SEQ_ELEM(n, paramdefaults) ) ), \ 70 toString BOOST_PP_LPAREN() \ 71 BOOST_PP_LIST_FIRST( BOOST_PP_SEQ_ELEM(n, DEFAULTLIST) ) \ 72 BOOST_PP_RPAREN(), \ 73 std::string("") \ 74 ) 64 75 65 76 // print a list of comma-separated list, i.e. (,)arg("Action") … … 142 153 #undef PARAMS 143 154 #undef MAXPARAMTYPES 155 #undef PARAM_DEFAULT 144 156 145 157 #undef help_print
Note:
See TracChangeset
for help on using the changeset viewer.