Why does the Doxygen documentation appear only for the last of several related groups?

I am trying to document several similar functions at the same time using Doxygen groups. I would like the functions to use the same documentation as shown in the example here .

// @{
//! @brief Some documentation
int func1(void);
int func2(void);
// @}

// @{
//! @brief Some other documentation
int func3(void);
int func4(void);
// @}

However, when I run doxygen, only the second group maps the @brief message to the HTML output. Am I doing something wrong, or is this a potential mistake?

Notice I'm not trying to nest the groups that doxygen documentation talks about.

+3
source share
3 answers

Solved!

The documentation to be accounted for for each functional group must precede the opening brackets:

//! @brief Some documentation
// @{
int func1(void);
int func2(void);
// @}

//! @brief Some other documentation
// @{
int func3(void);
int func4(void);
// @}
+2
source

DISTRIBUTE_GROUP_DOC . , :

//@{
//! Same documentation for both members. Details ...
void func1InGroup1();
void func2InGroup1();
//@}

:

//! @name Group name
//@{
//! Same documentation for both members. Details ...
void func1InGroup1();
void func2InGroup1();
//@}
+4

Just a thought: Doxygen is picky when it comes to spaces. Be sure to use '// @ {', not '// @ {'.

0
source

Source: https://habr.com/ru/post/1794819/


All Articles