1
0
Fork 0
mirror of https://github.com/ruby/ruby.git synced 2022-11-09 12:17:21 -05:00

Implicitly define classes in 'class <<ClassName' if we haven't come across them before

git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@5095 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
This commit is contained in:
dave 2003-12-03 14:40:44 +00:00
parent 3d9ba0390c
commit ad27a14136

View file

@ -1733,7 +1733,11 @@ module RDoc
if name == container.name
parse_statements(container, SINGLE, &block)
else
other = TopLevel.find_class_named(name) || Context.new
other = TopLevel.find_class_named(name)
unless other
other = @top_level.add_class(NormalClass, name, nil)
other.record_location(@top_level)
end
parse_statements(other, SINGLE, &block)
end
end