From mboxrd@z Thu Jan 1 00:00:00 1970 Path: news.gmane.io!.POSTED.ciao.gmane.io!not-for-mail From: Phillip Lord Newsgroups: gmane.emacs.devel Subject: Re: dash.el [was: Re: Imports / inclusion of s.el into Emacs] Date: Wed, 13 May 2020 09:58:22 +0100 Message-ID: <87h7wkb49d.fsf@russet.org.uk> References: <0c88192c-3c33-46ed-95cb-b4c6928016e3@default> <87wo5mc04t.fsf@fastmail.fm> <873686bbl5.fsf@russet.org.uk> <87d07963ec.fsf@fastmail.fm> Mime-Version: 1.0 Content-Type: text/plain Injection-Info: ciao.gmane.io; posting-host="ciao.gmane.io:159.69.161.202"; logging-data="43137"; mail-complaints-to="usenet@ciao.gmane.io" User-Agent: Gnus/5.13 (Gnus v5.13) Emacs/27.0.91 (gnu/linux) Cc: Joost Kremers , emacs-devel@gnu.org To: Richard Stallman Original-X-From: emacs-devel-bounces+ged-emacs-devel=m.gmane-mx.org@gnu.org Wed May 13 10:58:59 2020 Return-path: Envelope-to: ged-emacs-devel@m.gmane-mx.org Original-Received: from lists.gnu.org ([209.51.188.17]) by ciao.gmane.io with esmtps (TLS1.2:ECDHE_RSA_AES_256_GCM_SHA384:256) (Exim 4.92) (envelope-from ) id 1jYnEB-000B6P-11 for ged-emacs-devel@m.gmane-mx.org; Wed, 13 May 2020 10:58:59 +0200 Original-Received: from localhost ([::1]:56798 helo=lists1p.gnu.org) by lists.gnu.org with esmtp (Exim 4.90_1) (envelope-from ) id 1jYnEA-0003CL-31 for ged-emacs-devel@m.gmane-mx.org; Wed, 13 May 2020 04:58:58 -0400 Original-Received: from eggs.gnu.org ([2001:470:142:3::10]:37274) by lists.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_256_GCM_SHA384:256) (Exim 4.90_1) (envelope-from ) id 1jYnDe-0002Ry-Rb for emacs-devel@gnu.org; Wed, 13 May 2020 04:58:26 -0400 Original-Received: from cloud103.planethippo.com ([78.129.138.110]:44340) by eggs.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_256_GCM_SHA384:256) (Exim 4.90_1) (envelope-from ) id 1jYnDd-00085d-TZ; Wed, 13 May 2020 04:58:26 -0400 DKIM-Signature: v=1; a=rsa-sha256; q=dns/txt; c=relaxed/relaxed; d=russet.org.uk; s=default; h=Content-Type:MIME-Version:Message-ID: In-Reply-To:Date:References:Subject:Cc:To:From:Sender:Reply-To: Content-Transfer-Encoding:Content-ID:Content-Description:Resent-Date: Resent-From:Resent-Sender:Resent-To:Resent-Cc:Resent-Message-ID:List-Id: List-Help:List-Unsubscribe:List-Subscribe:List-Post:List-Owner:List-Archive; bh=rbDXszJzPN/oLIezWQnRKjn+COao6N1Hbz5B1t66Vjs=; b=06GrB8VfvOKo+pWzNUTP8ytn3 CS+Ce9R4rghzvkUkPw5aBXKF+LgP2OHdiqNOFKLw9Yd0yQ3RCGw1Ug1bSDqqYRpcyq5iz/E5LNJkW sGB06E+VtjhmYcjIxlX6g+w4kKJ6pxmKoBSbIpu1NZxirBZGq5+3V2iWmCALMtNgq7nriUfF5SnGt F8V8l7i63iM8frVOuiaJxFlW/kEIJN+vckQnro2KI8Pcz1Cui9/b45SEloXiodRkzdh2WiWfLJoNt Rkgx3ar6jt2KiIsYrbk09eRO/CWw5OeTK+0H0ynA+bJhFvOkoOgm+QAA0cMJYg16SnYD/58K3/gch NlBe8nq1g==; Original-Received: from cpc142652-benw12-2-0-cust953.16-2.cable.virginm.net ([82.21.43.186]:54762 helo=russet.org.uk) by cloud103.planethippo.com with esmtpsa (TLS1.2) tls TLS_ECDHE_RSA_WITH_AES_256_GCM_SHA384 (Exim 4.93) (envelope-from ) id 1jYnDb-0002Bz-9O; Wed, 13 May 2020 09:58:23 +0100 In-Reply-To: (Richard Stallman's message of "Wed, 13 May 2020 00:00:55 -0400") X-AntiAbuse: This header was added to track abuse, please include it with any abuse report X-AntiAbuse: Primary Hostname - cloud103.planethippo.com X-AntiAbuse: Original Domain - gnu.org X-AntiAbuse: Originator/Caller UID/GID - [47 12] / [47 12] X-AntiAbuse: Sender Address Domain - russet.org.uk X-Get-Message-Sender-Via: cloud103.planethippo.com: authenticated_id: phillip.lord@russet.org.uk X-Authenticated-Sender: cloud103.planethippo.com: phillip.lord@russet.org.uk Received-SPF: none client-ip=78.129.138.110; envelope-from=phillip.lord@russet.org.uk; helo=cloud103.planethippo.com X-detected-operating-system: by eggs.gnu.org: First seen = 2020/05/13 04:52:38 X-ACL-Warn: Detected OS = Linux 3.11 and newer X-Spam_score_int: -20 X-Spam_score: -2.1 X-Spam_bar: -- X-Spam_report: (-2.1 / 5.0 requ) BAYES_00=-1.9, DKIM_SIGNED=0.1, DKIM_VALID=-0.1, DKIM_VALID_AU=-0.1, DKIM_VALID_EF=-0.1, URIBL_BLOCKED=0.001 autolearn=_AUTOLEARN X-Spam_action: no action X-BeenThere: emacs-devel@gnu.org X-Mailman-Version: 2.1.23 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-mx.org@gnu.org Original-Sender: "Emacs-devel" Xref: news.gmane.io gmane.emacs.devel:250104 Archived-At: Richard Stallman writes: > [[[ To any NSA and FBI agents reading my email: please consider ]]] > [[[ whether defending the US Constitution against all enemies, ]]] > [[[ foreign or domestic, requires you to follow Snowden's example. ]]] > > > In Clojure, a function literal is written with `#(...)`, and it > > supports `%n` for arguments, where n=1,2,3... (Actually, I don't > > know if Clojure supports `%10` and up or if it just goes up to > > `%9`, but I guess that doesn't matter much). A single `%` is > > synonymous with `%1`, which is used when there's only one > > argument. Also supported is `%&`, which is similar to `&rest > > ` in Elisp, being bound to a list containing the remaining > > arguments. > > This is rather shell-like. Can we find a nicer one? Suggest away. > It doesn't specify how many args the literal function should accept. > Maybe there is no need for that, but if we want to do that, how could we? You look for the maximum argument number #(list %) takes one argument #(list %1 %2) takes two #(list %1 %2 %3) takes three. > Is there ever a need for nested literal functions? To implement them > fully, we would want to use different arg names at each level. You don't. They are for short functions that you pass to something else, and for which you don't want to name parameters. For nesting, you use lambda. > What Lisp syntax would people suggest for this construct? > What is available? > > Does anyone think this is a bad idea? It's a small feature, and convenient for some things, but overuse makes the code messy. Phil