[cfe-dev] Missing info in macro expansion chain
Abramo Bagnara
abramo.bagnara at gmail.com
Sat Feb 25 03:18:24 PST 2012
In the source below I need to be able to detect that the token 4 has
been expanded by body of macro z, but I'm unable to do that.
Asking for immediate expansion range of expanded location I get a
MacroArgExpansion loc for argument x whose immediate expansion range is
macro p.
It seems that use of macro z is not tracked in expansion chain, I'm
missing something?
#define p(x) x
#define z 4
void foo() {
p(z);
}
More information about the cfe-dev
mailing list