+2011-07-12 Lars Magne Ingebrigtsen <larsi@gnus.org>
+
+ * subr.el (remove-duplicates): Remove; `delete-dups' is sufficient.
+
+ * dired-x.el (dired-guess-default): Use `delete-dups'.
+
2011-07-12 Chong Yidong <cyd@stupidchicken.com>
* dired.el (dired-mark-prompt):
;; Return commands or nil if flist is still non-nil.
;; Evaluate the commands in order that any logical testing will be done.
(if (cdr cmds)
- (remove-duplicates (mapcar #'eval cmds))
+ (delete-dups (mapcar #'eval cmds))
(eval (car cmds))))) ; single command
(defun dired-guess-shell-command (prompt files)
(progn
;; If we reload subr.el after having loaded CL, be careful not to
;; overwrite CL's extended definition of `dolist', `dotimes',
- ;; `declare', `push', `pop' and `remove-duplicates'.
+ ;; `declare', `push' and `pop'.
(defmacro dolist (spec &rest body)
"Loop over a list.
Treated as a declaration when used at the right place in a
`defmacro' form. \(See Info anchor `(elisp)Definition of declare'.)"
nil)
-
-(defun remove-duplicates (list)
- "Return a copy of LIST with all duplicate elements removed."
- (let ((result nil))
- (while list
- (unless (member (car list) result)
- (push (car list) result))
- (pop list))
- (nreverse result)))
))
(defmacro ignore-errors (&rest body)