eric6/QScintilla/DocstringGenerator/EricdocGenerator.py

changeset 8005
94a6a1bd5f80
parent 8000
47b15df088e4
--- a/eric6/QScintilla/DocstringGenerator/EricdocGenerator.py	Mon Jan 25 14:44:35 2021 +0100
+++ b/eric6/QScintilla/DocstringGenerator/EricdocGenerator.py	Mon Jan 25 14:53:56 2021 +0100
@@ -99,7 +99,11 @@
         lines.append(argLine)
     
     # add return section
-    if functionInfo.hasYield or functionInfo.returnValueInBody:
+    if (
+        functionInfo.hasYield or
+        functionInfo.returnValueInBody or
+        functionInfo.returnTypeAnnotated
+    ):
         if functionInfo.hasYield:
             lines.append("@yield DESCRIPTION")
             rType = "@ytype"

eric ide

mercurial