From mboxrd@z Thu Jan 1 00:00:00 1970 Path: news.gmane.org!not-for-mail From: Oleh Newsgroups: gmane.emacs.devel Subject: Re: [PATCH] Clojure-like syntactic sugar for an anonymous function literal Date: Wed, 21 Jan 2015 23:37:31 +0100 Message-ID: References: <765b55dfa6d6df976352fc7c50b15c6f@samertm.com> NNTP-Posting-Host: plane.gmane.org Mime-Version: 1.0 Content-Type: text/plain; charset=UTF-8 X-Trace: ger.gmane.org 1421879873 3490 80.91.229.3 (21 Jan 2015 22:37:53 GMT) X-Complaints-To: usenet@ger.gmane.org NNTP-Posting-Date: Wed, 21 Jan 2015 22:37:53 +0000 (UTC) Cc: emacs-devel@gnu.org To: samer Original-X-From: emacs-devel-bounces+ged-emacs-devel=m.gmane.org@gnu.org Wed Jan 21 23:37:52 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 1YE3uJ-0000kA-D7 for ged-emacs-devel@m.gmane.org; Wed, 21 Jan 2015 23:37:51 +0100 Original-Received: from localhost ([::1]:50452 helo=lists.gnu.org) by lists.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1YE3uI-0003uh-LR for ged-emacs-devel@m.gmane.org; Wed, 21 Jan 2015 17:37:50 -0500 Original-Received: from eggs.gnu.org ([2001:4830:134:3::10]:41338) by lists.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1YE3u1-0003ta-T4 for emacs-devel@gnu.org; Wed, 21 Jan 2015 17:37:34 -0500 Original-Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.71) (envelope-from ) id 1YE3u0-0004bg-V1 for emacs-devel@gnu.org; Wed, 21 Jan 2015 17:37:33 -0500 Original-Received: from mail-wg0-x22c.google.com ([2a00:1450:400c:c00::22c]:35749) by eggs.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1YE3u0-0004bc-Na for emacs-devel@gnu.org; Wed, 21 Jan 2015 17:37:32 -0500 Original-Received: by mail-wg0-f44.google.com with SMTP id z12so8815792wgg.3 for ; Wed, 21 Jan 2015 14:37:32 -0800 (PST) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20120113; h=mime-version:in-reply-to:references:date:message-id:subject:from:to :cc:content-type; bh=ImAkM8hxrJ2Boc2TQ75YBdmCC+wJ4YW29T4KJpYFx+w=; b=SC8g2vTAA7lInSTjX33CYqBYU5fZ9KrEasl3HDNKsgh3RTX1/fyg3d6aTN2AX+z/XG o2aQxZUBHw25a6Aewth4RS/tbIidqgocoC7tdrGSmxXJHxIp4hRPS589jTdchuZlEPBj cYYnPLHmK9q/20RrPUdtvsxzYtV0iGtge+FC4LGuK4wqd7Epe6uJ8YJFHj7b8H3dWjCe RzZW8svupfv7E5/OwOaPDSOC3V4sKrEe/PBmD9PFhF1i3MFQFtjq3MAXh9EvQMnLSEq5 kANfYIvRsSbgG+UgtmSjAWV4LcycJoxxSxE5F2AcPuO6SYq4aSV+rXS0p6BSOVyC/VJS vfuw== X-Received: by 10.180.72.177 with SMTP id e17mr60225114wiv.42.1421879852023; Wed, 21 Jan 2015 14:37:32 -0800 (PST) Original-Received: by 10.27.137.137 with HTTP; Wed, 21 Jan 2015 14:37:31 -0800 (PST) In-Reply-To: <765b55dfa6d6df976352fc7c50b15c6f@samertm.com> X-detected-operating-system: by eggs.gnu.org: Error: Malformed IPv6 address (bad octet value). X-Received-From: 2a00:1450:400c:c00::22c 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:181537 Archived-At: Thanks for the input, > Some parts of short-lambda's documentation is unclear to me. I have no > experience with Clojure, so this is all from the perspective of someone new > to short-lambda. > >> 2. In the case when `%1' is the highest-ranking argument, it may be >> abbreviated to `%'. > > > When '%1' is the highest-ranking argument, that means '%1' is the only > argument, correct? I think this point will be more accessible if we don't > rely on the reader knowing or correctly inferring what "highest-ranking" > means, and use something along the lines of "when %1 is the only argument" > instead. Fixed with your suggestion. The point is not to mix % and e.g. %2. Clojure allows this, for not particular reason. >> 3. The lower-ranking arguments are auto-added, even if they are not >> present in FORMS. > > > Auto-added to the list of arguments? Similar to my above point, it will be > better if we can remove the dependency on "lower-ranking", and explain what > we mean by that term (something like "all arguments with a smaller number > than the argument with the largest number are included as part of the > lambda's arguments, even if they do not appear in STRUCTURE"). This means: (short-lambda (list %3)) => (lambda (%1 %2 %3) (list %3)) Oleh