We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
There was an error while loading. Please reload this page.
1 parent 7a6015a commit f54449dCopy full SHA for f54449d
lib/rdoc/code_object/class_module.rb
@@ -309,8 +309,8 @@ def nesting_namespaces
309
310
def fully_qualified_nesting_namespaces
311
return nesting_namespaces if nesting_namespaces.length < 2
312
- @fqns ||= nesting_namespaces.map.with_index do |_, i|
313
- nesting_namespaces[0..i].join("::")
+ @fqns ||= nesting_namespaces.inject([]) do |list, n|
+ list << (list.empty? ? n : "#{list.last}::#{n}")
314
end
315
316
0 commit comments