From mboxrd@z Thu Jan 1 00:00:00 1970 Path: main.gmane.org!not-for-mail From: Denis Bueno Newsgroups: gmane.emacs.help Subject: Re: shorter form of frequently-seen lisp idiom? Date: Sun, 20 Feb 2005 19:07:11 -0500 Message-ID: <6dbd4d00050220160740636f@mail.gmail.com> References: Reply-To: Denis Bueno NNTP-Posting-Host: main.gmane.org Mime-Version: 1.0 Content-Type: text/plain; charset=ISO-8859-1 Content-Transfer-Encoding: quoted-printable X-Trace: sea.gmane.org 1108944523 11265 80.91.229.2 (21 Feb 2005 00:08:43 GMT) X-Complaints-To: usenet@sea.gmane.org NNTP-Posting-Date: Mon, 21 Feb 2005 00:08:43 +0000 (UTC) Original-X-From: help-gnu-emacs-bounces+geh-help-gnu-emacs=m.gmane.org@gnu.org Mon Feb 21 01:08:43 2005 Original-Received: from lists.gnu.org ([199.232.76.165]) by ciao.gmane.org with esmtp (Exim 4.43) id 1D317Y-0003jh-67 for geh-help-gnu-emacs@m.gmane.org; Mon, 21 Feb 2005 01:08:16 +0100 Original-Received: from localhost ([127.0.0.1] helo=lists.gnu.org) by lists.gnu.org with esmtp (Exim 4.43) id 1D31MQ-000174-Mb for geh-help-gnu-emacs@m.gmane.org; Sun, 20 Feb 2005 19:23:38 -0500 Original-Received: from mailman by lists.gnu.org with tmda-scanned (Exim 4.43) id 1D31Lz-00013J-32 for help-gnu-emacs@gnu.org; Sun, 20 Feb 2005 19:23:11 -0500 Original-Received: from exim by lists.gnu.org with spam-scanned (Exim 4.43) id 1D31Lt-0000zy-8E for help-gnu-emacs@gnu.org; Sun, 20 Feb 2005 19:23:05 -0500 Original-Received: from [199.232.76.173] (helo=monty-python.gnu.org) by lists.gnu.org with esmtp (Exim 4.43) id 1D31Lt-0000zU-2Z for help-gnu-emacs@gnu.org; Sun, 20 Feb 2005 19:23:05 -0500 Original-Received: from [64.233.184.207] (helo=wproxy.gmail.com) by monty-python.gnu.org with esmtp (Exim 4.34) id 1D316W-0002zJ-HV for help-gnu-emacs@gnu.org; Sun, 20 Feb 2005 19:07:12 -0500 Original-Received: by wproxy.gmail.com with SMTP id 36so1005746wra for ; Sun, 20 Feb 2005 16:07:11 -0800 (PST) DomainKey-Signature: a=rsa-sha1; q=dns; c=nofws; s=beta; d=gmail.com; h=received:message-id:date:from:reply-to:to:subject:in-reply-to:mime-version:content-type:content-transfer-encoding:references; b=XMG9WYOBMBIBqQ1dRr3Png6QrOHX4nqv9PnvDDTYT9TFaX+13WBpl9/Q5dhL+DxHbdYV+pG6kcLk+06pwnnSDV7hqirS5Hx0W7U0982uapGRCGf3Dwjd0spyZunFc3gOxTNhf4o/mpojYZO7gYhm1O4iLv1OmozXGspNVcReV2w= Original-Received: by 10.54.39.76 with SMTP id m76mr239096wrm; Sun, 20 Feb 2005 16:07:11 -0800 (PST) Original-Received: by 10.54.43.68 with HTTP; Sun, 20 Feb 2005 16:07:11 -0800 (PST) Original-To: help-gnu-emacs@gnu.org In-Reply-To: X-BeenThere: help-gnu-emacs@gnu.org X-Mailman-Version: 2.1.5 Precedence: list List-Id: Users list for the GNU Emacs text editor List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Original-Sender: help-gnu-emacs-bounces+geh-help-gnu-emacs=m.gmane.org@gnu.org Errors-To: help-gnu-emacs-bounces+geh-help-gnu-emacs=m.gmane.org@gnu.org X-MailScanner-To: geh-help-gnu-emacs@m.gmane.org Xref: main.gmane.org gmane.emacs.help:24205 X-Report-Spam: http://spam.gmane.org/gmane.emacs.help:24205 On Sun, 20 Feb 2005 00:55:53 +0100, David Kastrup wrote: > August writes: >=20 > > On l=F6r, 2005-02-19 at 19:43 +0100, David Kastrup wrote: > >> Joe Corneli writes: > >> > >> > Is there a shorter way to concatenate a list of strings > >> > than this? > >> > > >> > (eval (append (list 'concat) list-of-strings)) > >> > > >> > Or more generally, > >> > > >> > (eval (append (list 'function-that-acts-on-foos) list-of-foos)) Or even: (reduce #'function-that-acts-on-2-foos list-of-foos) Like: (reduce #'concat '("aoeu" "1234" "htns")) =3D> "aoeu1234htns" -- Denis Bueno