summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authoralbert-github <albert.tests@gmail.com>2020-05-27 15:47:44 (GMT)
committeralbert-github <albert.tests@gmail.com>2020-05-27 15:47:44 (GMT)
commit5870db1f2848ff551007a0feff0b25e1029f7eb6 (patch)
treef7366972c627443ba4d8be3b7c7f6b777c998b5c
parent09aa9ba7da61c9452523f40719cf07bf36e6c976 (diff)
downloadDoxygen-5870db1f2848ff551007a0feff0b25e1029f7eb6.zip
Doxygen-5870db1f2848ff551007a0feff0b25e1029f7eb6.tar.gz
Doxygen-5870db1f2848ff551007a0feff0b25e1029f7eb6.tar.bz2
Warning in case of multiple python documentation sections.
In special cases when having multiple documentation section for 1 item in python it is possible that they are concatenated in a wrong way and result in a warning. Each documentation section should be seen as a separate section and be separated from other sections. the example: ``` ##################################################################### # # Modify Install Stage ############################################ ##################################################################### class install(_install): """Specialised python package installer. It does some required chown calls in addition to the usual stuff. """ ``` gives a warning like: ``` warning: unexpected command endverbatim ```
-rw-r--r--src/pyscanner.l4
1 files changed, 4 insertions, 0 deletions
diff --git a/src/pyscanner.l b/src/pyscanner.l
index f2a315c..ed76c75 100644
--- a/src/pyscanner.l
+++ b/src/pyscanner.l
@@ -1618,6 +1618,10 @@ static void handleCommentBlock(yyscan_t yyscanner,const QCString &doc,bool brief
// TODO: Fix me
yyextra->docBlockInBody=FALSE;
+ if (!yyextra->current->doc.isEmpty())
+ {
+ yyextra->current->doc=yyextra->current->doc.stripWhiteSpace()+"\n\n";
+ }
if (yyextra->docBlockInBody && yyextra->previous && !yyextra->previous->doc.isEmpty())
{
yyextra->previous->doc=yyextra->previous->doc.stripWhiteSpace()+"\n\n";