eric6/Utilities/ClassBrowsers/pyclbr.py

changeset 8493
da73e8e32ba7
parent 8217
385f60c94548
--- a/eric6/Utilities/ClassBrowsers/pyclbr.py	Thu Jul 29 19:43:01 2021 +0200
+++ b/eric6/Utilities/ClassBrowsers/pyclbr.py	Fri Jul 30 13:43:42 2021 +0200
@@ -416,8 +416,9 @@
         # start with zero based line after start line
         while lineno < len(lines):
             line = lines[lineno]
-            if line.strip():
-                # line contains some text
+            if line.strip() and not line.lstrip().startswith("#"):
+                # line contains some text and does not start with
+                # a comment sign
                 lineIndent = _indent(line.replace(line.lstrip(), ""))
                 if lineIndent <= indent:
                     return lineno

eric ide

mercurial