#pragma dumpmacros(value[,value...])
Use this pragma when you want to see how macros are behaving in your program. This pragma provides information such as macro defines, undefines, and instances of usage. It prints output to the standard error (stderr) based on the order macros are processed. The dumpmacros pragma is in effect through the end of the file or until it reaches a #pragma end_dumpmacros. See end_dumpmacros. The following table lists the possible values for value:
|
The dumpmacros pragma has the same effect as the command-line option, however, the pragma overrides the command-line option. See -xdumpmacros[=value[,value...]].
The dumpmacros pragma does not nest so the following lines of code stop printing macro information when the #pragma end_dumpmacros is processed:
#pragma dumpmacros(defs, undefs) #pragma dumpmacros(defs, undefs) ... #pragma end_dumpmacros
The effect of the dumpmacros pragma is cumulative. The following lines
#pragma dumpmacros(defs, undefs) #pragma dumpmacros(loc)
have the same effect as:
#pragma dumpmacros(defs, undefs, loc)
If you use the option #pragma dumpmacros(use,no%loc), the name of each macro that is used is printed only once. If you use the option #pragma dumpmacros(use,loc), the location and macro name is printed every time a macro is used.