diff options
-rw-r--r-- | ChangeLog | 5 | ||||
-rw-r--r-- | lib/rdoc/parsers/parse_c.rb | 2 |
2 files changed, 6 insertions, 1 deletions
@@ -1,3 +1,8 @@ +Wed Dec 14 23:50:20 2005 Nobuyoshi Nakada <nobu@ruby-lang.org> + + * lib/rdoc/parsers/parse_c.rb (find_class_comment): fix for class + document with prototypes. [ruby-core:06863] + Wed Dec 14 23:39:53 2005 Nobuyoshi Nakada <nobu@ruby-lang.org> * dir.c (has_magic): glob names contain alphabets to enable case fold diff --git a/lib/rdoc/parsers/parse_c.rb b/lib/rdoc/parsers/parse_c.rb index e6c18cb0ff..89d36c6c50 100644 --- a/lib/rdoc/parsers/parse_c.rb +++ b/lib/rdoc/parsers/parse_c.rb @@ -262,7 +262,7 @@ module RDoc def find_class_comment(class_name, class_meth) comment = nil if @body =~ %r{((?>/\*.*?\*/\s+)) - (static\s+)?void\s+Init_#{class_name}\s*\(\)}xmi + (static\s+)?void\s+Init_#{class_name}\s*(?:_\(\s*)?\(\s*(?:void\s*)\)}xmi comment = $1 elsif @body =~ %r{Document-(class|module):\s#{class_name}\s*?\n((?>.*?\*/))}m comment = $2 |