I wasn't able to find this anywhere, so...
This is my first Doxygen attempt. I have a code in C and use Doxygen to generate the HTML documentation.
However, when I mix block and line comments, the resulting source code is not formatted correctly. Some comments (not doxygen) are rendered as acutal comments and some are shown as preprocessor lines.
This is a MWE source code:
#ifdef __DEFINES_H_
#define __DEFINES_H_
// this comment looks like a comment
/** error */
#define ERROR -1
// this is also ok
/** This is zero */
#define ZERO 0
// and so is this one
#define FIRST 1 /**< the first */
// but this comment is listed with class="preprocessor"
#define TEN 10 /**< just 10 */
// and this comment also looks like a preprocessor line
/** error */
#define ANOTHER_ERROR -1
// here the comment looks like a comment again
/** This is zero */
#define ANOTHER_ZERO 0
#endif // __DEFINES_H_
The HTML source code for this file is the following (sorry for the long lines).
<div class="line"><a name="l00002"></a><span class="lineno"> 2</span> <span class="preprocessor">#define __DEFINES_H_</span></div>
<div class="line"><a name="l00003"></a><span class="lineno"> 3</span>  </div>
<div class="line"><a name="l00004"></a><span class="lineno"> 4</span> <span class="comment">// this comment looks like a comment</span></div>
<div class="line"><a name="l00006"></a><span class="lineno"> 6</span> <span class="comment"></span><span class="preprocessor">#define ERROR -1</span></div>
<div class="line"><a name="l00007"></a><span class="lineno"> 7</span>  </div>
<div class="line"><a name="l00008"></a><span class="lineno"> 8</span> <span class="comment">// this is also ok</span></div>
<div class="line"><a name="l00010"></a><span class="lineno"> 10</span> <span class="comment"></span><span class="preprocessor">#define ZERO 0</span></div>
<div class="line"><a name="l00011"></a><span class="lineno"> 11</span>  </div>
<div class="line"><a name="l00012"></a><span class="lineno"> 12</span> <span class="comment">// and so is this one</span></div>
<div class="line"><a name="l00013"></a><span class="lineno"> 13</span> <span class="preprocessor">#define FIRST 1 </span></div>
<div class="line"><a name="l00015"></a><span class="lineno"> 15</span> <span class="preprocessor">// but this comment is listed with class="preprocessor"</span></div>
<div class="line"><a name="l00016"></a><span class="lineno"> 16</span> <span class="preprocessor">#define TEN 10 </span></div>
<div class="line"><a name="l00018"></a><span class="lineno"> 18</span> <span class="preprocessor">// and this comment also looks like a preprocessor line</span></div>
<div class="line"><a name="l00019"></a><span class="lineno"> 19</span>  </div>
<div class="line"><a name="l00020"></a><span class="lineno"> 20</span> <span class="preprocessor">#define ANOTHER_ERROR -1</span></div>
<div class="line"><a name="l00021"></a><span class="lineno"> 21</span>  </div>
<div class="line"><a name="l00022"></a><span class="lineno"> 22</span> <span class="comment">// here the comment looks like a comment again</span></div>
<div class="line"><a name="l00024"></a><span class="lineno"> 24</span> <span class="comment"></span><span class="preprocessor">#define ANOTHER_ZERO 0</span></div>
<div class="line"><a name="l00025"></a><span class="lineno"> 25</span>  </div>
<div class="line"><a name="l00026"></a><span class="lineno"> 26</span> <span class="preprocessor">#endif // __DEFINES_H_</span></div>
And this is how the browser shows it.
Lines 15 and 18 use <span class="preprocessor"> when should use <span class="comment">.
As I can see, it happens after /**< */ comments.
But how to fix this?
