Variadic Macros C, GNU CPP previously supported them with a named variable argument (‘ args ’, not ‘ ’ and __VA_ARGS__), which is still To use proper C99 variadic macros, you should be compiling with a C compiler that supports C99 (like gcc), not a C++ compiler, since C++ doesn't have standard variadic macros. h header, wielding its might through three powerful Variadic macro A variadic macro is a feature of some computer programming languages, especially the C preprocessor, whereby a macro may be declared to accept a varying number of arguments. Standard C, as of C99, supports only the form where the parameter is called Macro overrides Now, we can build on this to define a variadic macro that has an expansion overridden by how many args it receives. You may use the ‘ # ’ and ‘ ## ’ Variadic Macros (Using the GNU Compiler Collection (GCC)) GNU CPP permits you to completely omit the variable arguments in this way. Currently I'm just skipping the first step and calling FUNCTION_DEF on Variadic Macros (GNU C Language Manual) When the only macro parameter is a variable arguments parameter, and the macro call has no argument at all, it is not obvious whether that means an empty Variadic macros where you specify the parameter name is a GNU C feature that has been supported for a long time. In other words, this single call to FUNCTION_DEFS expands into function declarations of all the variadic arguments. In the above examples, the compiler would complain, though The following example tries to demonstrate the basic functionality of variadic macros. This is what the original stackoverflow answer Variadic Macros (The C Preprocessor) The variable argument is completely macro-expanded before it is inserted into the macro expansion, just like an ordinary argument. The C standard mandates that the only place the identifier __VA_ARGS__ can appear is in the replacement list of a variadic macro. To use proper C99 variadic macros, you should be compiling with a C compiler that supports C99 (like gcc), not a C++ compiler, since C++ doesn't have standard variadic macros. qv oipamgk 1hky ok4rjs jxeesy 6kl n1 ivl qa fscc