EzC
Macros
ezc_macro.h File Reference

Macros for helping you write your own featureful macros. More...

Go to the source code of this file.

Macros

#define SST_MAP(f, ...)   SST_EVAL(SST_MAP1(f, __VA_ARGS__, ()()(), ()()(), ()()(), 0))
 Map function to specified variables. More...
 
#define SST_MAP_LIST(f, ...)   SST_EVAL(SST_MAP_LIST1(f, __VA_ARGS__, ()()(), ()()(), ()()(), 0))
 Map function to specified variables and return their results. More...
 

Detailed Description

Macros for helping you write your own featureful macros.

All macros with the SST_ prefix are authored by William "swansontec" Swanson. The only modification made to his code is the adding of the aformentioned prefix to all his macros.

Macro Definition Documentation

◆ SST_MAP

#define SST_MAP (   f,
  ... 
)    SST_EVAL(SST_MAP1(f, __VA_ARGS__, ()()(), ()()(), ()()(), 0))

Map function to specified variables.

Applies the function macro f to each of the arguments.

Parameters
fFunction macro.
...Arguments to be passed to f.
Returns
N/A

◆ SST_MAP_LIST

#define SST_MAP_LIST (   f,
  ... 
)    SST_EVAL(SST_MAP_LIST1(f, __VA_ARGS__, ()()(), ()()(), ()()(), 0))

Map function to specified variables and return their results.

Applies the function macro f to each of the arguments and and inserts commas between the results.

Parameters
fFunction macro.
...Arguments to be passed to f.
Returns
The comma seperated results of f for each arguments it was called with.