summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorDimitri van Heesch <doxygen@gmail.com>2019-08-04 09:49:11 (GMT)
committerDimitri van Heesch <doxygen@gmail.com>2019-08-04 09:49:11 (GMT)
commit07926ab1f7f60f63cfe25201dcf81897df12d89c (patch)
tree1bb8d799f870b7c2c6d061c89baf7a2ec0c25e45
parenta4dde87ba3c008ff463af7b6d6d02d13212ea695 (diff)
downloadDoxygen-07926ab1f7f60f63cfe25201dcf81897df12d89c.zip
Doxygen-07926ab1f7f60f63cfe25201dcf81897df12d89c.tar.gz
Doxygen-07926ab1f7f60f63cfe25201dcf81897df12d89c.tar.bz2
Minor code simplifications
-rw-r--r--src/commentscan.l11
1 files changed, 8 insertions, 3 deletions
diff --git a/src/commentscan.l b/src/commentscan.l
index 1d7297a..168de94 100644
--- a/src/commentscan.l
+++ b/src/commentscan.l
@@ -812,7 +812,10 @@ static inline void setOutput(OutputContext ctx)
}
else
{
- if (!current->doc.isEmpty()) current->doc += "\n";
+ if (!current->doc.isEmpty()) // when appending parts add a new line
+ {
+ current->doc += "\n";
+ }
pOutputString = &current->doc;
inContext = OutputDoc; // need to switch to detailed docs, see bug 631380
}
@@ -3147,8 +3150,10 @@ bool parseCommentBlock(/* in */ ParserInterface *parser,
parseMore = FALSE;
inBody = isInbody;
outputXRef.resize(0);
- if (!(isBrief || isAutoBriefOn))
- if (!current->doc.isEmpty()) current->doc += "\n";
+ if (!isBrief && !isAutoBriefOn && !current->doc.isEmpty())
+ { // add newline separator between detailed comment blocks
+ current->doc += '\n';
+ }
setOutput( isBrief || isAutoBriefOn ? OutputBrief : OutputDoc );
briefEndsAtDot = isAutoBriefOn;
g_condCount = 0;