[Doxygen-users] How to get Doxygen to completely ignore a section of code?
Brought to you by:
dimitri
From: Warren Y. <wa...@et...> - 2005-05-26 12:23:56
|
I've got a project converted over to Doxygen, and for the most part it's working fine. But there are two instances where I want Doxygen to ignore something, unconditionally, no questions asked. The first problem instance is that I have some macros that are used internally only, and Doxygen warns that they're undocumented. I don't really want to document them, but to placate Doxygen I've tried anyway, and nothing makes the warnings go away. I'd prefer to just tell Doxygen, "ignore this bit, please". I've tried \if, but the macros still generate warnings; other undocumented declarations (not macros) within that \if block do get ignored, however. Here's one example of the code, in case it matters: #define oprsw(opr, other, conv) \ template<class Str> \ inline other operator opr (ColData_Tmpl<Str> x, other y) \ {return static_cast<conv>(x) opr y;} \ template<class Str> \ inline other operator opr (other x, ColData_Tmpl<Str> y) \ {return x opr static_cast<conv>(y);} The warning is, "Member oprsw(opr, other, conv) of file coldata.h is not documented." If anything, I'd want to document instantiations of this macro, not the macro itself. The second instance I'd like Doxygen to ignore is the guts of a legacy header file. I want to have a \file comment to document why the file exists, but I don't want it to try and parse anything in the file. This legacy file exists to preserve source compatibility for a library, and I really don't want to document its internals. All I want is a page in the Doxygen output explaining that this is an obsolete file and that new code should use its replacement. The problem is, Doxygen still tries to generate the #include graph, which takes time, for no good purpose. I can leave out the \file comment, which solves the processing time problem and the wish to not have the file's internals documented, but then I end up with an entry in the File List with no explanation of why the file exists. Both of these problems could be solved if I can find a way to make Doxygen ignore a section of code completely. |