summaryrefslogtreecommitdiff
path: root/lib/irb/completion.rb
diff options
context:
space:
mode:
Diffstat (limited to 'lib/irb/completion.rb')
-rw-r--r--lib/irb/completion.rb8
1 files changed, 6 insertions, 2 deletions
diff --git a/lib/irb/completion.rb b/lib/irb/completion.rb
index 54e6526957..7fd69a0a09 100644
--- a/lib/irb/completion.rb
+++ b/lib/irb/completion.rb
@@ -178,8 +178,12 @@ module IRB
rescue Exception
name = ""
end
- next if name != "IRB::Context" and
- /^(IRB|SLex|RubyLex|RubyToken)/ =~ name
+ begin
+ next if name != "IRB::Context" and
+ /^(IRB|SLex|RubyLex|RubyToken)/ =~ name
+ rescue Exception
+ next
+ end
candidates.concat m.instance_methods(false).collect{|x| x.to_s}
}
candidates.sort!