Skip to content

Commit a883e14

Browse files
committed
Import r43006 from ruby trunk
> rdoc/constant.rb: workaround of NoMethodError > > * lib/rdoc/constant.rb (RDoc::Constant#documented?): workaround for > NoMethodError when the original of alias is not found.
1 parent 900de99 commit a883e14

File tree

1 file changed

+9
-1
lines changed

1 file changed

+9
-1
lines changed

lib/rdoc/constant.rb

Lines changed: 9 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -63,7 +63,15 @@ def == other
6363
# for a documented class or module.
6464

6565
def documented?
66-
super or is_alias_for && is_alias_for.documented?
66+
return true if super
67+
return false unless @is_alias_for
68+
case @is_alias_for
69+
when String then
70+
found = @store.find_class_or_module @is_alias_for
71+
return false unless found
72+
@is_alias_for = found
73+
end
74+
@is_alias_for.documented?
6775
end
6876

6977
##

0 commit comments

Comments
 (0)