1
Fork 0
mirror of git://git.sv.gnu.org/emacs.git synced 2026-01-30 04:10:54 -08:00

(icomplete-completions): Don't use `predicate' with

a table of a different type than `candidates'.
This commit is contained in:
Stefan Monnier 2008-05-20 13:44:50 +00:00
parent fac97ac5a9
commit be91065ff4
2 changed files with 13 additions and 7 deletions

View file

@ -1,3 +1,8 @@
2008-05-20 Stefan Monnier <monnier@iro.umontreal.ca>
* icomplete.el (icomplete-completions): Don't use `predicate' with
a table of a different type than `candidates'.
2008-05-20 Roland Winkler <Roland.Winkler@physik.uni-erlangen.de>
* proced.el (proced-goal-header-re): Renamed from

View file

@ -291,13 +291,14 @@ are exhibited within the square braces.)"
;; `icomplete-prospects-length', there is no need for `catch'/`throw'.
(if (null comps)
(format " %sNo matches%s" open-bracket close-bracket)
(let* ((most-try (completion-try-completion
name
;; If the `comps' are 0-based, the result should be
;; the same with `comps'.
(if base-size candidates comps)
predicate
(length name)))
(let* ((most-try
(if (and base-size (> base-size 0))
(completion-try-completion
name candidates predicate (length name))
;; If the `comps' are 0-based, the result should be
;; the same with `comps'.
(completion-try-completion
name comps nil (length name))))
(most (if (consp most-try) (car most-try) (car comps)))
;; Compare name and most, so we can determine if name is
;; a prefix of most, or something else.