From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: from mp1 ([2001:41d0:2:4a6f::]) (using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits)) by ms0.migadu.com with LMTPS id ky05MMqgkmDCeQAAgWs5BA (envelope-from ) for ; Wed, 05 May 2021 15:42:34 +0200 Received: from aspmx1.migadu.com ([2001:41d0:2:4a6f::]) (using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits)) by mp1 with LMTPS id 2G8eK8qgkmC1DgAAbx9fmQ (envelope-from ) for ; Wed, 05 May 2021 13:42:34 +0000 Received: from mail.notmuchmail.org (nmbug.tethera.net [IPv6:2607:5300:201:3100::1657]) (using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits) key-exchange X25519 server-signature RSA-PSS (2048 bits) server-digest SHA256) (No client certificate requested) by aspmx1.migadu.com (Postfix) with ESMTPS id 899CE8448 for ; Wed, 5 May 2021 15:42:34 +0200 (CEST) Received: from nmbug.tethera.net (localhost [127.0.0.1]) by mail.notmuchmail.org (Postfix) with ESMTP id 13599271CC; Wed, 5 May 2021 09:42:30 -0400 (EDT) Received: from fethera.tethera.net (fethera.tethera.net [198.245.60.197]) by mail.notmuchmail.org (Postfix) with ESMTP id 8A8EE2716D for ; Wed, 5 May 2021 09:42:27 -0400 (EDT) Received: by fethera.tethera.net (Postfix, from userid 1001) id 3394060016; Wed, 5 May 2021 09:42:27 -0400 (EDT) Received: (nullmailer pid 1951725 invoked by uid 1000); Wed, 05 May 2021 13:42:25 -0000 From: David Bremner To: Kyle Meyer , Matt Lundin Subject: Re: [PATCH] emacs: restore tag-changes and query bindings for tag hooks In-Reply-To: <87sg319aqa.fsf@kyleam.com> References: <87v97ytd2s.fsf@fastmail.fm> <87sg319aqa.fsf@kyleam.com> Date: Wed, 05 May 2021 10:42:25 -0300 Message-ID: <87im3xl2ke.fsf@tethera.net> MIME-Version: 1.0 Message-ID-Hash: V6RNEPIFEKGXURD2RWXCRUTKPEBDEFAP X-Message-ID-Hash: V6RNEPIFEKGXURD2RWXCRUTKPEBDEFAP X-MailFrom: david@tethera.net X-Mailman-Rule-Misses: dmarc-mitigation; no-senders; approved; emergency; loop; banned-address; member-moderation; header-match-notmuch.notmuchmail.org-0; nonmember-moderation; administrivia; implicit-dest; max-recipients; max-size; news-moderation; no-subject; suspicious-header CC: notmuch@notmuchmail.org X-Mailman-Version: 3.2.1 Precedence: list List-Id: "Use and development of the notmuch mail system." List-Help: List-Post: List-Subscribe: List-Unsubscribe: Content-Type: text/plain; charset="us-ascii" Content-Transfer-Encoding: 7bit X-Migadu-Flow: FLOW_IN X-Migadu-Spam-Score: -4.00 Authentication-Results: aspmx1.migadu.com; none X-Migadu-Queue-Id: 899CE8448 X-Spam-Score: -4.00 X-Migadu-Scanner: scn0.migadu.com X-TUID: bxcH/F6uX+sX Kyle Meyer writes: > +;; `dlet' isn't available until Emacs 28.1. Below is a copy, with the > +;; addition of `with-no-warnings'. > +(defmacro notmuch-dlet (binders &rest body) > + "Like `let*' but using dynamic scoping." > + (declare (indent 1) (debug let)) > + `(let (_) > + (with-no-warnings ; Quiet "lacks a prefix" warning. > + ,@(mapcar (lambda (binder) > + `(defvar ,(if (consp binder) (car binder) binder))) > + binders)) > + (let* ,binders ,@body))) > + > (provide 'notmuch-compat) What do you think Jonas, is this a reasonable approach? d