Why is size param required for BOOST_PP_TUPLE_TO_LIST(size, tuple) ?

Hi there, I am looking at: http://www.boost.org/doc/libs/1_39_0/libs/preprocessor/doc/ref/tuple_to_list... Just ouf of curiosity why is size required ? Can't the number of argument be deduced using the preprocessor ? Eg.: http://groups.google.com/group/comp.std.c/browse_thread/thread/77ee8c8f92e4a... Thanks, -- Mathieu

2009/8/6 Mathieu Malaterre
Hi there,
I am looking at:
http://www.boost.org/doc/libs/1_39_0/libs/preprocessor/doc/ref/tuple_to_list...
Just ouf of curiosity why is size required ? Can't the number of argument be deduced using the preprocessor ? Eg.:
http://groups.google.com/group/comp.std.c/browse_thread/thread/77ee8c8f92e4a...
Boost PP uses C++ preprocessor. Variadic macros are not part of it, but they are part of C99 and many C++ compilers support it. AFAIK there is no way to get size of a tuple without variadic macros. Roman Perepelitsa.
participants (2)
-
Mathieu Malaterre
-
Roman Perepelitsa