emacs-elpa-diffs
[Top][All Lists]
Advanced

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

[elpa] master 78be161 165/348: Fix alist and :predicate interaction


From: Oleh Krehel
Subject: [elpa] master 78be161 165/348: Fix alist and :predicate interaction
Date: Sat, 8 Apr 2017 11:03:48 -0400 (EDT)

branch: master
commit 78be1618a40baba1cddc7e5a691dbe7f30c0b167
Author: Oleh Krehel <address@hidden>
Commit: Oleh Krehel <address@hidden>

    Fix alist and :predicate interaction
    
    * ivy.el (ivy--reset-state): The 'idx text property refers to the full
      alist collection, so the full one should fully match :predicate.
    
    Fixes #657
---
 ivy.el | 5 ++++-
 1 file changed, 4 insertions(+), 1 deletion(-)

diff --git a/ivy.el b/ivy.el
index 863bb86..ed5eed5 100644
--- a/ivy.el
+++ b/ivy.el
@@ -1549,7 +1549,10 @@ This is useful for recursive `ivy-read'."
                                       (cl-sort
                                        (copy-sequence collection)
                                        sort-fn))))
-               (setq coll (all-completions "" collection predicate)))
+               (setq collection
+                     (setf (ivy-state-collection ivy-last)
+                           (cl-remove-if-not predicate collection)))
+               (setq coll (all-completions "" collection)))
              (let ((i 0))
                (ignore-errors
                  ;; cm can be read-only



reply via email to

[Prev in Thread] Current Thread [Next in Thread]