From mboxrd@z Thu Jan 1 00:00:00 1970 Path: news.gmane.io!.POSTED.blaine.gmane.org!not-for-mail From: Jean Louis Newsgroups: gmane.emacs.bugs Subject: bug#59333: [PATCH] Define macro dlet* Date: Sat, 19 Nov 2022 07:37:31 +0300 Message-ID: References: <0e8ca5ce-a413-0dd0-c62e-647d19953a3b@gmail.com> <83leoadovn.fsf@gnu.org> Mime-Version: 1.0 Content-Type: text/plain; charset=utf-8 Content-Transfer-Encoding: 8bit Injection-Info: ciao.gmane.io; posting-host="blaine.gmane.org:116.202.254.214"; logging-data="30964"; mail-complaints-to="usenet@ciao.gmane.io" User-Agent: Mutt/2.2.7+37 (a90f69b) (2022-09-02) Cc: Eli Zaretskii , 59333@debbugs.gnu.org To: Daan Ro Original-X-From: bug-gnu-emacs-bounces+geb-bug-gnu-emacs=m.gmane-mx.org@gnu.org Sat Nov 19 05:39:14 2022 Return-path: Envelope-to: geb-bug-gnu-emacs@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 1owFdJ-0007pq-Lo for geb-bug-gnu-emacs@m.gmane-mx.org; Sat, 19 Nov 2022 05:39:13 +0100 Original-Received: from localhost ([::1] helo=lists1p.gnu.org) by lists.gnu.org with esmtp (Exim 4.90_1) (envelope-from ) id 1owFdA-0000kw-3j; Fri, 18 Nov 2022 23:39:04 -0500 Original-Received: from eggs.gnu.org ([2001:470:142:3::10]) by lists.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_256_GCM_SHA384:256) (Exim 4.90_1) (envelope-from ) id 1owFd8-0000kg-Ml for bug-gnu-emacs@gnu.org; Fri, 18 Nov 2022 23:39:02 -0500 Original-Received: from debbugs.gnu.org ([209.51.188.43]) by eggs.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_128_GCM_SHA256:128) (Exim 4.90_1) (envelope-from ) id 1owFd8-0001sR-Du for bug-gnu-emacs@gnu.org; Fri, 18 Nov 2022 23:39:02 -0500 Original-Received: from Debian-debbugs by debbugs.gnu.org with local (Exim 4.84_2) (envelope-from ) id 1owFd8-00027t-AF for bug-gnu-emacs@gnu.org; Fri, 18 Nov 2022 23:39:02 -0500 X-Loop: help-debbugs@gnu.org Resent-From: Jean Louis Original-Sender: "Debbugs-submit" Resent-CC: bug-gnu-emacs@gnu.org Resent-Date: Sat, 19 Nov 2022 04:39:02 +0000 Resent-Message-ID: Resent-Sender: help-debbugs@gnu.org X-GNU-PR-Message: followup 59333 X-GNU-PR-Package: emacs X-GNU-PR-Keywords: patch Original-Received: via spool by 59333-submit@debbugs.gnu.org id=B59333.16688326848100 (code B ref 59333); Sat, 19 Nov 2022 04:39:02 +0000 Original-Received: (at 59333) by debbugs.gnu.org; 19 Nov 2022 04:38:04 +0000 Original-Received: from localhost ([127.0.0.1]:38680 helo=debbugs.gnu.org) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1owFcC-00026Z-0D for submit@debbugs.gnu.org; Fri, 18 Nov 2022 23:38:04 -0500 Original-Received: from stw1.rcdrun.com ([217.170.207.13]:36839) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1owFcA-00025U-Fs for 59333@debbugs.gnu.org; Fri, 18 Nov 2022 23:38:02 -0500 Original-Received: from localhost ([::ffff:197.239.5.174]) (AUTH: PLAIN admin, TLS: TLS1.3,256bits,ECDHE_RSA_AES_256_GCM_SHA384) by stw1.rcdrun.com with ESMTPSA id 00000000000F612E.0000000063785DAA.00000BD0; Fri, 18 Nov 2022 21:38:01 -0700 Content-Disposition: inline In-Reply-To: X-BeenThere: debbugs-submit@debbugs.gnu.org X-Mailman-Version: 2.1.18 Precedence: list X-BeenThere: bug-gnu-emacs@gnu.org List-Id: "Bug reports for GNU Emacs, the Swiss army knife of text editors" List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: bug-gnu-emacs-bounces+geb-bug-gnu-emacs=m.gmane-mx.org@gnu.org Original-Sender: bug-gnu-emacs-bounces+geb-bug-gnu-emacs=m.gmane-mx.org@gnu.org Xref: news.gmane.io gmane.emacs.bugs:248293 Archived-At: * Daan Ro [2022-11-17 10:42]: > > dlet was new in Emacs 28, and the change you mention was done before > > Emacs 28 was released. So NEWS just mentions the introduction of > > dlet, and that is enough. > > Sorry it was my fault for not paying attention to the commit year (I thought > that was August this year). > > Therefore reverting it now must not be an option. > > But I think let* is more useful than let in general for programming, > as it let us create successive bindings and transform the flow of > data, like the natural flow of thought. In some cases I use `dlet' within my 'let*' to make certain variables to be global as those variables are not found in the main code, but in the external text. Those two functions are not interchangeable for me. Replacing them does not work. Example is below: (let* ((text (rcd-dlet ((hs::id id) (hs::uuid (hyperscope-uuid id))) (rcd-template-eval text '("⟦" "⟧"))))) (continue...)) There are three parts: main code, template and text. Main code does the template interpolation by using text. As text is separate from code and from the template, the main code cannot know what exactly is evaluated during template interpolation. Thus using lexical binding does not work well with externally evaluated code. -- Jean Take action in Free Software Foundation campaigns: https://www.fsf.org/campaigns In support of Richard M. Stallman https://stallmansupport.org/