aboutsummaryrefslogtreecommitdiffstats
path: root/lib/rdoc
diff options
context:
space:
mode:
authorMike Dalessio <mike.dalessio@gmail.com>2021-09-20 10:09:14 -0400
committergit <svn-admin@ruby-lang.org>2021-10-16 06:31:11 +0900
commit4ffc3fb019bd1373991ca9278299f6d7c44c3024 (patch)
tree7feb4734a102253db807c6a2eb4eab6ec9ff5f84 /lib/rdoc
parent5d975684da6d7b8ce309c2b176698b37eac5cabb (diff)
downloadruby-4ffc3fb019bd1373991ca9278299f6d7c44c3024.tar.gz
[ruby/rdoc] fix: alias to method with call-seq
This change fixes alias call-seq to return nil if the method's call-seq does not specify the alias. Previously, the alias's call-seq would be an empty string in this case which broke darkfish rendering. This change also backfills test coverage for 0ead786 which moved call-seq deduplication into AnyMethod. https://github.com/ruby/rdoc/commit/5ce2789b6f
Diffstat (limited to 'lib/rdoc')
-rw-r--r--lib/rdoc/any_method.rb2
1 files changed, 1 insertions, 1 deletions
diff --git a/lib/rdoc/any_method.rb b/lib/rdoc/any_method.rb
index 3d0b60790d..0b7dd717ab 100644
--- a/lib/rdoc/any_method.rb
+++ b/lib/rdoc/any_method.rb
@@ -359,6 +359,6 @@ class RDoc::AnyMethod < RDoc::MethodAttr
entry =~ /\s#{ignore}\s/
end
- matching.join "\n"
+ matching.empty? ? nil : matching.join("\n")
end
end