diff options
author | Stefan Kangas <stefan@marxist.se> | 2021-04-05 15:14:19 +0200 |
---|---|---|
committer | Stefan Kangas <stefan@marxist.se> | 2021-04-05 15:14:19 +0200 |
commit | 6686a31591d2d22a4d1c7b6e68a618823186c48e (patch) | |
tree | f1ede142778839c1e9ee98a13607681805767bbe /lisp/pcomplete.el | |
parent | 20f7fa691b7c2859b96550d9ccb326bf394e160d (diff) | |
download | emacs-6686a31591d2d22a4d1c7b6e68a618823186c48e.tar.gz |
Remove local uniquify functions in favour of seq-uniq
* lisp/emacs-lisp/seq.el (seq-uniq): Add autoload cookie.
* lisp/pcomplete.el: (pcomplete-uniquify-list): Use seq-uniq.
* lisp/eshell/esh-util.el (eshell-uniqify-list)
(eshell-uniquify-list):
* lisp/nxml/rng-util.el (rng-uniquify-equal):
* lisp/progmodes/idlwave.el (idlwave-uniquify):
* lisp/textmodes/artist.el (artist-uniq): Make into obsolete
function aliases for seq-uniq. Update callers.
* lisp/nxml/rng-util.el (rng-uniquify-eq): Make obsolete in favor
of seq-uniq. Update callers.
Diffstat (limited to 'lisp/pcomplete.el')
-rw-r--r-- | lisp/pcomplete.el | 15 |
1 files changed, 3 insertions, 12 deletions
diff --git a/lisp/pcomplete.el b/lisp/pcomplete.el index b648ecf0986..bffdcaa2de0 100644 --- a/lisp/pcomplete.el +++ b/lisp/pcomplete.el @@ -1260,18 +1260,9 @@ If specific documentation can't be given, be generic." (defun pcomplete-uniquify-list (l) "Sort and remove multiples in L." - (setq l (sort l 'string-lessp)) - (let ((m l)) - (while m - (while (and (cdr m) - (string= (car m) - (cadr m))) - (setcdr m (cddr m))) - (setq m (cdr m)))) - l) -(define-obsolete-function-alias - 'pcomplete-uniqify-list - 'pcomplete-uniquify-list "27.1") + (setq l (sort l #'string-lessp)) + (seq-uniq l)) +(define-obsolete-function-alias 'pcomplete-uniqify-list #'pcomplete-uniquify-list "27.1") (defun pcomplete-process-result (cmd &rest args) "Call CMD using `call-process' and return the simplest result." |