I have a globally defined character that must be conditionally undefined for a given subset of source files. All files that require special treatment are already wrapped in pre- and post-inclusion:
pre.h:
#undefine mysymbol
post.h:
#define mysymbol MY_SYMBOL_DEFINITION
My problem is that pre.h, and post.hmay be included multiple times for a given source file due to the inclusion of various chain. Thus, I need 1 to enable pre.h for the first time, and I need 2 for the last time when enabled post.h. Conceptually:
pre
pre
pre
post
post
post
Since I use GCC 3.4.6, I do not have access to push and pop macro pragmas , which otherwise could solve this problem for me.
?
- / , , .
" ?"
new new(__FILE__, __LINE__) - . - , , , , , .