summaryrefslogtreecommitdiff
path: root/lib/rdoc/parsers/parse_simple.rb
diff options
context:
space:
mode:
Diffstat (limited to 'lib/rdoc/parsers/parse_simple.rb')
-rw-r--r--lib/rdoc/parsers/parse_simple.rb6
1 files changed, 5 insertions, 1 deletions
diff --git a/lib/rdoc/parsers/parse_simple.rb b/lib/rdoc/parsers/parse_simple.rb
index b01104574e..3f1a546964 100644
--- a/lib/rdoc/parsers/parse_simple.rb
+++ b/lib/rdoc/parsers/parse_simple.rb
@@ -30,8 +30,12 @@ module RDoc
def scan
# @body.gsub(/^(\s\n)+/, '')
- @top_level.comment = @body
+ @top_level.comment = remove_private_comments(@body)
@top_level
end
+
+ def remove_private_comments(comment)
+ comment.gsub(/^--.*?^\+\+/m, '').sub(/^--.*/m, '')
+ end
end
end