diff options
Diffstat (limited to 'src/pyscanner.l')
-rw-r--r-- | src/pyscanner.l | 18 |
1 files changed, 12 insertions, 6 deletions
diff --git a/src/pyscanner.l b/src/pyscanner.l index 773391b..701381b 100644 --- a/src/pyscanner.l +++ b/src/pyscanner.l @@ -1253,9 +1253,12 @@ STARTDOCSYMS "##" QCString actualDoc=yyextra->docBlock; if (!yyextra->docBlockSpecial) // legacy unformatted docstring { - stripIndentation(actualDoc,yyextra->commentIndent); - actualDoc.prepend("\\verbatim\n"); - actualDoc.append("\\endverbatim "); + if (!actualDoc.isEmpty()) + { + stripIndentation(actualDoc,yyextra->commentIndent); + actualDoc.prepend("\\verbatim\n"); + actualDoc.append("\\endverbatim "); + } } //printf("-------> yyextra->current=%p yyextra->bodyEntry=%p\n",yyextra->current,yyextra->bodyEntry); handleCommentBlock(yyscanner, actualDoc, FALSE); @@ -1265,9 +1268,12 @@ STARTDOCSYMS "##" QCString actualDoc=yyextra->docBlock; if (!yyextra->docBlockSpecial) // legacy unformatted docstring { - stripIndentation(actualDoc,yyextra->commentIndent); - actualDoc.prepend("\\verbatim\n"); - actualDoc.append("\\endverbatim "); + if (!actualDoc.isEmpty()) + { + stripIndentation(actualDoc,yyextra->commentIndent); + actualDoc.prepend("\\verbatim\n"); + actualDoc.append("\\endverbatim "); + } } actualDoc.prepend("\\namespace "+yyextra->moduleScope+" "); handleCommentBlock(yyscanner, actualDoc, FALSE); |