What\'s the trick to create a variadic macro FOO(a1, a2, a3,..., an) such that it expands to FOOn(a1, a2, a3,..., an) for values of n
FOO(a1, a2, a3,..., an)
FOOn(a1, a2, a3,..., an)
n
This post Variadic macro to count number of arguments has what you're looking for I believe. Look at the first and second responses.