#include <boost/preprocessor/arithmetic/dec.hpp> #include <boost/preprocessor/seq/transform.hpp> #define SEQ (1)(3)(2)(5) #define OP(s, data, elem) BOOST_PP_DEC(elem) BOOST_PP_SEQ_TRANSFORM(OP, 3, SEQ) // expands to (0)(2)(1)(4)
Distributed under the Boost Software License, Version 1.0. (See accompanying file LICENSE_1_0.txt or copy at www.boost.org/LICENSE_1_0.txt)