DocumentationTools/ModuleDocumentor.py

changeset 2956
615dbd8a696a
parent 2953
703452a2876f
child 2989
7efa8b8b6903
diff -r e9aeafe80329 -r 615dbd8a696a DocumentationTools/ModuleDocumentor.py
--- a/DocumentationTools/ModuleDocumentor.py	Sat Sep 28 20:12:12 2013 +0200
+++ b/DocumentationTools/ModuleDocumentor.py	Sun Sep 29 10:19:28 2013 +0200
@@ -878,7 +878,7 @@
             ditem = self.__processInlineTags(ditem)
             desc = ditem.strip()
             if desc:
-                if desc.startswith("@param") or desc.startswith("@keyparam"):
+                if desc.startswith(("@param", "@keyparam")):
                     inTagSection = True
                     parts = desc.split(None, 2)
                     if len(parts) < 2:
@@ -891,16 +891,14 @@
                     except IndexError:
                         paramList.append([paramName, []])
                     lastItem = paramList[-1][1]
-                elif desc.startswith("@return"):
+                elif desc.startswith(("@return", "@ireturn")):
                     inTagSection = True
                     parts = desc.split(None, 1)
                     if len(parts) < 2:
                         raise TagError("Wrong format in {0} line.\n".format(parts[0]))
                     returns = [parts[1]]
                     lastItem = returns
-                elif desc.startswith("@exception") or \
-                     desc.startswith("@throws") or \
-                     desc.startswith("@raise"):
+                elif desc.startswith(("@exception", "@throws", "@raise")):
                     inTagSection = True
                     parts = desc.split(None, 2)
                     if len(parts) < 2:

eric ide

mercurial