diff --git a/lib/rocco.rb b/lib/rocco.rb index 75c3e31..921dc79 100644 --- a/lib/rocco.rb +++ b/lib/rocco.rb @@ -104,7 +104,7 @@ class Rocco docs, code = [], [] data.split("\n").each do |line| case line - when /^\s*#(?!\!)/ + when /^\s*#(?:\s+|$)/ if code.any? sections << [docs, code] docs, code = [], []