emacs-diffs
[Top][All Lists]
Advanced

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

[Emacs-diffs] /srv/bzr/emacs/trunk r105124: Remove `remove-duplicates',


From: Lars Magne Ingebrigtsen
Subject: [Emacs-diffs] /srv/bzr/emacs/trunk r105124: Remove `remove-duplicates', since `delete-dups' is sufficient.
Date: Tue, 12 Jul 2011 09:26:48 +0200
User-agent: Bazaar (2.3.1)

------------------------------------------------------------
revno: 105124
committer: Lars Magne Ingebrigtsen <address@hidden>
branch nick: trunk
timestamp: Tue 2011-07-12 09:26:48 +0200
message:
  Remove `remove-duplicates', since `delete-dups' is sufficient.
modified:
  lisp/ChangeLog
  lisp/dired-x.el
  lisp/subr.el
=== modified file 'lisp/ChangeLog'
--- a/lisp/ChangeLog    2011-07-12 02:54:26 +0000
+++ b/lisp/ChangeLog    2011-07-12 07:26:48 +0000
@@ -1,3 +1,9 @@
+2011-07-12  Lars Magne Ingebrigtsen  <address@hidden>
+
+       * subr.el (remove-duplicates): Remove; `delete-dups' is sufficient.
+
+       * dired-x.el (dired-guess-default): Use `delete-dups'.
+
 2011-07-12  Chong Yidong  <address@hidden>
 
        * dired.el (dired-mark-prompt):

=== modified file 'lisp/dired-x.el'
--- a/lisp/dired-x.el   2011-07-11 13:46:46 +0000
+++ b/lisp/dired-x.el   2011-07-12 07:26:48 +0000
@@ -1103,7 +1103,7 @@
     ;; 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)

=== modified file 'lisp/subr.el'
--- a/lisp/subr.el      2011-07-11 13:33:05 +0000
+++ b/lisp/subr.el      2011-07-12 07:26:48 +0000
@@ -173,7 +173,7 @@
     (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.
@@ -250,15 +250,6 @@
 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)


reply via email to

[Prev in Thread] Current Thread [Next in Thread]