From ebb15cc6c17e33b030b511fff8b5722a8238ace5 Mon Sep 17 00:00:00 2001 From: aycabta Date: Mon, 13 May 2019 02:33:29 +0900 Subject: [PATCH] Reline.completion_proc= should raise ArgumentError When the value is not Proc. --- lib/reline.rb | 1 + 1 file changed, 1 insertion(+) diff --git a/lib/reline.rb b/lib/reline.rb index fbe39f54fd..9773f5cb3b 100644 --- a/lib/reline.rb +++ b/lib/reline.rb @@ -67,6 +67,7 @@ module Reline @@completion_proc end def self.completion_proc=(p) + raise ArgumentError unless p.is_a?(Proc) @@completion_proc = p end