[Doxygen-users] Documentation inside preprocessor macro definition
Brought to you by:
dimitri
From: Matthias M. <mmo...@gm...> - 2016-08-11 13:47:16
|
Dear all, I run into the following problem documenting my code with doxygen. Large parts of the code are created using preprocessor macros like this /// Helper macro for generating selectors for specialialized /// implementations of element-wise binary operations; generic /// implementation follows below #define FDBB_GENERATE_BINARY_ELEMENTOPERATION_OVERLOADS(OPNAME) \ /** @brief \ Selector for (specialized) implementation of \ fdbb::internal::elem_##OPNAME##<A,B>(A&& a, B&& b) function \ */ \ template<typename A, typename B, typename = void> \ struct elem_##OPNAME##_spec : public std::integral_constant<EnumETL, EnumETL::GENERIC>{}; FDBB_GENERATE_BINARY_ELEMENTOPERATION_OVERLOADS(mul) FDBB_GENERATE_BINARY_ELEMENTOPERATION_OVERLOADS(div) FDBB_GENERATE_BINARY_ELEMENTOPERATION_OVERLOADS(pow) #undef FDBB_GENERATE_BINARY_ELEMENTOPERATION_OVERLOADS Running doxygen (v1.8.11) with the following configuration of the preprocessor ENABLE_PREPROCESSING = YES MACRO_EXPANSION = YES EXPAND_ONLY_PREDEF = NO SEARCH_INCLUDES = YES INCLUDE_PATH = INCLUDE_FILE_PATTERNS = PREDEFINED = EXPAND_AS_DEFINED = SKIP_FUNCTION_MACROS = YES produces the following output (html): struct elem_mul_spec <file:///Users/mmoller/codes/FDBB/build.gcc5/doc/html/structfdbb_1_1internal_1_1elem__mul__spec.html> \ Selector for (specialized) implementation of \ fdbb::internal::elem_mul<A,B>(A&& a, B&& b) function \ More... <file:///Users/mmoller/codes/FDBB/build.gcc5/doc/html/structfdbb_1_1internal_1_1elem__mul__spec.html#details> Obviously, the backslash that is needed for multiline macros is included in the documentation. Any help on how to configure doxygen and/or modify the documentation is appreciated. Best regards, Matthias |