diff options
author | Eli Zaretskii <eliz@gnu.org> | 2023-07-02 09:16:58 +0300 |
---|---|---|
committer | Eli Zaretskii <eliz@gnu.org> | 2023-07-02 09:16:58 +0300 |
commit | 37ed3d15f38339400eba67647c87fad85de3a384 (patch) | |
tree | 765df1e0a93785c65e1f6b22b3f21e3049ac61f5 /lisp/minibuffer.el | |
parent | 15ff87617772c2a2c3d8a3a1e2ed7f96e527ad9e (diff) | |
download | emacs-37ed3d15f38339400eba67647c87fad85de3a384.tar.gz emacs-37ed3d15f38339400eba67647c87fad85de3a384.tar.bz2 emacs-37ed3d15f38339400eba67647c87fad85de3a384.zip |
Avoid errors in completion due to 'completion-regexp-list'
* doc/lispref/minibuf.texi (Basic Completion):
* src/minibuf.c (syms_of_minibuf) <completion-regexp-list>:
Document that global non-nil settings of 'completion-regexp-list'
are not safe.
* lisp/minibuffer.el (completion-pcm--merge-completions): Avoid
errors in 'try-completion' when PREFIX is nil. (Bug#64351)
Diffstat (limited to 'lisp/minibuffer.el')
-rw-r--r-- | lisp/minibuffer.el | 3 |
1 files changed, 2 insertions, 1 deletions
diff --git a/lisp/minibuffer.el b/lisp/minibuffer.el index 4aa1ab3e890..3e30b68d5e9 100644 --- a/lisp/minibuffer.el +++ b/lisp/minibuffer.el @@ -4027,7 +4027,8 @@ the same set of elements." (setq ccs (nreverse ccs)) (let* ((prefix (try-completion fixed comps)) (unique (or (and (eq prefix t) (setq prefix fixed)) - (eq t (try-completion prefix comps))))) + (and (stringp prefix) + (eq t (try-completion prefix comps)))))) (unless (or (eq elem 'prefix) (equal prefix "")) (push prefix res)) |