[前][次][番号順一覧][スレッド一覧]

ruby-changes:67642

From: aycabta <ko1@a...>
Date: Mon, 6 Sep 2021 22:50:25 +0900 (JST)
Subject: [ruby-changes:67642] 966ed206a6 (master): [ruby/reline] Limit number of chars only when completion source text (pointer == -1)

https://git.ruby-lang.org/ruby.git/commit/?id=966ed206a6

From 966ed206a626ef19a5e4deaf77a6ee2a28453026 Mon Sep 17 00:00:00 2001
From: aycabta <aycabta@g...>
Date: Mon, 6 Sep 2021 22:50:10 +0900
Subject: [ruby/reline] Limit number of chars only when completion source text
 (pointer == -1)

https://github.com/ruby/reline/commit/1d7b603811
---
 lib/reline.rb | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)

diff --git a/lib/reline.rb b/lib/reline.rb
index 57a21b6..2bf62df 100644
--- a/lib/reline.rb
+++ b/lib/reline.rb
@@ -214,7 +214,7 @@ module Reline https://github.com/ruby/ruby/blob/trunk/lib/reline.rb#L214
         return nil
       end
       pre, target, post = retrieve_completion_block(true)
-      if target.nil? or target.empty? or target.size <= 3
+      if target.nil? or target.empty? or (completion_journey_data&.pointer == -1 and target.size <= 3)
         return nil
       end
       if completion_journey_data and completion_journey_data.list
-- 
cgit v1.1


--
ML: ruby-changes@q...
Info: http://www.atdot.net/~ko1/quickml/

[前][次][番号順一覧][スレッド一覧]