Utilities/ClassBrowsers/pyclbr.py

changeset 2768
eab35f6e709f
parent 2302
f29e9405c851
child 2769
8cbebde7a984
diff -r c413e9eeaf95 -r eab35f6e709f Utilities/ClassBrowsers/pyclbr.py
--- a/Utilities/ClassBrowsers/pyclbr.py	Wed Jul 03 19:23:52 2013 +0200
+++ b/Utilities/ClassBrowsers/pyclbr.py	Wed Jul 03 19:34:42 2013 +0200
@@ -320,6 +320,9 @@
             # close all classes indented at least as much
             while classstack and \
                   classstack[-1][1] >= thisindent:
+                if classstack[-1][0] is not None:
+                    # record the end line
+                    classstack[-1][0].setEndLine(lineno - 1)
                 del classstack[-1]
             if classstack:
                 # it's a class method
@@ -354,6 +357,9 @@
             # close all classes indented at least as much
             while classstack and \
                   classstack[-1][1] >= thisindent:
+                if classstack[-1][0] is not None:
+                    # record the end line
+                    classstack[-1][0].setEndLine(lineno - 1)
                 del classstack[-1]
             lineno = lineno + src.count('\n', last_lineno_pos, start)
             last_lineno_pos = start

eric ide

mercurial