diff options
author | Kyrylo Silin <silin@kyrylo.org> | 2019-05-11 02:12:40 +0300 |
---|---|---|
committer | Kyrylo Silin <silin@kyrylo.org> | 2019-05-11 02:12:40 +0300 |
commit | 18bf21605ab7c8eeee253d05e508d402414ff0bb (patch) | |
tree | bfc44dfe5b2d01e4cf828033587c42c049c5a9a1 | |
parent | c123bce66116c2bb050ad47d0006e9df215ff3be (diff) | |
download | pry-18bf21605ab7c8eeee253d05e508d402414ff0bb.tar.gz |
Resolve config warnings about redefined method
I spotted "method redefined" warnings while working with Pry in another project,
which used `--warnings`. It would be nice to enable `--warnings` in RSpec,
however it's a bit tricky because our test suite has a lot of violations (on
purpose). We should strive to fix all possible warnings, though (especially
those that occur in `lib/`).
-rw-r--r-- | lib/pry/config.rb | 4 | ||||
-rw-r--r-- | lib/pry/pry_class.rb | 1 |
2 files changed, 1 insertions, 4 deletions
diff --git a/lib/pry/config.rb b/lib/pry/config.rb index 18626363..c42bab21 100644 --- a/lib/pry/config.rb +++ b/lib/pry/config.rb @@ -108,9 +108,6 @@ class Pry # @return [Integer] how many input/output lines to keep in memory attribute :memory_size - # @return [Proc] - attribute :control_d_handler - # @return [Proc] The proc that runs system commands attribute :system @@ -263,6 +260,7 @@ class Pry @custom_attrs = @custom_attrs.dup end + attr_reader :control_d_handler def control_d_handler=(value) proxy_proc = if value.arity == 2 diff --git a/lib/pry/pry_class.rb b/lib/pry/pry_class.rb index 3e8792c8..6a7b6a8c 100644 --- a/lib/pry/pry_class.rb +++ b/lib/pry/pry_class.rb @@ -16,7 +16,6 @@ class Pry attr_accessor :quiet attr_accessor :last_internal_error attr_accessor :config - attr_writer :history def_delegators :@plugin_manager, :plugins, :load_plugins, :locate_plugins |