FOLLY_PP_FOR_EACH
Declared in <folly/Preprocessor.h>
#define FOLLY_PP_FOR_EACH(fn, ...)
Used to invoke a preprocessor macro, the name of which is passed as the first argument, once for each subsequent variadic argument.
At present, supports [0, 16) arguments.]
This input:
#define DOIT(a) go_do_it(a); FOLLY_PP_FOR_EACH(DOIT, 3, 5, 7) #undef DOIT
Expands to this output (with whitespace adjusted for clarity):
go_do_it(3); go_do_it(5); go_do_it(7);
| Name | Description |
|---|---|
| fn | The macro to invoke once for each subsequent argument. |