Using MSVC6, SP5: BOOST_PP_LIST_AT() doesn't work in a transform function, but BOOST_PP_LIST_FIRST() and BOOST_PP_LIST_REST() work fine I expected the following code to expand to: a , b but instead it expands to BOOST_PP_TUPLE3_ELEM0 BOOST_PP_TUPLE2_ELEM0 BOOST_PP_WHILE0(BOOST_PP_LIST_REST_N_C,BOOST_PP_LIST_REST_N_F,((a,(7,(_,_,0),1),1),0)) , BOOST_PP_TUPLE3_ELEM0 BOOST_PP_TUPLE2_ELEM0 BOOST_PP_WHILE0(BOOST_PP_LIST_REST_N_C,BOOST_PP_LIST_REST_N_F,((b,(8,(_,_,0),1),1),0)) If I change the definition of F to use BOOST_PP_FIRST(X), it works ************* Example code*************** #define F(a,b,X) BOOST_PP_LIST_AT(X,0) #define LST BOOST_PP_TUPLE_TO_LIST(2,( \ BOOST_PP_TUPLE_TO_LIST(2,(a,7)), \ BOOST_PP_TUPLE_TO_LIST(2,(b,8)))) BOOST_PP_LIST_ENUM(BOOST_PP_LIST_TRANSFORM(F,dummy,LST))
participants (1)
-
jkharris01