In the first definition, #a
means to print the macro argument as a string. This will turn, e.g. STR(foo)
into "foo"
, but it won't do macro-expansion on its arguments.
The second definition doesn't add anything to the first, but by passing its argument to another macro, it forces full macro expansion of its argument. So XSTR(expr)
creates a string of expr
with all macros fully expanded.
与恶龙缠斗过久,自身亦成为恶龙;凝视深渊过久,深渊将回以凝视…