https://issues.dlang.org/show_bug.cgi?id=14413

--- Comment #6 from Nick Sabalausky <[email protected]> ---
This is happening in function "Lexer::combineComments" in "lexer.c". The
function combines consecutive doc comments, like:

/++ comment 1 +/

/++
  comment 2
+/

/** comment 3 */
/** comment 4 */

/// comment 5
/// comment 6

Note that the lexer treats each line of a line comment as a separate comment.

Those all get combined and each one becomes a separate paragraph (by way of
"Lexer::combineComments" concatenating them with an extra \n added in between
each one).

Ideally, IMO, "Lexer::combineComments" should only add the \n if there's at
least one blank line between two comments. I'm not sure how feasable that is,
but at the very least omitting the extra \n in between each would be an
improvement, because I can't imagine that consecutive doc comments are really
all that common, aside from the case in question here (immediately consecutive
line comments).

--

Reply via email to