summaryrefslogtreecommitdiff
path: root/lib/irb
diff options
context:
space:
mode:
Diffstat (limited to 'lib/irb')
-rw-r--r--lib/irb/completion.rb5
1 files changed, 3 insertions, 2 deletions
diff --git a/lib/irb/completion.rb b/lib/irb/completion.rb
index e51a92adc1..ac227fee90 100644
--- a/lib/irb/completion.rb
+++ b/lib/irb/completion.rb
@@ -137,9 +137,10 @@ module IRB
else
# func1.func2
candidates = []
+ name = m.name rescue ""
ObjectSpace.each_object(Module){|m|
- next if m.name != "IRB::Context" and
- /^(IRB|SLex|RubyLex|RubyToken)/ =~ m.name
+ next if name != "IRB::Context" and
+ /^(IRB|SLex|RubyLex|RubyToken)/ =~ name
candidates.concat m.instance_methods(false)
}
candidates.sort!