From debbugs-submit-bounces@debbugs.gnu.org Mon Aug 01 13:07:06 2022 Received: (at submit) by debbugs.gnu.org; 1 Aug 2022 17:07:06 +0000 Received: from localhost ([127.0.0.1]:41530 helo=debbugs.gnu.org) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1oIYsj-0006Gg-Hz for submit@debbugs.gnu.org; Mon, 01 Aug 2022 13:07:05 -0400 Received: from lists.gnu.org ([209.51.188.17]:53020) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1oIYsd-0006GC-Pb for submit@debbugs.gnu.org; Mon, 01 Aug 2022 13:07:03 -0400 Received: from eggs.gnu.org ([2001:470:142:3::10]:55492) by lists.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_256_GCM_SHA384:256) (Exim 4.90_1) (envelope-from ) id 1oIYsd-00015h-J9 for bug-gnu-emacs@gnu.org; Mon, 01 Aug 2022 13:06:59 -0400 Received: from mail-ed1-x532.google.com ([2a00:1450:4864:20::532]:44592) by eggs.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_128_GCM_SHA256:128) (Exim 4.90_1) (envelope-from ) id 1oIYsb-0004IU-Og for bug-gnu-emacs@gnu.org; Mon, 01 Aug 2022 13:06:59 -0400 Received: by mail-ed1-x532.google.com with SMTP id i13so14569317edj.11 for ; Mon, 01 Aug 2022 10:06:56 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20210112; h=from:to:subject:date:message-id:user-agent:mime-version; bh=0pQuMitzs4gX9XOP+pTmDDnodhFuoZOxmgCE98SIO7k=; b=EaVtoqzg4ekhnnajuXLMejh0NQYxvRJE6KKOu9nwy1wsFjD4IgyMTuCLZQD9FWPel9 v0+xzlFksvG8uc/wKVwh2M5OiIn9m6egjVV3/GU+1LnsDGdjBb2c1qU3efblWldL7C2V OC6G13FJjKlJdLdoJSIZVVYQ4eKmfI4tXoghrsX9Cc/RJ+IEp0eU6/FDISnZ/YR2fZ1U cHuiT0l+z3hlPgekbXM8bfOl4iDXxLjUNB3SwFwtpk/4FDYi2DdKrNBMqMg0YFW6ROH4 gEXSLzq2UWMiRKqy48c18iwZe7wCiQzWR/56T82d2NZLCk8vaxwlgAZDNwjFL2S9A7zO x05Q== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20210112; h=x-gm-message-state:from:to:subject:date:message-id:user-agent :mime-version; bh=0pQuMitzs4gX9XOP+pTmDDnodhFuoZOxmgCE98SIO7k=; b=p+hTxUszuHoR+Q32NjSpT2f84so58w/P7F/viMushzRvqEKFlO3zVg+q6wQ0EZ8WO2 WuTROpZwduB0/nquICd/xIjJ1VzP6IrwHOEOOm6GKMdVX2t1kBqrh1g/x1t3MoGrfhdf CS91nIFXF0f8ZfqWffmPGLeEYYUGBC2j51riCMH97dEOzro+DgndfgCgNvwjCzrzwGIb wMWF/ZCvEz3/DjuPJyxhYY42Z341xR+uPl/RQdZAp7iIlsbZhb+TbF+BcRg4gRJPgiBX kRDyZCQzezMv7AZP0COsgGdtm6qu0AOYQSlbfVpWy15vxGdPZLDqet0/jZBNJ94CLa94 ZNwg== X-Gm-Message-State: ACgBeo1pfzPUQjhmxyo2/ZnFup2TaV+UyWr20IqNO/S/5j5rnqvu8s9H LCYUcYxOXQqHBXSJx1zvCqIDoHNT+jU= X-Google-Smtp-Source: AA6agR4unwrRgG81Yff+lZ6ETCsFY69jHIvhvpMmMUryHrkiE0ybfQCw9vDphnW1Jcg8WCMLigOb6Q== X-Received: by 2002:a05:6402:5190:b0:43d:da02:566a with SMTP id q16-20020a056402519000b0043dda02566amr1864508edd.187.1659373614916; Mon, 01 Aug 2022 10:06:54 -0700 (PDT) Received: from ars3 ([2a02:8109:8ac0:56d0::11cf]) by smtp.gmail.com with ESMTPSA id x25-20020aa7d6d9000000b0043bc4b28464sm7078554edr.34.2022.08.01.10.06.53 for (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Mon, 01 Aug 2022 10:06:54 -0700 (PDT) From: Augusto Stoffel To: bug-gnu-emacs@gnu.org Subject: 29.0.50; [PATCH] Add thread-as macro Date: Mon, 01 Aug 2022 19:06:53 +0200 Message-ID: <87h72vq4eq.fsf@gmail.com> User-Agent: Gnus/5.13 (Gnus v5.13) Emacs/29.0.50 (gnu/linux) MIME-Version: 1.0 Content-Type: multipart/mixed; boundary="=-=-=" Received-SPF: pass client-ip=2a00:1450:4864:20::532; envelope-from=arstoffel@gmail.com; helo=mail-ed1-x532.google.com 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, FREEMAIL_FROM=0.001, RCVD_IN_DNSWL_NONE=-0.0001, SPF_HELO_NONE=0.001, SPF_PASS=-0.001, T_SCC_BODY_TEXT_LINE=-0.01 autolearn=ham autolearn_force=no X-Spam_action: no action X-Spam-Score: -1.3 (-) X-Debbugs-Envelope-To: submit X-BeenThere: debbugs-submit@debbugs.gnu.org X-Mailman-Version: 2.1.18 Precedence: list List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: debbugs-submit-bounces@debbugs.gnu.org Sender: "Debbugs-submit" X-Spam-Score: -2.3 (--) --=-=-= Content-Type: text/plain; charset=utf-8 Content-Transfer-Encoding: quoted-printable It has been noted many times that threading macros are not as useful in Emacs Lisp because the APIs are not always consistent with regard to the ordering of arguments. A =E2=80=9Cthread-as=E2=80=9D macro on the lines of= Clojure's 'as->' [1] would address this difficulty. The signature of the Clojure macro is (as-> expr name & forms), which looks a bit odd to me. Here I've changed this so the lexical variable (name) comes before the initial value (expr). Also, unlike thread-first and thread-last, in the attached version of the macro there's no magic whereby an element of FORMS which is a symbol, say fun, is turned into a function call, i.e. (fun name). In other words, (thread-as x 1 1+) returns the symbol 1+. Clojure behaves the same. I'm not necessarily against changing the macro so that the above example returns 2, but I don't see a good reason to do so either; for one thing, the example gives a byte-compilation warning (unused lexical variable x). [1]: https://clojure.github.io/clojure/clojure.core-api.html#clojure.core/a= s-%3E --=-=-= Content-Type: text/x-patch; charset=utf-8 Content-Disposition: attachment; filename=0001-Add-thread-as-macro.patch Content-Transfer-Encoding: quoted-printable >From c044cf5891638cd0095db091e86303d683cf380d Mon Sep 17 00:00:00 2001 From: Augusto Stoffel Date: Mon, 1 Aug 2022 15:59:53 +0200 Subject: [PATCH] Add thread-as macro * lisp/subr-x.el (thread-as): New macro. --- lisp/emacs-lisp/subr-x.el | 17 +++++++++++++++++ 1 file changed, 17 insertions(+) diff --git a/lisp/emacs-lisp/subr-x.el b/lisp/emacs-lisp/subr-x.el index d5d7bfeb6f..916ed39a03 100644 --- a/lisp/emacs-lisp/subr-x.el +++ b/lisp/emacs-lisp/subr-x.el @@ -81,6 +81,23 @@ thread-last threading." (declare (indent 0) (debug thread-first)) `(internal--thread-argument nil ,@forms)) + +(defmacro thread-as (var &rest forms) + "Successively bind VAR to the result of evaluating each of the FORMS. +Return the last computed value. + +Example: + (thread-as x + 4 + (- 10 x) + (/ x 2)) + =E2=87=92 3" + (declare (indent 1)) + (if forms + `(let ((,var ,(car forms))) + (thread-as ,var ,@(cdr forms))) + var)) + (defsubst hash-table-empty-p (hash-table) "Check whether HASH-TABLE is empty (has 0 elements)." (zerop (hash-table-count hash-table))) --=20 2.37.1 --=-=-=-- From debbugs-submit-bounces@debbugs.gnu.org Mon Aug 01 23:41:00 2022 Received: (at 56875) by debbugs.gnu.org; 2 Aug 2022 03:41:00 +0000 Received: from localhost ([127.0.0.1]:41965 helo=debbugs.gnu.org) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1oIimC-0001V5-59 for submit@debbugs.gnu.org; Mon, 01 Aug 2022 23:41:00 -0400 Received: from eggs.gnu.org ([209.51.188.92]:56590) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1oIimA-0001Ur-Sk for 56875@debbugs.gnu.org; Mon, 01 Aug 2022 23:40:59 -0400 Received: from fencepost.gnu.org ([2001:470:142:3::e]:36592) by eggs.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_256_GCM_SHA384:256) (Exim 4.90_1) (envelope-from ) id 1oIim5-0006Dl-LS; Mon, 01 Aug 2022 23:40:53 -0400 DKIM-Signature: v=1; a=rsa-sha256; q=dns/txt; c=relaxed/relaxed; d=gnu.org; s=fencepost-gnu-org; h=Date:References:Subject:In-Reply-To:To:From: mime-version; bh=ytB2odvIS5BYui3xaxf8wtok8/yVSMw67l7izc4zu2I=; b=rDFz2yoGMHvt kwk9LSUqCEsvbeH/xuucwHgRmkDMO8VQwMbNBHtstl2bkBptk8CImsALPtv05EOv3AhJ3vZd/zRdu hcS3d/KUHAg4DSEW/ImxKBX4t+9a2U74VyzAlDXWL32Y5v8A0AdkBByWjhFJOiTouZralgSIwvROB UVfdasgGDmzBd7yqR2/3nRxXvj48UOfQgJAETWgWXzBh8iGnXWK5uSlUHhL37MmgAzL+DCl2v/KlV vFAlQJce4OkRrRaCC9tbKCk6m6L1LSSOdo1QRI1gRWUynbod0I8j24Z4Yl62YRGvGJLIqeNiLsYnd 1RCbSlOXgq+YA/ZTk7A3/A==; Received: from rms by fencepost.gnu.org with local (Exim 4.90_1) (envelope-from ) id 1oIim5-0000uD-5b; Mon, 01 Aug 2022 23:40:53 -0400 Content-Type: text/plain; charset=Utf-8 From: Richard Stallman To: Augusto Stoffel In-Reply-To: <87h72vq4eq.fsf@gmail.com> (message from Augusto Stoffel on Mon, 01 Aug 2022 19:06:53 +0200) Subject: Re: bug#56875: 29.0.50; [PATCH] Add thread-as macro References: <87h72vq4eq.fsf@gmail.com> Message-Id: Date: Mon, 01 Aug 2022 23:40:53 -0400 X-Spam-Score: -2.3 (--) X-Debbugs-Envelope-To: 56875 Cc: 56875@debbugs.gnu.org X-BeenThere: debbugs-submit@debbugs.gnu.org X-Mailman-Version: 2.1.18 Precedence: list List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Reply-To: rms@gnu.org Errors-To: debbugs-submit-bounces@debbugs.gnu.org Sender: "Debbugs-submit" X-Spam-Score: -3.3 (---) [[[ 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. ]]] Clojure is not really much like Lisp. Would you please write down the specs of the construct that you propose we add? Please make it self-contained, not assuming any knowledge of Clojure. We will need that text as the basis to document it for the Emacs Lisp Reference Manual. -- Dr Richard Stallman (https://stallman.org) Chief GNUisance of the GNU Project (https://gnu.org) Founder, Free Software Foundation (https://fsf.org) Internet Hall-of-Famer (https://internethalloffame.org) From debbugs-submit-bounces@debbugs.gnu.org Tue Aug 02 02:57:32 2022 Received: (at 56875) by debbugs.gnu.org; 2 Aug 2022 06:57:32 +0000 Received: from localhost ([127.0.0.1]:42116 helo=debbugs.gnu.org) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1oIlqO-00018j-6b for submit@debbugs.gnu.org; Tue, 02 Aug 2022 02:57:32 -0400 Received: from mail-ed1-f46.google.com ([209.85.208.46]:47037) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1oIlqL-00018T-6I for 56875@debbugs.gnu.org; Tue, 02 Aug 2022 02:57:30 -0400 Received: by mail-ed1-f46.google.com with SMTP id s11so5002710edd.13 for <56875@debbugs.gnu.org>; Mon, 01 Aug 2022 23:57:29 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20210112; h=from:to:cc:subject:in-reply-to:references:date:message-id :user-agent:mime-version; bh=Ffipows6nfSGdPFekJURi4QTaz7epwP7MyRlHz8F/8Y=; b=pSC+5N014jgdAtUqH4j3FaGp775vxkMy7qfNs+T60bx54SEftFLOrMrwg1TAQW0q3n m5/2P62J6//ZugvLYrhbk3Lq+JxZM2WFQE95UbN2cxghaG53Yxm68Ml0R8AMOnTrhA94 tHao36lzv+PvtVR293z1vnEWBi2ZomBYnPcDjkGX5i6zdfpBErzFFg5kc37dfy5IRWtM NzVzO1Bjr3Jj+QCRObigd1BgsaK2oGkZo5iSTE7w01AUGtZUQ3XO6M54zFUM+1ZW/sNU jcYJ2qfIOVAkGvbg0KRP/Ft0zNNyRGHXndfrbd/YNbChdC3+yiGp/VKd0uAeMIicOlCB 62eg== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20210112; h=x-gm-message-state:from:to:cc:subject:in-reply-to:references:date :message-id:user-agent:mime-version; bh=Ffipows6nfSGdPFekJURi4QTaz7epwP7MyRlHz8F/8Y=; b=ZGRYKwMfQ++7Qvt5Snzo+kXKHxU3y7Y0SzKK6u0UhedGj5hbUw9effgftAI9O41T7u UW3AygfGjrTzu9QisuHh3GJsTZqiZFiKmSCKenkf+88sD9kHyjdANd2IlA1abLwAljZw OLWZlNbrULE1kCyJ57HCcwqZUjkoY8pqVKMZxs+ZbGSHKzebzbukIplgou8pPBfMsdwX NlB6Eq4PP7jbR4kB94no0JZNy7A1Tq+eY1wcFp43+kxie6NlX3o+S7H/V/dM/f0i6zUI 2IN7RucfO0CxvVBB0+Ygz2Qius+A7m2XzNkcwLs5J5zHMZnjPrO8vplpOpR6m6CqM8Ii snvA== X-Gm-Message-State: ACgBeo3PJZBaNGP3eP6wxMVjmc0rl5BFWbECANiiBv2jevw1eD6u9r5G aoTAv0mDyNWmxDnaH8I8nprezGdzuV/pDg== X-Google-Smtp-Source: AA6agR6KdeuTKyKVyj1EsuPstRZdedc18Mq94mZBednGLPq+yvEodKrrolPBcFbTFJttWCGVvyZH2Q== X-Received: by 2002:a05:6402:3583:b0:43d:6943:44a with SMTP id y3-20020a056402358300b0043d6943044amr11998120edc.409.1659423443213; Mon, 01 Aug 2022 23:57:23 -0700 (PDT) Received: from ars3 ([2a02:8109:8ac0:56d0::11cf]) by smtp.gmail.com with ESMTPSA id ia17-20020a170907a07100b007307d099ed7sm2233496ejc.121.2022.08.01.23.57.21 (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Mon, 01 Aug 2022 23:57:22 -0700 (PDT) From: Augusto Stoffel To: Richard Stallman Subject: Re: bug#56875: 29.0.50; [PATCH] Add thread-as macro In-Reply-To: (Richard Stallman's message of "Mon, 01 Aug 2022 23:40:53 -0400") References: <87h72vq4eq.fsf@gmail.com> Date: Tue, 02 Aug 2022 08:57:21 +0200 Message-ID: <875yjbp1ym.fsf@gmail.com> User-Agent: Gnus/5.13 (Gnus v5.13) Emacs/29.0.50 (gnu/linux) MIME-Version: 1.0 Content-Type: text/plain X-Spam-Score: 0.0 (/) X-Debbugs-Envelope-To: 56875 Cc: 56875@debbugs.gnu.org X-BeenThere: debbugs-submit@debbugs.gnu.org X-Mailman-Version: 2.1.18 Precedence: list List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: debbugs-submit-bounces@debbugs.gnu.org Sender: "Debbugs-submit" X-Spam-Score: -1.0 (-) On Mon, 1 Aug 2022 at 23:40, Richard Stallman wrote: > [[[ 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. ]]] > > Clojure is not really much like Lisp. Would you please write down the > specs of the construct that you propose we add? Please make it > self-contained, not assuming any knowledge of Clojure. We will need that text > as the basis to document it for the Emacs Lisp Reference Manual. Did you see the patch attached to my first message? Concerning documentation, I wrote a docstring with the same level of detail of the existing thread-first and thread-last, which is on the terse side but probably sufficient. WDYT? From debbugs-submit-bounces@debbugs.gnu.org Tue Aug 02 06:17:21 2022 Received: (at 56875) by debbugs.gnu.org; 2 Aug 2022 10:17:21 +0000 Received: from localhost ([127.0.0.1]:42404 helo=debbugs.gnu.org) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1oIoxl-0002Ns-Ae for submit@debbugs.gnu.org; Tue, 02 Aug 2022 06:17:21 -0400 Received: from quimby.gnus.org ([95.216.78.240]:55454) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1oIoxi-0002Nc-RH for 56875@debbugs.gnu.org; Tue, 02 Aug 2022 06:17:19 -0400 DKIM-Signature: v=1; a=rsa-sha256; q=dns/txt; c=relaxed/relaxed; d=gnus.org; s=20200322; h=Content-Transfer-Encoding:Content-Type:MIME-Version:Message-ID :Date:References:In-Reply-To:Subject:Cc:To:From:Sender:Reply-To: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=X0GtO1Fy9W0oAqkjoSV6VCBCaeyQPHHtu8efJgvHICA=; b=Vz+8eaUAX4SkGkUdtp1CKw+5vO wUige4wGlFjaiDVMwSS7tTrh0LJ6jxmqHQmFsimRLWlXcIRbkUGe0sqvVKErNnUDdkGCI+aunq0Ld HVbc+1QciEgKQOBOvU3Evlt1/pE7yqFz9KGhsCC9u2yAYZ43oLM/QjuglEwlkO1achVk=; Received: from [84.212.220.105] (helo=joga) by quimby.gnus.org with esmtpsa (TLS1.3:ECDHE_RSA_AES_256_GCM_SHA384:256) (Exim 4.92) (envelope-from ) id 1oIoxa-00075U-Jh; Tue, 02 Aug 2022 12:17:12 +0200 From: Lars Ingebrigtsen To: Augusto Stoffel Subject: Re: bug#56875: 29.0.50; [PATCH] Add thread-as macro In-Reply-To: <87h72vq4eq.fsf@gmail.com> (Augusto Stoffel's message of "Mon, 01 Aug 2022 19:06:53 +0200") References: <87h72vq4eq.fsf@gmail.com> X-Now-Playing: Thick Pigeon's _Too Crazy Cowboys_: "Help" Date: Tue, 02 Aug 2022 12:17:09 +0200 Message-ID: <877d3r0x22.fsf@gnus.org> User-Agent: Gnus/5.13 (Gnus v5.13) Emacs/29.0.50 (gnu/linux) MIME-Version: 1.0 Content-Type: text/plain; charset=utf-8 Content-Transfer-Encoding: quoted-printable X-Spam-Report: Spam detection software, running on the system "quimby.gnus.org", has NOT identified this incoming email as spam. The original message has been attached to this so you can view it or label similar future email. If you have any questions, see @@CONTACT_ADDRESS@@ for details. Content preview: Augusto Stoffel writes: > +(defmacro thread-as (var &rest forms) > + "Successively bind VAR to the result of evaluating each of the FORMS. > +Return the last computed value. > + > +Example: > + (thread-as x > + 4 > + (- 10 x [...] Content analysis details: (-2.9 points, 5.0 required) pts rule name description ---- ---------------------- -------------------------------------------------- -1.0 ALL_TRUSTED Passed through trusted hosts only via SMTP -1.9 BAYES_00 BODY: Bayes spam probability is 0 to 1% [score: 0.0000] X-Spam-Score: -2.3 (--) X-Debbugs-Envelope-To: 56875 Cc: 56875@debbugs.gnu.org, 'Eli Zaretskii' X-BeenThere: debbugs-submit@debbugs.gnu.org X-Mailman-Version: 2.1.18 Precedence: list List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: debbugs-submit-bounces@debbugs.gnu.org Sender: "Debbugs-submit" X-Spam-Score: -3.3 (---) Augusto Stoffel writes: > +(defmacro thread-as (var &rest forms) > + "Successively bind VAR to the result of evaluating each of the FORMS. > +Return the last computed value. > + > +Example: > + (thread-as x > + 4 > + (- 10 x) > + (/ x 2)) > + =E2=87=92 3" > + (declare (indent 1)) I'm not enthusiastic. As experience with the other threading macros has shown, they're neat hacks, but they're not used much in actual code (because there's no culture for reading code that's formatted that way in Emacs Lisp). If others think that this would be useful, I won't object to adding it, though. Eli, what do you think? From debbugs-submit-bounces@debbugs.gnu.org Tue Aug 02 06:17:23 2022 Received: (at control) by debbugs.gnu.org; 2 Aug 2022 10:17:23 +0000 Received: from localhost ([127.0.0.1]:42407 helo=debbugs.gnu.org) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1oIoxn-0002O6-KE for submit@debbugs.gnu.org; Tue, 02 Aug 2022 06:17:23 -0400 Received: from quimby.gnus.org ([95.216.78.240]:55466) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1oIoxl-0002Ng-US for control@debbugs.gnu.org; Tue, 02 Aug 2022 06:17:22 -0400 DKIM-Signature: v=1; a=rsa-sha256; q=dns/txt; c=relaxed/relaxed; d=gnus.org; s=20200322; h=Subject:From:To:Message-Id:Date:Sender:Reply-To:Cc: MIME-Version:Content-Type:Content-Transfer-Encoding:Content-ID: Content-Description:Resent-Date:Resent-From:Resent-Sender:Resent-To:Resent-Cc :Resent-Message-ID:In-Reply-To:References:List-Id:List-Help:List-Unsubscribe: List-Subscribe:List-Post:List-Owner:List-Archive; bh=G4YSP36pIKy1fheAxKw7dmMZRXfJ8naolRpKYc6Zrps=; b=XJJeydeSn8LqZSOZgfCxGROvWC t4vsc5cS22mlXn6MivtM2R2JW9eBskvhAI4oc/G9QsfPzkHFBYcbP2t2ZI95mhHgfphQLu8DlZuFy varcjtOIAXLg4R9bo0NQpXFTHDbaETiby/+ZX8gjT9y3vKKjomqDC8agEFa1bORM7ICw=; Received: from [84.212.220.105] (helo=joga) by quimby.gnus.org with esmtpsa (TLS1.3:ECDHE_RSA_AES_256_GCM_SHA384:256) (Exim 4.92) (envelope-from ) id 1oIoxe-00075d-Ef for control@debbugs.gnu.org; Tue, 02 Aug 2022 12:17:16 +0200 Date: Tue, 02 Aug 2022 12:17:14 +0200 Message-Id: <875yjb0x1x.fsf@gnus.org> To: control@debbugs.gnu.org From: Lars Ingebrigtsen Subject: control message for bug #56875 X-Spam-Report: Spam detection software, running on the system "quimby.gnus.org", has NOT identified this incoming email as spam. The original message has been attached to this so you can view it or label similar future email. If you have any questions, see @@CONTACT_ADDRESS@@ for details. Content preview: tags 56875 + moreinfo quit Content analysis details: (-2.9 points, 5.0 required) pts rule name description ---- ---------------------- -------------------------------------------------- -1.0 ALL_TRUSTED Passed through trusted hosts only via SMTP -1.9 BAYES_00 BODY: Bayes spam probability is 0 to 1% [score: 0.0000] X-Spam-Score: -2.3 (--) X-Debbugs-Envelope-To: control X-BeenThere: debbugs-submit@debbugs.gnu.org X-Mailman-Version: 2.1.18 Precedence: list List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: debbugs-submit-bounces@debbugs.gnu.org Sender: "Debbugs-submit" X-Spam-Score: -3.3 (---) tags 56875 + moreinfo quit From debbugs-submit-bounces@debbugs.gnu.org Tue Aug 02 07:25:11 2022 Received: (at 56875) by debbugs.gnu.org; 2 Aug 2022 11:25:11 +0000 Received: from localhost ([127.0.0.1]:42631 helo=debbugs.gnu.org) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1oIq1O-0004lk-TW for submit@debbugs.gnu.org; Tue, 02 Aug 2022 07:25:11 -0400 Received: from eggs.gnu.org ([209.51.188.92]:43798) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1oIq1O-0004lW-00 for 56875@debbugs.gnu.org; Tue, 02 Aug 2022 07:25:10 -0400 Received: from fencepost.gnu.org ([2001:470:142:3::e]:43006) by eggs.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_256_GCM_SHA384:256) (Exim 4.90_1) (envelope-from ) id 1oIq1B-0007Bf-9E; Tue, 02 Aug 2022 07:25:01 -0400 DKIM-Signature: v=1; a=rsa-sha256; q=dns/txt; c=relaxed/relaxed; d=gnu.org; s=fencepost-gnu-org; h=MIME-version:References:Subject:In-Reply-To:To:From: Date; bh=mV7kNn1VtDmGObbPqf1OaDbPqt8fKbHOHM47oF32QqA=; b=JwHrK9RM+50BPuXdo5uv uwmdHHXQcjcgXx550myBCbxxw/Oj4EgjMbuMujsuDIwN/TPhRWwSnMWdb5UH+WNB8gubz+q/e6Gp2 0E8T7DzrO6TPYBarU48i9NO3F69/8TkKTJ7t/JwlRKZ9hGG65KbgOQAUVU5hjVTKa8WkQeOl60EiV VzF7RPM7eSttRKvBoY8eb3w1w/eA96luLuKoZ2ju4EBT7gmHkeMv5uQQUX8yUzPVx/ZXTxkTv6pVb CP4+u8BjFexjT7gj1jj5rGFPqURvJgxSsfRy7edImZwv1NDnK2oJh04m4Uw0v8RZdrNF4mBvaJIP8 0Y84m16LuZstYw==; Received: from [87.69.77.57] (port=4436 helo=home-c4e4a596f7) by fencepost.gnu.org with esmtpsa (TLS1.2:ECDHE_RSA_AES_256_GCM_SHA384:256) (Exim 4.90_1) (envelope-from ) id 1oIq12-0001hJ-0m; Tue, 02 Aug 2022 07:24:49 -0400 Date: Tue, 02 Aug 2022 14:24:38 +0300 Message-Id: <83fsie28i1.fsf@gnu.org> From: Eli Zaretskii To: Lars Ingebrigtsen In-Reply-To: <877d3r0x22.fsf@gnus.org> (message from Lars Ingebrigtsen on Tue, 02 Aug 2022 12:17:09 +0200) Subject: Re: bug#56875: 29.0.50; [PATCH] Add thread-as macro References: <87h72vq4eq.fsf@gmail.com> <877d3r0x22.fsf@gnus.org> MIME-version: 1.0 Content-type: text/plain; charset=utf-8 Content-Transfer-Encoding: 8bit X-Spam-Score: -2.3 (--) X-Debbugs-Envelope-To: 56875 Cc: 56875@debbugs.gnu.org, arstoffel@gmail.com X-BeenThere: debbugs-submit@debbugs.gnu.org X-Mailman-Version: 2.1.18 Precedence: list List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: debbugs-submit-bounces@debbugs.gnu.org Sender: "Debbugs-submit" X-Spam-Score: -3.3 (---) > From: Lars Ingebrigtsen > Cc: 56875@debbugs.gnu.org, "'Eli Zaretskii'" > Date: Tue, 02 Aug 2022 12:17:09 +0200 > > Augusto Stoffel writes: > > > +(defmacro thread-as (var &rest forms) > > + "Successively bind VAR to the result of evaluating each of the FORMS. > > +Return the last computed value. > > + > > +Example: > > + (thread-as x > > + 4 > > + (- 10 x) > > + (/ x 2)) > > + ⇒ 3" > > + (declare (indent 1)) > > I'm not enthusiastic. As experience with the other threading macros has > shown, they're neat hacks, but they're not used much in actual code > (because there's no culture for reading code that's formatted that way > in Emacs Lisp). > > If others think that this would be useful, I won't object to adding it, > though. Eli, what do you think? TBH, I tend to agree. And I'd like to hear the rationale, to make the discussion more concrete. Maybe if the reasons are good enough, I'll change my mind. Just looking at the usage, it does sound a bit artificial. From debbugs-submit-bounces@debbugs.gnu.org Tue Aug 02 08:56:15 2022 Received: (at 56875) by debbugs.gnu.org; 2 Aug 2022 12:56:15 +0000 Received: from localhost ([127.0.0.1]:42811 helo=debbugs.gnu.org) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1oIrRW-00039B-GM for submit@debbugs.gnu.org; Tue, 02 Aug 2022 08:56:14 -0400 Received: from mail-ej1-f49.google.com ([209.85.218.49]:45055) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1oIrRU-00038y-OQ for 56875@debbugs.gnu.org; Tue, 02 Aug 2022 08:56:13 -0400 Received: by mail-ej1-f49.google.com with SMTP id ss3so25719690ejc.11 for <56875@debbugs.gnu.org>; Tue, 02 Aug 2022 05:56:12 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20210112; h=from:to:cc:subject:in-reply-to:references:date:message-id :user-agent:mime-version:content-transfer-encoding; bh=4RqfPxUPYZWTkzbtydyJM6oGu/vVs9+jOqZxw3INKyk=; b=LIywG1o9F3r49c/SYGpoNxUp18pUySwKm/+0PJWHmsYXeeS3b3vBemAgsbYlovyVs3 VPA08U+vnOXQOihho5w1vOQi/FBqzAhrdw2R5R7S2i3h/lthKXZIqw9pSeGmTB+3NObJ CJazLNDCmu4LrIjJTWvqc/oWyuto31xpZ04O0FrybM4VU3gSzLw8f7YqZlLvJrBSeB2W Whr9hqOB0GtClIrZ/UcwNWNVHzkwHK1h1A6OCcp8MFWaWDO3bFr4ufFmbnT7LBtKnNQQ /vCf4NeIHTAt8I6bHte4aP0yVLIAKBApEVpRKceUYCRQN0Q9z1LPNcJ5ifusdPS1aDCy TRAw== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20210112; h=x-gm-message-state:from:to:cc:subject:in-reply-to:references:date :message-id:user-agent:mime-version:content-transfer-encoding; bh=4RqfPxUPYZWTkzbtydyJM6oGu/vVs9+jOqZxw3INKyk=; b=LchH/bOlwXiL5zamcyjOxD6oROB27uKD21cmRHZSv6zTMoz5vcSbf0eRTjOzQQBZqu johC8YQQflk0u4P0e1AT7Zzu3eSoyrknt/nsJVadVIIH1aNVrW74L5Rsuwb8aVqDYzLj oeZ2jF7VoZbQYOqjMMpfSn7OxcdXMg9GrcBbFbCcagt53bo+//JBjlQJEFImM06k7FUn n5us5tMIvjXm/XGy2DDaHW1C222cjIWFzmUkkezWSUUcYxc1eJQqcK7B+L3n9Z9T7YC0 eICr7JDwy6SV5KAWsB01HMkqzTH7jdEHRqutAmO0Yxuf60SBpvf01kRxTmVrl1YhCbRJ M6lg== X-Gm-Message-State: AJIora8GA82us13bovi6inz3zURY07/yWulaJYFbK3EOsDfkrkhzOdIx vZrBASC5fkQtiAFCbOK0HyixdTzYy3XFlA== X-Google-Smtp-Source: AGRyM1sHEA+vvpL5tMhpAlSmqPqqXYx8QOzsucP8xoO1u+tgHNkhaZy/Lf9XkxW8M+WzwrtltWa7ug== X-Received: by 2002:a17:906:fe0b:b0:730:3646:d177 with SMTP id wy11-20020a170906fe0b00b007303646d177mr14301417ejb.688.1659444966344; Tue, 02 Aug 2022 05:56:06 -0700 (PDT) Received: from ars3 (pd95c95b0.dip0.t-ipconnect.de. [217.92.149.176]) by smtp.gmail.com with ESMTPSA id fl19-20020a1709072a9300b007052b183d51sm6167174ejc.132.2022.08.02.05.56.05 (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Tue, 02 Aug 2022 05:56:05 -0700 (PDT) From: Augusto Stoffel To: Eli Zaretskii Subject: Re: bug#56875: 29.0.50; [PATCH] Add thread-as macro In-Reply-To: <83fsie28i1.fsf@gnu.org> (Eli Zaretskii's message of "Tue, 02 Aug 2022 14:24:38 +0300") References: <87h72vq4eq.fsf@gmail.com> <877d3r0x22.fsf@gnus.org> <83fsie28i1.fsf@gnu.org> Date: Tue, 02 Aug 2022 14:56:02 +0200 Message-ID: <87pmhiolct.fsf@gmail.com> User-Agent: Gnus/5.13 (Gnus v5.13) Emacs/29.0.50 (gnu/linux) MIME-Version: 1.0 Content-Type: text/plain; charset=utf-8 Content-Transfer-Encoding: quoted-printable X-Spam-Score: 0.0 (/) X-Debbugs-Envelope-To: 56875 Cc: 56875@debbugs.gnu.org, Lars Ingebrigtsen X-BeenThere: debbugs-submit@debbugs.gnu.org X-Mailman-Version: 2.1.18 Precedence: list List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: debbugs-submit-bounces@debbugs.gnu.org Sender: "Debbugs-submit" X-Spam-Score: -1.0 (-) On Tue, 2 Aug 2022 at 14:24, Eli Zaretskii wrote: >> From: Lars Ingebrigtsen >> Cc: 56875@debbugs.gnu.org, "'Eli Zaretskii'" >> Date: Tue, 02 Aug 2022 12:17:09 +0200 >>=20 >> Augusto Stoffel writes: >>=20 >> > +(defmacro thread-as (var &rest forms) >> > + "Successively bind VAR to the result of evaluating each of the FORM= S. >> > +Return the last computed value. >> > + >> > +Example: >> > + (thread-as x >> > + 4 >> > + (- 10 x) >> > + (/ x 2)) >> > + =E2=87=92 3" >> > + (declare (indent 1)) >>=20 >> I'm not enthusiastic. As experience with the other threading macros has >> shown, they're neat hacks, but they're not used much in actual code >> (because there's no culture for reading code that's formatted that way >> in Emacs Lisp). I agree that the threading style hasn't become popular in Emacs core. But some users and package authors rely on it a lot. Moreover, if 2 of the 3 basic threading macros are already provided, it seems a bit incongruent not to offer the third. Matters of taste aside -- I only use threading occasionally -- I think it can objectively turn certain really ugly constructs into something that is at least palatable. >> If others think that this would be useful, I won't object to adding it, >> though. Eli, what do you think? > > TBH, I tend to agree. And I'd like to hear the rationale, to make the > discussion more concrete. Maybe if the reasons are good enough, I'll > change my mind. Just looking at the usage, it does sound a bit > artificial. One concrete example where thread-as would help is in the situation outlined in the following message, specifically the point that =E2=80=9Ctot= ally breaks down if you want to mix in LITERAL etc=E2=80=9D: https://lists.gnu.org/archive/html/emacs-devel/2021-09/msg01653.html But since I proposed the macro, maybe I should wait and see if someone else finds it useful, and in which situation. (Also, for whatever little it's worth, the macro generates smaller bytecode than the =E2=80=9Cjust give up and go all imperative=E2=80=9D alte= rnative mentioned in the linked message.) From debbugs-submit-bounces@debbugs.gnu.org Tue Aug 02 09:06:58 2022 Received: (at 56875) by debbugs.gnu.org; 2 Aug 2022 13:06:59 +0000 Received: from localhost ([127.0.0.1]:42834 helo=debbugs.gnu.org) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1oIrbu-0003R8-K5 for submit@debbugs.gnu.org; Tue, 02 Aug 2022 09:06:58 -0400 Received: from eggs.gnu.org ([209.51.188.92]:41988) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1oIrbs-0003Qw-Ip for 56875@debbugs.gnu.org; Tue, 02 Aug 2022 09:06:57 -0400 Received: from fencepost.gnu.org ([2001:470:142:3::e]:44392) by eggs.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_256_GCM_SHA384:256) (Exim 4.90_1) (envelope-from ) id 1oIrbn-0005b3-9i; Tue, 02 Aug 2022 09:06:51 -0400 DKIM-Signature: v=1; a=rsa-sha256; q=dns/txt; c=relaxed/relaxed; d=gnu.org; s=fencepost-gnu-org; h=MIME-version:References:Subject:In-Reply-To:To:From: Date; bh=Pt3w2g0JXPNGcNaH/wjhCfVMjVpbh7xK5pz/L4A5ZhQ=; b=F5hCHhCermiN3Qatzkw/ 3uP1rrHLtSxi3bNw4dCeNqpwZ4O9P1EI/7TORC6Ft5ijb4MvwNaLfNKDEyWSYDbrbLfXGOTUxQ9Du goe76jowRnY22km8EBfT0mTrL7vvH4tkPwLuU7HsibIsuWernIZsFVhARn4hp3Kv4gbpgzqmkNum8 YI1HesevP4muT+2U2IFJizzoB1UL9G3nRua6x7368qscdGX/rta6Cm+IgfqBbGf0UfE7cCvt+4I+l 7zoKL+qdtrgZz221aeK9/CV0T0+S8qIBdIb3JE8Q2/cdgq/dALcE9S4oor7n1fT1MgGLezws2xnYw eXhN9v5JxkgQLw==; Received: from [87.69.77.57] (port=2833 helo=home-c4e4a596f7) by fencepost.gnu.org with esmtpsa (TLS1.2:ECDHE_RSA_AES_256_GCM_SHA384:256) (Exim 4.90_1) (envelope-from ) id 1oIrbm-0002Dx-Ns; Tue, 02 Aug 2022 09:06:51 -0400 Date: Tue, 02 Aug 2022 16:06:42 +0300 Message-Id: <837d3q7q1p.fsf@gnu.org> From: Eli Zaretskii To: Augusto Stoffel In-Reply-To: <87pmhiolct.fsf@gmail.com> (message from Augusto Stoffel on Tue, 02 Aug 2022 14:56:02 +0200) Subject: Re: bug#56875: 29.0.50; [PATCH] Add thread-as macro References: <87h72vq4eq.fsf@gmail.com> <877d3r0x22.fsf@gnus.org> <83fsie28i1.fsf@gnu.org> <87pmhiolct.fsf@gmail.com> MIME-version: 1.0 Content-type: text/plain; charset=utf-8 Content-Transfer-Encoding: 8bit X-Spam-Score: -2.3 (--) X-Debbugs-Envelope-To: 56875 Cc: 56875@debbugs.gnu.org, larsi@gnus.org X-BeenThere: debbugs-submit@debbugs.gnu.org X-Mailman-Version: 2.1.18 Precedence: list List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: debbugs-submit-bounces@debbugs.gnu.org Sender: "Debbugs-submit" X-Spam-Score: -3.3 (---) > From: Augusto Stoffel > Cc: Lars Ingebrigtsen , 56875@debbugs.gnu.org > Date: Tue, 02 Aug 2022 14:56:02 +0200 > > One concrete example where thread-as would help is in the situation > outlined in the following message, specifically the point that “totally > breaks down if you want to mix in LITERAL etc”: > > https://lists.gnu.org/archive/html/emacs-devel/2021-09/msg01653.html How frequent that is, and why do you thing using the proposed syntax makes it less awkward? From debbugs-submit-bounces@debbugs.gnu.org Tue Aug 02 23:47:18 2022 Received: (at 56875) by debbugs.gnu.org; 3 Aug 2022 03:47:18 +0000 Received: from localhost ([127.0.0.1]:45724 helo=debbugs.gnu.org) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1oJ5Lq-0006Fy-98 for submit@debbugs.gnu.org; Tue, 02 Aug 2022 23:47:18 -0400 Received: from eggs.gnu.org ([209.51.188.92]:44158) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1oJ5Lo-0006Fh-0O for 56875@debbugs.gnu.org; Tue, 02 Aug 2022 23:47:16 -0400 Received: from fencepost.gnu.org ([2001:470:142:3::e]:34726) by eggs.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_256_GCM_SHA384:256) (Exim 4.90_1) (envelope-from ) id 1oJ5Li-00010S-N6; Tue, 02 Aug 2022 23:47:10 -0400 DKIM-Signature: v=1; a=rsa-sha256; q=dns/txt; c=relaxed/relaxed; d=gnu.org; s=fencepost-gnu-org; h=Date:References:Subject:In-Reply-To:To:From: mime-version; bh=oguIJyXOPEBy5hwAUUhgGq58f2GiBRVoO+bjxZRLXD0=; b=hQANrLk8yVSe V4rOi0VFBK+7bV2dYQg7u7Yx+j/F0b2nAFleQ0PXZ27AVai27D7gndyrnU2mmImnwyZyXVbYRHaxx x+3lfVU9/YCdDeIbOQfL3ytwoDFpAK+gaUaUpoQAAkUns1mQ+sQ4fhFcBox5Hco2kh4uzPEr0qJcf RQooSFJ62W5S0vBeeijsjnSOiow9UPcbvFgz41luTHftLMPeNaoVBHpEyKZaLEn/kAbRUIUdF6BT/ 9WJGq1dKTFCJUumUh3WnZXnFCN5Vzp94UcgmSPK7ZrHp6wgagqNwiwminPB+Uq3e6hBHB4DBhKpaB +Ms/lsrpOG3o1WDMfrnlVA==; Received: from rms by fencepost.gnu.org with local (Exim 4.90_1) (envelope-from ) id 1oJ5Lg-0005fq-Sm; Tue, 02 Aug 2022 23:47:08 -0400 Content-Type: text/plain; charset=Utf-8 From: Richard Stallman To: Lars Ingebrigtsen In-Reply-To: <877d3r0x22.fsf@gnus.org> (message from Lars Ingebrigtsen on Tue, 02 Aug 2022 12:17:09 +0200) Subject: Re: bug#56875: 29.0.50; [PATCH] Add thread-as macro References: <87h72vq4eq.fsf@gmail.com> <877d3r0x22.fsf@gnus.org> Message-Id: Date: Tue, 02 Aug 2022 23:47:08 -0400 X-Spam-Score: -2.3 (--) X-Debbugs-Envelope-To: 56875 Cc: 56875@debbugs.gnu.org, eliz@gnu.org, arstoffel@gmail.com X-BeenThere: debbugs-submit@debbugs.gnu.org X-Mailman-Version: 2.1.18 Precedence: list List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Reply-To: rms@gnu.org Errors-To: debbugs-submit-bounces@debbugs.gnu.org Sender: "Debbugs-submit" X-Spam-Score: -3.3 (---) [[[ 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. ]]] > + (thread-as x > + 4 > + (- 10 x) > + (/ x 2)) I propose a different syntax which is more Lispy than thread-as, and more self-evident: (let-successive ((x 4 (- 10 x))) (/ x 2)) A Lisper can guess what it means, without having read a description. It lends itself to a generalization where there is more than one bound variable, each of which can have several values: (let-successive ((x 4 (- 10 x)) (y 6 (- 12 y))) (* x y)) => 36 The values after the first can refer to all of the variables, since all of them are already bound (to the previous values) at that point. -- Dr Richard Stallman (https://stallman.org) Chief GNUisance of the GNU Project (https://gnu.org) Founder, Free Software Foundation (https://fsf.org) Internet Hall-of-Famer (https://internethalloffame.org) From debbugs-submit-bounces@debbugs.gnu.org Thu Aug 04 09:58:29 2022 Received: (at control) by debbugs.gnu.org; 4 Aug 2022 13:58:29 +0000 Received: from localhost ([127.0.0.1]:54075 helo=debbugs.gnu.org) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1oJbMr-0006yL-B2 for submit@debbugs.gnu.org; Thu, 04 Aug 2022 09:58:29 -0400 Received: from mail-vs1-f42.google.com ([209.85.217.42]:45634) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1oJbMq-0006xz-G8 for control@debbugs.gnu.org; Thu, 04 Aug 2022 09:58:28 -0400 Received: by mail-vs1-f42.google.com with SMTP id m67so13610472vsc.12 for ; Thu, 04 Aug 2022 06:58:28 -0700 (PDT) X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20210112; h=x-gm-message-state:from:mime-version:date:message-id:subject:to; bh=k44iYK+5XsLJ9ygx0zACRLJ6jH1am2h80yDN1SWf0RY=; b=Bs0aVrHTbiV1nX8aKwjuh6AYorAbO2LTRhVTeSb4+vSLmmEdnN2asPzwKmEULjd7RN H+b+Q1VEoebO91F+FOFsBFdStNf7oy5Kg0k79cdqU/jSg40/1walLRpRsIYy+4qaXdmf 0R1ANSTcwDU2/I7LQ0bRN6JJAC8lDoOPVX9rIKFASLvPSqRiaHQMq3sMcIr/qoeRUwIF SXvxeddM0f/NF0O0Yl+JVvmTRiJ+jWY8kVNVAj6IAKIsn5+BNYP2ZkKLlJudoAVuTl2V Ja/eUpiUKBFhP7JjSJ+zJIPItgIJ3d/DUQL8EWvbOLaTfmaQYAqerzUo3ps8lpsgB/uC t7Ow== X-Gm-Message-State: ACgBeo3PLYnHJ3w/Pt/W5dTW1cnto8hsWj+1DDpaa1iaedm7SVY3QF+4 AKinpN8x9TgqfUghCnxsSSjRmX9+uDHxiYxzaQYjjXZs X-Google-Smtp-Source: AA6agR4Aazj5Oie3XjUAyBOkbRTi5IHdVhA5ufxT6XhaiWfmkDnj5CUswBzTtbRfKESz+ssuoltWi/pdDa8pudlx0QY= X-Received: by 2002:a67:cb0c:0:b0:357:9897:32d4 with SMTP id b12-20020a67cb0c000000b00357989732d4mr882264vsl.18.1659621503064; Thu, 04 Aug 2022 06:58:23 -0700 (PDT) Received: from 753933720722 named unknown by gmailapi.google.com with HTTPREST; Thu, 4 Aug 2022 13:58:22 +0000 X-Hashcash: 1:21:220804:control@debbugs.gnu.org::Wm93adbeQmCghnQE:OqaJ From: Stefan Kangas MIME-Version: 1.0 Date: Thu, 4 Aug 2022 13:58:22 +0000 Message-ID: Subject: control message for bug #56875 To: control@debbugs.gnu.org Content-Type: text/plain; charset="UTF-8" X-Spam-Score: 0.5 (/) X-Debbugs-Envelope-To: control X-BeenThere: debbugs-submit@debbugs.gnu.org X-Mailman-Version: 2.1.18 Precedence: list List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: debbugs-submit-bounces@debbugs.gnu.org Sender: "Debbugs-submit" X-Spam-Score: -0.5 (/) severity 56875 wishlist quit From debbugs-submit-bounces@debbugs.gnu.org Fri Aug 05 03:44:59 2022 Received: (at 56875) by debbugs.gnu.org; 5 Aug 2022 07:44:59 +0000 Received: from localhost ([127.0.0.1]:56031 helo=debbugs.gnu.org) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1oJs0x-0004oI-Ea for submit@debbugs.gnu.org; Fri, 05 Aug 2022 03:44:59 -0400 Received: from mail-ed1-f51.google.com ([209.85.208.51]:40554) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1oJs0v-0004o3-VA for 56875@debbugs.gnu.org; Fri, 05 Aug 2022 03:44:58 -0400 Received: by mail-ed1-f51.google.com with SMTP id f22so2334596edc.7 for <56875@debbugs.gnu.org>; Fri, 05 Aug 2022 00:44:57 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20210112; h=mime-version:user-agent:message-id:date:references:in-reply-to :subject:cc:to:from:from:to:cc; bh=DwIuCc0MLF8/xpLJq0ZGCJ5oLenzWl6N0EN0jkt6eSo=; b=kJkpWeMh0ziS/pjPnPehkN/kmBtTkwB4gtHX7BfjXl5Kzjfgkhz/bQR/4rlXVEIPPQ gwTBK0Dcid3tlMWXbeQq2QDm4tirCyBpB9GvQgT2z2qaTxcUmQqfgGXDollZVE+J3f2j 4QrwX1MdFEqHOuVX2PHjsckxCW+2SW9qSD49NS7eS4hV3Y5envfOj3Pj4i6VQbV0hh4A I0laEY61DhxL8mXOh0N/OO6S5l/Y9qCFTO91IklW5MZDqMbuI016EzxgYZTkqqb26Yqp fi1/Aad5UnwiRDg9aDw/0KMA3fSJhdGTuo/Xuu+ikQ0zg5IcVQubSDs4mzeBYQ5/BhMY mXvg== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20210112; h=mime-version:user-agent:message-id:date:references:in-reply-to :subject:cc:to:from:x-gm-message-state:from:to:cc; bh=DwIuCc0MLF8/xpLJq0ZGCJ5oLenzWl6N0EN0jkt6eSo=; b=uh8q6wZH6UNP6q5aK3u00VnNSo6vZwFMDd8+fHq4MHg4QgeX6+HzEG4cW5PDKDK6Na 4oVK+Vf+wz7uoaVsTNvnqfmybHsxh3oQQoo1/YdKsu7srezPA/hxy10B3rn6nWaDNNLY a6T166+UPQhozwXXgJJBErrfsNc72mznmVEGKbfOlMOaJWqVsGdtE/Y+ARyv2DUXpn6x PMGuauF80qt4yG8AoH7M3IyvCh3Sdlfw3RD/Ys1uOa7M462+3Cict/SeJmlmisCRxrvk K/8ibJw4qezi1ZJeUmZA36JJA4RtzQHTjuxsuDdVkY8MT1ih+6Q0mNM92n7Z2bvcmYHM X46A== X-Gm-Message-State: ACgBeo24kq72Ndgcz7qcI4ShK5z7j93ME/tnsSrk1xjjiiNIgzIuKeu2 8b5knnk5ATEWtTHaygbp1/g= X-Google-Smtp-Source: AA6agR62mr9cBK2c+Z0+N/oxp6KKXUtBW6BKVLvVAoRxvoxJRMHjMbwRJpT8dgg5X61wGWikdQckXw== X-Received: by 2002:a05:6402:5192:b0:43d:cc0d:6ea4 with SMTP id q18-20020a056402519200b0043dcc0d6ea4mr5500709edd.111.1659685491999; Fri, 05 Aug 2022 00:44:51 -0700 (PDT) Received: from ars3 ([2a02:8109:8ac0:56d0::a827]) by smtp.gmail.com with ESMTPSA id h22-20020aa7cdd6000000b0043be16f5f4csm1668576edw.52.2022.08.05.00.44.50 (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Fri, 05 Aug 2022 00:44:51 -0700 (PDT) From: Augusto Stoffel To: Richard Stallman Subject: Re: bug#56875: 29.0.50; [PATCH] Add thread-as macro In-Reply-To: (Richard Stallman's message of "Tue, 02 Aug 2022 23:47:08 -0400") References: <87h72vq4eq.fsf@gmail.com> <877d3r0x22.fsf@gnus.org> Date: Fri, 05 Aug 2022 09:44:50 +0200 Message-ID: <87zggj6snh.fsf@gmail.com> User-Agent: Gnus/5.13 (Gnus v5.13) Emacs/29.0.50 (gnu/linux) MIME-Version: 1.0 Content-Type: text/plain X-Spam-Score: 0.0 (/) X-Debbugs-Envelope-To: 56875 Cc: 56875@debbugs.gnu.org, Lars Ingebrigtsen , eliz@gnu.org X-BeenThere: debbugs-submit@debbugs.gnu.org X-Mailman-Version: 2.1.18 Precedence: list List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: debbugs-submit-bounces@debbugs.gnu.org Sender: "Debbugs-submit" X-Spam-Score: -1.0 (-) On Tue, 2 Aug 2022 at 23:47, Richard Stallman wrote: > [[[ 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. ]]] > > > + (thread-as x > > + 4 > > + (- 10 x) > > + (/ x 2)) > > I propose a different syntax which is more Lispy than thread-as, and > more self-evident: > > (let-successive ((x 4 > (- 10 x))) > (/ x 2)) > > A Lisper can guess what it means, without having read a description. > > It lends itself to a generalization where there is more than > one bound variable, each of which can have several values: > > (let-successive ((x 4 > (- 10 x)) > (y 6 > (- 12 y))) > (* x y)) > => 36 > > The values after the first can refer to all of the variables, > since all of them are already bound (to the previous values) > at that point. This is an interesting alternative. I'd suggest to wait for other opinions about the need for this kind of macro in general, and which variant is preferred. From debbugs-submit-bounces@debbugs.gnu.org Fri Sep 02 06:46:27 2022 Received: (at 56875) by debbugs.gnu.org; 2 Sep 2022 10:46:27 +0000 Received: from localhost ([127.0.0.1]:44985 helo=debbugs.gnu.org) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1oU4Bv-0001qT-Ag for submit@debbugs.gnu.org; Fri, 02 Sep 2022 06:46:27 -0400 Received: from quimby.gnus.org ([95.216.78.240]:34052) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1oU4Bt-0001q9-Eg for 56875@debbugs.gnu.org; Fri, 02 Sep 2022 06:46:26 -0400 DKIM-Signature: v=1; a=rsa-sha256; q=dns/txt; c=relaxed/relaxed; d=gnus.org; s=20200322; h=Content-Type:MIME-Version:Message-ID:Date:References: In-Reply-To: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=NFC7sPzG7zabK/KoXCCELLnQ83WllC1X81ytkp4Owc8=; b=ZNZGq2tVLbq6izCOUM3lRJdoAp 9Us8RCKm2Vusw/TvzNeC/FfuZjEt1q5qOXE/GTAgl5huLhkOlbgeYDDIHj8d8MzDnhxz1wqDOfT7Y XWVIeQ+yAHXf6pJNzExLVYIJmeainBbqdkmFitYP7nCbE63UFpyN5lKQSlvpCB5MBu/I=; Received: from [84.212.220.105] (helo=joga) by quimby.gnus.org with esmtpsa (TLS1.3:ECDHE_RSA_AES_256_GCM_SHA384:256) (Exim 4.92) (envelope-from ) id 1oU4Bk-0004h6-72; Fri, 02 Sep 2022 12:46:18 +0200 From: Lars Ingebrigtsen To: Augusto Stoffel Subject: Re: bug#56875: 29.0.50; [PATCH] Add thread-as macro In-Reply-To: <87zggj6snh.fsf@gmail.com> (Augusto Stoffel's message of "Fri, 05 Aug 2022 09:44:50 +0200") References: <87h72vq4eq.fsf@gmail.com> <877d3r0x22.fsf@gnus.org> <87zggj6snh.fsf@gmail.com> X-Now-Playing: Neil Young & Crazy Horse's _American Stars 'N Bars_: "Like A Hurricane" Date: Fri, 02 Sep 2022 12:46:15 +0200 Message-ID: <87ilm6xde0.fsf@gnus.org> User-Agent: Gnus/5.13 (Gnus v5.13) Emacs/29.0.50 (gnu/linux) MIME-Version: 1.0 Content-Type: text/plain X-Spam-Report: Spam detection software, running on the system "quimby.gnus.org", has NOT identified this incoming email as spam. The original message has been attached to this so you can view it or label similar future email. If you have any questions, see @@CONTACT_ADDRESS@@ for details. Content preview: Augusto Stoffel writes: > This is an interesting alternative. I'd suggest to wait for other > opinions about the need for this kind of macro in general, and which > variant is preferred. Content analysis details: (-2.9 points, 5.0 required) pts rule name description ---- ---------------------- -------------------------------------------------- -1.0 ALL_TRUSTED Passed through trusted hosts only via SMTP -1.9 BAYES_00 BODY: Bayes spam probability is 0 to 1% [score: 0.0000] X-Spam-Score: -2.3 (--) X-Debbugs-Envelope-To: 56875 Cc: 56875@debbugs.gnu.org, eliz@gnu.org, Richard Stallman X-BeenThere: debbugs-submit@debbugs.gnu.org X-Mailman-Version: 2.1.18 Precedence: list List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: debbugs-submit-bounces@debbugs.gnu.org Sender: "Debbugs-submit" X-Spam-Score: -3.3 (---) Augusto Stoffel writes: > This is an interesting alternative. I'd suggest to wait for other > opinions about the need for this kind of macro in general, and which > variant is preferred. I think the conclusion here is that there's not much enthusiasm for adding thread-as, and adding a more Lisp-like version like Richard proposes wouldn't satisfy anybody, I think: People coming from a Lisp background generally like writing Lisp in the order they're used to, and people who like the reversed order want something less Lispy. So I'm closing this bug report. From debbugs-submit-bounces@debbugs.gnu.org Fri Sep 02 06:46:30 2022 Received: (at control) by debbugs.gnu.org; 2 Sep 2022 10:46:30 +0000 Received: from localhost ([127.0.0.1]:44988 helo=debbugs.gnu.org) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1oU4By-0001qi-Jf for submit@debbugs.gnu.org; Fri, 02 Sep 2022 06:46:30 -0400 Received: from quimby.gnus.org ([95.216.78.240]:34066) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1oU4Bx-0001qF-Gy for control@debbugs.gnu.org; Fri, 02 Sep 2022 06:46:29 -0400 DKIM-Signature: v=1; a=rsa-sha256; q=dns/txt; c=relaxed/relaxed; d=gnus.org; s=20200322; h=Subject:From:To:Message-Id:Date:Sender:Reply-To:Cc: MIME-Version:Content-Type:Content-Transfer-Encoding:Content-ID: Content-Description:Resent-Date:Resent-From:Resent-Sender:Resent-To:Resent-Cc :Resent-Message-ID:In-Reply-To:References:List-Id:List-Help:List-Unsubscribe: List-Subscribe:List-Post:List-Owner:List-Archive; bh=bX/f8gf8Pl28c+QqnuSqgvH/sl9BzUJ/X/SmvOvsHuE=; b=ZIqfwhSsfiCNJJmNIXHxjbJFTk FwOaV+ePYbCFstPPH5durld0Cql53oibkbZ8LTufW9DcjYRp3mWADQM9CirHN4ItCkqpqN3f1zTwl 6g1pdfGts2jFG4YBE4eooZHbe3tEXhX8ArjXWKqhTwdqQYYuZKRv/jYM/iI/SPL4cWHU=; Received: from [84.212.220.105] (helo=joga) by quimby.gnus.org with esmtpsa (TLS1.3:ECDHE_RSA_AES_256_GCM_SHA384:256) (Exim 4.92) (envelope-from ) id 1oU4Bp-0004hD-KT for control@debbugs.gnu.org; Fri, 02 Sep 2022 12:46:23 +0200 Date: Fri, 02 Sep 2022 12:46:21 +0200 Message-Id: <87h71qxddu.fsf@gnus.org> To: control@debbugs.gnu.org From: Lars Ingebrigtsen Subject: control message for bug #56875 X-Spam-Report: Spam detection software, running on the system "quimby.gnus.org", has NOT identified this incoming email as spam. The original message has been attached to this so you can view it or label similar future email. If you have any questions, see @@CONTACT_ADDRESS@@ for details. Content preview: tags 56875 wontfix close 56875 quit Content analysis details: (-2.9 points, 5.0 required) pts rule name description ---- ---------------------- -------------------------------------------------- -1.0 ALL_TRUSTED Passed through trusted hosts only via SMTP -1.9 BAYES_00 BODY: Bayes spam probability is 0 to 1% [score: 0.0000] X-Spam-Score: -2.3 (--) X-Debbugs-Envelope-To: control X-BeenThere: debbugs-submit@debbugs.gnu.org X-Mailman-Version: 2.1.18 Precedence: list List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: debbugs-submit-bounces@debbugs.gnu.org Sender: "Debbugs-submit" X-Spam-Score: -3.3 (---) tags 56875 wontfix close 56875 quit From unknown Mon Jun 23 07:52:58 2025 Received: (at fakecontrol) by fakecontrolmessage; To: internal_control@debbugs.gnu.org From: Debbugs Internal Request Subject: Internal Control Message-Id: bug archived. Date: Fri, 30 Sep 2022 11:24:11 +0000 User-Agent: Fakemail v42.6.9 # This is a fake control message. # # The action: # bug archived. thanks # This fakemail brought to you by your local debbugs # administrator