mirror of
https://github.com/ruby/ruby.git
synced 2022-11-09 12:17:21 -05:00
* lib/rdoc.rb, lib/rdoc, test/rdoc: Update to RDoc 4.2.0.alpha(313287)
git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@47391 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
This commit is contained in:
parent
670c6e8ce9
commit
d42d6e690e
56 changed files with 1597 additions and 223 deletions
|
|
@ -240,7 +240,15 @@ class RDoc::AnyMethod < RDoc::MethodAttr
|
|||
return []
|
||||
end
|
||||
|
||||
params = params.gsub(/\s+/, '').split ','
|
||||
if @block_params then
|
||||
# If this method has explicit block parameters, remove any explicit
|
||||
# &block
|
||||
params.sub!(/,?\s*&\w+/, '')
|
||||
else
|
||||
params.sub!(/\&(\w+)/, '\1')
|
||||
end
|
||||
|
||||
params = params.gsub(/\s+/, '').split(',').reject(&:empty?)
|
||||
|
||||
params.map { |param| param.sub(/=.*/, '') }
|
||||
end
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue