On 10/5/17, Samuel Wales <samolog...@gmail.com> wrote: > delete-dups seems suspicious but what do i know. i wonder if > cl-delete-duplicates is more efficient.
perhaps it has been made more efficient in new emacs versions than 24? > > (defun delete-dups (list) > "Destructively remove `equal' duplicates from LIST. > Store the result in LIST and return it. LIST must be a proper list. > Of several `equal' occurrences of an element in LIST, the first > one is kept." > (let ((tail list)) > (while tail > (setcdr tail (delete (car tail) (cdr tail))) > (setq tail (cdr tail)))) > list) > -- The Kafka Pandemic: <http://thekafkapandemic.blogspot.com> The disease DOES progress. MANY people have died from it. And ANYBODY can get it at any time. "You’ve really gotta quit this and get moving, because this is murder by neglect." --- <http://www.meaction.net/2017/02/03/pwme-people-with-me-are-being-murdered-by-neglect>.