From mboxrd@z Thu Jan 1 00:00:00 1970 From: Samuel Wales Subject: Re: refile too slow Date: Tue, 24 Oct 2017 20:04:09 -0700 Message-ID: References: <87fuaxk63j.fsf@nicolasgoaziou.fr> Mime-Version: 1.0 Content-Type: text/plain; charset="UTF-8" Content-Transfer-Encoding: quoted-printable Return-path: Received: from eggs.gnu.org ([2001:4830:134:3::10]:39554) by lists.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1e7BzI-0002YW-EX for emacs-orgmode@gnu.org; Tue, 24 Oct 2017 23:04:13 -0400 Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.71) (envelope-from ) id 1e7BzH-0006oF-Do for emacs-orgmode@gnu.org; Tue, 24 Oct 2017 23:04:12 -0400 Received: from mail-io0-x231.google.com ([2607:f8b0:4001:c06::231]:50381) by eggs.gnu.org with esmtps (TLS1.0:RSA_AES_128_CBC_SHA1:16) (Exim 4.71) (envelope-from ) id 1e7BzH-0006nh-9L for emacs-orgmode@gnu.org; Tue, 24 Oct 2017 23:04:11 -0400 Received: by mail-io0-x231.google.com with SMTP id 97so26074070iok.7 for ; Tue, 24 Oct 2017 20:04:10 -0700 (PDT) In-Reply-To: List-Id: "General discussions about Org-mode." List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: emacs-orgmode-bounces+geo-emacs-orgmode=m.gmane.org@gnu.org Sender: "Emacs-orgmode" To: Nicolas Goaziou Cc: emacs-orgmode@gnu.org On 10/5/17, Samuel Wales 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) > --=20 The Kafka Pandemic: The disease DOES progress. MANY people have died from it. And ANYBODY can get it at any time. "You=E2=80=99ve really gotta quit this and get moving, because this is murd= er by neglect." --- .