mirror of
https://git.savannah.gnu.org/git/emacs.git
synced 2024-12-24 10:38:38 +00:00
Don't replace user input when completion prefix is empty (Bug#18951)
* lisp/pcomplete.el (pcomplete-parse-arguments): Only replace user input if we produced a non-empty common completion stub.
This commit is contained in:
parent
ec6cf35c5f
commit
5d744e032f
@ -772,7 +772,7 @@ this is `comint-dynamic-complete-functions'."
|
|||||||
(setq c (cdr c)))
|
(setq c (cdr c)))
|
||||||
(setq pcomplete-stub (substring common-stub 0 len)
|
(setq pcomplete-stub (substring common-stub 0 len)
|
||||||
pcomplete-autolist t)
|
pcomplete-autolist t)
|
||||||
(when (and begin (not pcomplete-show-list))
|
(when (and begin (> len 0) (not pcomplete-show-list))
|
||||||
(delete-region begin (point))
|
(delete-region begin (point))
|
||||||
(pcomplete-insert-entry "" pcomplete-stub))
|
(pcomplete-insert-entry "" pcomplete-stub))
|
||||||
(throw 'pcomplete-completions completions))
|
(throw 'pcomplete-completions completions))
|
||||||
|
Loading…
Reference in New Issue
Block a user