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 79e0ff9 commit 3fbadbaCopy full SHA for 3fbadba
lib/rdoc/class_module.rb
@@ -12,8 +12,9 @@ class RDoc::ClassModule < RDoc::Context
12
# Creates a new ClassModule with +name+ with optional +superclass+
13
14
def initialize(name, superclass = 'Object')
15
- @name = name
16
@diagram = nil
+ @full_name = nil
17
+ @name = name
18
@superclass = superclass
19
super()
20
end
@@ -31,11 +32,11 @@ def find_class_named(name)
31
32
# Return the fully qualified name of this class or module
33
34
def full_name
- if RDoc::ClassModule === @parent then
35
- "#{@parent.full_name}::#{@name}"
36
- else
37
- @name
38
- end
+ @full_name ||= if RDoc::ClassModule === @parent then
+ "#{@parent.full_name}::#{@name}"
+ else
+ @name
39
+ end
40
41
42
##
0 commit comments