summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorMorgan Goose <morgan.goose@gmail.com>2010-10-25 18:56:38 -0400
committerMorgan Goose <morgan.goose@gmail.com>2010-10-25 18:56:38 -0400
commite1b863422ccbf6e49f1f580b0554349a5bfb9331 (patch)
treee90b575f8a7f61dadbb7db21163b08722422c31b
parenta13f4ef6d05d328d3f9e82f6d516b1972b086f92 (diff)
downloadpycco-e1b863422ccbf6e49f1f580b0554349a5bfb9331.tar.gz
Think that the order is good now for the docstrings.
-rwxr-xr-xpycco6
1 files changed, 3 insertions, 3 deletions
diff --git a/pycco b/pycco
index aa4bb4c..3070af7 100755
--- a/pycco
+++ b/pycco
@@ -98,9 +98,9 @@ def parse(source, code):
docs_text += re.sub(language["comment_matcher"], "", line) + "\n"
else:
-# if docs_text:
-# save(docs_text, code_text)
-# code_text = has_code = docs_text = ''
+ if code_text and any([x in line for x in ['class ', 'def ']]):
+ save(docs_text, code_text)
+ code_text = has_code = docs_text = ''
has_code = True
code_text += line + '\n'