mirror of
https://github.com/pry/pry.git
synced 2022-11-09 12:35:05 -05:00
Really ignore old Argon2::Password and the like in the methods scan
This commit is contained in:
parent
67a497fa1c
commit
6a29ed8342
2 changed files with 13 additions and 1 deletions
|
@ -170,7 +170,7 @@ class Pry::InputCompleter
|
|||
candidates = []
|
||||
to_ignore = ignored_modules
|
||||
ObjectSpace.each_object(Module){|m|
|
||||
next if to_ignore.include?(m) rescue true
|
||||
next if (to_ignore.include?(m) rescue true)
|
||||
|
||||
# jruby doesn't always provide #instance_methods() on each
|
||||
# object.
|
||||
|
|
|
@ -224,4 +224,16 @@ describe Pry::InputCompleter do
|
|||
require 'irb'
|
||||
completer_test(self, nil, false).call("[].size.parse_printf_format")
|
||||
end
|
||||
|
||||
it 'ignores methods from modules that override Object#hash incompatibly' do
|
||||
_m = Module.new do
|
||||
def self.hash(a, b)
|
||||
end
|
||||
|
||||
def aaaa
|
||||
end
|
||||
end
|
||||
|
||||
completer_test(self, nil, false).call("[].size.aaaa")
|
||||
end
|
||||
end
|
||||
|
|
Loading…
Add table
Reference in a new issue