@@ -283,12 +283,13 @@ def find_attr_comment(attr_name)
283283
284284 def find_body ( class_name , meth_name , meth_obj , body , quiet = false )
285285 case body
286- when %r"((?>/\* .*?\* /\s *))(?:(?:static|SWIGINTERN)\s +)?(?:intern\s +)?VALUE\s +#{ meth_name }
287- \s *(\( [^)]*\) )([^;]|$)"xm
288- comment , params = $1, $2
289- body_text = $&
286+ when %r"((?>/\* .*?\* /\s *))((?:(?:static|SWIGINTERN)\s +)?(?:intern\s +)?VALUE\s +#{ meth_name }
287+ \s *(\( [^)]*\) )([^;]|$))"xm
288+ comment = $1
289+ body_text = $2
290+ params = $3
290291
291- remove_private_comments ( comment ) if comment
292+ remove_private_comments comment if comment
292293
293294 # see if we can find the whole body
294295
@@ -301,15 +302,15 @@ def find_body(class_name, meth_name, meth_obj, body, quiet = false)
301302 # distinct (for example Kernel.hash and Kernel.object_id share the same
302303 # implementation
303304
304- override_comment = find_override_comment ( class_name , meth_obj . name )
305+ override_comment = find_override_comment class_name , meth_obj . name
305306 comment = override_comment if override_comment
306307
307- find_modifiers ( comment , meth_obj ) if comment
308+ find_modifiers comment , meth_obj if comment
308309
309310# meth_obj.params = params
310311 meth_obj . start_collecting_tokens
311- meth_obj . add_token ( RDoc ::RubyToken ::Token . new ( 1 , 1 ) . set_text ( body_text ) )
312- meth_obj . comment = mangle_comment ( comment )
312+ meth_obj . add_token RDoc ::RubyToken ::Token . new ( 1 , 1 ) . set_text ( body_text )
313+ meth_obj . comment = mangle_comment comment
313314 when %r{((?>/\* .*?\* /\s *))^\s *\# \s *define\s +#{ meth_name } \s +(\w +)}m
314315 comment = $1
315316 find_body ( class_name , $2, meth_obj , body , true )
0 commit comments