I'm using preprocessor macros to declare some repetitive variables, specifically:
QuitCallbackType quitCallback;
LossCallbackType lossCallback;
PauseCallbackType pauseCallback;
KeyCallbackType keyCallback;
MouseCallbackType mouseCallback;
I'd like to use a preprocessor macro to do it, a la
CREATE_CALLBACK_STORAGE(quit)
CREATE_CALLBACK_STORAGE(loss)
CREATE_CALLBACK_STORAGE(pause)
CREATE_CALLBACK_STORAGE(key)
CREATE_CALLBACK_STORAGE(mouse)
where it would essentially be like this:
#define CREATE_CALLBACK_STORAGE(x) capitalize(x)##CallbackType x##CallBack;
Is there a way to do this, so that I don't have to pass in both the capitalized AND lowercase versions of each name?
I realize it's not much less typing to use macros, but the problem itself began intriguing me.