GNOME Bugzilla – Bug 694147
#undef is ignored by doxygen
Last modified: 2013-08-23 15:04:53 UTC
Example code: #define a someting #undef a int a() { return 0; } Doxyfile: ENABLE_PREPROCESSING = YES MACRO_EXPANSION = YES EXPAND_ONLY_PREDEF = NO INPUT = test.c Result: Macros #define a someting Functions int someting () But should be: Macros #define a someting Functions int a () This is regression (#undef works correctly in 1.7.3)
Thanks, I'll use your patch posted on doxygen-develop: diff --git a/src/pre.l b/src/pre.l index 4c017da..6f05d91 100644 --- a/src/pre.l +++ b/src/pre.l @@ -233,6 +233,7 @@ class DefineManager { Define *d = m_contextDefines.find(name); //printf("isDefined(%s)=%p\n",name,d); + if (d && d->undef) d=0; return d; } /** Returns a reference to the defines found in the current context. */
This bug was previously marked ASSIGNED, which means it should be fixed in doxygen version 1.8.5. Please verify if this is indeed the case. Reopen the bug if you think it is not fixed and please include any additional information that you think can be relevant.