I want to write macro in c code to freeing many pointers like this :
FREE(ptr1, ptr2, ptr3, ptr4, ptrx);
For me, this is better than
use BOOST
#include #include #define PROC(r, f, elem) f(elem); #define FREE(...) BOOST_PP_SEQ_FOR_EACH(PROC, free, BOOST_PP_TUPLE_TO_SEQ((__VA_ARGS__)))