diff options
author | aycabta <aycabta@gmail.com> | 2020-05-13 07:21:44 +0900 |
---|---|---|
committer | aycabta <aycabta@gmail.com> | 2020-05-14 12:27:33 +0900 |
commit | 68a7c8ad5781ecfa12cf7b512b5745ba1a78bdcd (patch) | |
tree | 742569de493316a5f1e0fbac115887297a5e550a /lib/reline.rb | |
parent | ca1f6b3eae076fefe1b1c042a9191894c6773669 (diff) |
Reline callbacks can take nil
Diffstat (limited to 'lib/reline.rb')
-rw-r--r-- | lib/reline.rb | 10 |
1 files changed, 5 insertions, 5 deletions
diff --git a/lib/reline.rb b/lib/reline.rb index 1537ee7e69..91863ebfea 100644 --- a/lib/reline.rb +++ b/lib/reline.rb @@ -98,22 +98,22 @@ module Reline end def completion_proc=(p) - raise ArgumentError unless p.respond_to?(:call) + raise ArgumentError unless p.respond_to?(:call) or p.nil? @completion_proc = p end def output_modifier_proc=(p) - raise ArgumentError unless p.respond_to?(:call) + raise ArgumentError unless p.respond_to?(:call) or p.nil? @output_modifier_proc = p end def prompt_proc=(p) - raise ArgumentError unless p.respond_to?(:call) + raise ArgumentError unless p.respond_to?(:call) or p.nil? @prompt_proc = p end def auto_indent_proc=(p) - raise ArgumentError unless p.respond_to?(:call) + raise ArgumentError unless p.respond_to?(:call) or p.nil? @auto_indent_proc = p end @@ -122,7 +122,7 @@ module Reline end def dig_perfect_match_proc=(p) - raise ArgumentError unless p.respond_to?(:call) + raise ArgumentError unless p.respond_to?(:call) or p.nil? @dig_perfect_match_proc = p end |