From mboxrd@z Thu Jan 1 00:00:00 1970 Path: news.gmane.org!not-for-mail From: David Kastrup Newsgroups: gmane.emacs.devel Subject: Re: [PATCH] Clojure-like syntactic sugar for an anonymous function literal Date: Thu, 22 Jan 2015 11:20:05 +0100 Message-ID: <87a91bf76y.fsf@fencepost.gnu.org> References: <54C05269.7050602@dancol.org> <87oaprfa3t.fsf@fencepost.gnu.org> <877fwfunnz.fsf@uwakimon.sk.tsukuba.ac.jp> NNTP-Posting-Host: plane.gmane.org Mime-Version: 1.0 Content-Type: text/plain X-Trace: ger.gmane.org 1421922024 22871 80.91.229.3 (22 Jan 2015 10:20:24 GMT) X-Complaints-To: usenet@ger.gmane.org NNTP-Posting-Date: Thu, 22 Jan 2015 10:20:24 +0000 (UTC) Cc: Oleh , "emacs-devel@gnu.org" To: "Stephen J. Turnbull" Original-X-From: emacs-devel-bounces+ged-emacs-devel=m.gmane.org@gnu.org Thu Jan 22 11:20:24 2015 Return-path: Envelope-to: ged-emacs-devel@m.gmane.org Original-Received: from lists.gnu.org ([208.118.235.17]) by plane.gmane.org with esmtp (Exim 4.69) (envelope-from ) id 1YEEsA-0001r3-9x for ged-emacs-devel@m.gmane.org; Thu, 22 Jan 2015 11:20:22 +0100 Original-Received: from localhost ([::1]:52154 helo=lists.gnu.org) by lists.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1YEEs9-00027D-Ib for ged-emacs-devel@m.gmane.org; Thu, 22 Jan 2015 05:20:21 -0500 Original-Received: from eggs.gnu.org ([2001:4830:134:3::10]:54590) by lists.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1YEErv-00025x-Bp for emacs-devel@gnu.org; Thu, 22 Jan 2015 05:20:08 -0500 Original-Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.71) (envelope-from ) id 1YEEru-00012U-8H for emacs-devel@gnu.org; Thu, 22 Jan 2015 05:20:07 -0500 Original-Received: from fencepost.gnu.org ([2001:4830:134:3::e]:51532) by eggs.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1YEEru-000121-5i for emacs-devel@gnu.org; Thu, 22 Jan 2015 05:20:06 -0500 Original-Received: from localhost ([127.0.0.1]:58707 helo=lola) by fencepost.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1YEErt-0001fx-N0; Thu, 22 Jan 2015 05:20:06 -0500 Original-Received: by lola (Postfix, from userid 1000) id 4AA40DF3F4; Thu, 22 Jan 2015 11:20:05 +0100 (CET) In-Reply-To: <877fwfunnz.fsf@uwakimon.sk.tsukuba.ac.jp> (Stephen J. Turnbull's message of "Thu, 22 Jan 2015 19:15:12 +0900") User-Agent: Gnus/5.13 (Gnus v5.13) Emacs/25.0.50 (gnu/linux) X-detected-operating-system: by eggs.gnu.org: Error: Malformed IPv6 address (bad octet value). X-Received-From: 2001:4830:134:3::e X-BeenThere: emacs-devel@gnu.org X-Mailman-Version: 2.1.14 Precedence: list List-Id: "Emacs development discussions." List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: emacs-devel-bounces+ged-emacs-devel=m.gmane.org@gnu.org Original-Sender: emacs-devel-bounces+ged-emacs-devel=m.gmane.org@gnu.org Xref: news.gmane.org gmane.emacs.devel:181578 Archived-At: "Stephen J. Turnbull" writes: > Oleh writes: > > > The most popular library in MELPA, https://github.com/magnars/dash.el, > > implements it (for a long time) like this: > > > > (--map (* it it) '(1 2 3)) > > ;; => (1 4 9) > > > > With my approach, it's: > > > > (mapcar #(* % %) '(1 2 3)) > > ;; => (1 4 9) > > That looks almost like Perl! Now I'm -2. Just require dash. > > Personally, I don't see a huge advantage to anonymous functions > anyway, not even in an interactive repl, They are useful for calculated bindings. Context-sensitive mouse-overs or active links, regular bindings (I am currently working on some private project involving keybindings to keys on an accordion keyboard, and little surprisingly those are all different but all of the same kind). Stuff like that. -- David Kastrup