comparison lisp/gnus/gnus-util.el @ 65846:a4e8d78ae3fb

Revision: miles@gnu.org--gnu-2005/emacs--cvs-trunk--0--patch-574 Merge from gnus--rel--5.10 2005-10-04 Reiner Steib <Reiner.Steib@gmx.de> * lisp/gnus/mm-url.el (mm-url-predefined-programs): Add switches for curl. * lisp/gnus/gnus-util.el (gnus-remove-duplicates): Remove. * lisp/gnus/nnmail.el (nnmail-article-group): Use mm-delete-duplicates instead of gnus-remove-duplicates. * lisp/gnus/message.el (message-remove-duplicates): Remove. (message-idna-to-ascii-rhs-1): Use mm-delete-duplicates instead of message-remove-duplicates. * lisp/gnus/mm-util.el (mm-delete-duplicates): Use `delete-dups' if available, else use implementation from `delete-dups'.
author Miles Bader <miles@gnu.org>
date Tue, 04 Oct 2005 22:51:06 +0000
parents c16795de963a
children 5ea0e0a7dd38 aa89c814f853
comparison
equal deleted inserted replaced
65845:3c2a85b1a338 65846:a4e8d78ae3fb
1035 (get-buffer gnus-group-buffer) 1035 (get-buffer gnus-group-buffer)
1036 (save-excursion 1036 (save-excursion
1037 (set-buffer gnus-group-buffer) 1037 (set-buffer gnus-group-buffer)
1038 (eq major-mode 'gnus-group-mode)))) 1038 (eq major-mode 'gnus-group-mode))))
1039 1039
1040 (defun gnus-remove-duplicates (list)
1041 (let (new)
1042 (while list
1043 (or (member (car list) new)
1044 (setq new (cons (car list) new)))
1045 (setq list (cdr list)))
1046 (nreverse new)))
1047
1048 (defun gnus-remove-if (predicate list) 1040 (defun gnus-remove-if (predicate list)
1049 "Return a copy of LIST with all items satisfying PREDICATE removed." 1041 "Return a copy of LIST with all items satisfying PREDICATE removed."
1050 (let (out) 1042 (let (out)
1051 (while list 1043 (while list
1052 (unless (funcall predicate (car list)) 1044 (unless (funcall predicate (car list))