I couldn't think of a better way to word the title...
#define X(c) c
#define Y(c) X(c)
#undef X
int main(int argc,char*argv[])
{
std::cout << Y(5) << std::endl;
return 0;
}
This causes an error, because X() is not declared in this scope. Is there any way to make Y store a copy of X (aka, force the macro substitution to occur as I define Y) such that it no longer depends upon X existing? Perhaps boost has some preprocessor stuff for this, or maybe there's a simple way. Ideas?