From mboxrd@z Thu Jan 1 00:00:00 1970 Path: news.gmane.io!.POSTED.blaine.gmane.org!not-for-mail From: Stefan Monnier Newsgroups: gmane.emacs.devel Subject: Re: [nongnu] elpa/geiser bb9d5cb200: geiser-impl--normalize-method: quick fix for previous change Date: Fri, 28 Jan 2022 15:16:37 -0500 Message-ID: References: <164339989485.1614.11034229578358286224@vcs2.savannah.gnu.org> <20220128195815.4DB24C423B9@vcs2.savannah.gnu.org> Mime-Version: 1.0 Content-Type: text/plain Injection-Info: ciao.gmane.io; posting-host="blaine.gmane.org:116.202.254.214"; logging-data="40212"; mail-complaints-to="usenet@ciao.gmane.io" User-Agent: Gnus/5.13 (Gnus v5.13) Emacs/29.0.50 (gnu/linux) Cc: emacs-devel@gnu.org To: jao Original-X-From: emacs-devel-bounces+ged-emacs-devel=m.gmane-mx.org@gnu.org Fri Jan 28 21:26:31 2022 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 1nDXpE-000AF3-SW for ged-emacs-devel@m.gmane-mx.org; Fri, 28 Jan 2022 21:26:29 +0100 Original-Received: from localhost ([::1]:35274 helo=lists1p.gnu.org) by lists.gnu.org with esmtp (Exim 4.90_1) (envelope-from ) id 1nDXpD-0005Nz-Gr for ged-emacs-devel@m.gmane-mx.org; Fri, 28 Jan 2022 15:26:27 -0500 Original-Received: from eggs.gnu.org ([209.51.188.92]:38462) by lists.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_256_GCM_SHA384:256) (Exim 4.90_1) (envelope-from ) id 1nDXfw-0005rt-74 for emacs-devel@gnu.org; Fri, 28 Jan 2022 15:16:52 -0500 Original-Received: from mailscanner.iro.umontreal.ca ([132.204.25.50]:30170) by eggs.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_256_GCM_SHA384:256) (Exim 4.90_1) (envelope-from ) id 1nDXfr-0007jM-VK; Fri, 28 Jan 2022 15:16:50 -0500 Original-Received: from pmg3.iro.umontreal.ca (localhost [127.0.0.1]) by pmg3.iro.umontreal.ca (Proxmox) with ESMTP id 0A840442A38; Fri, 28 Jan 2022 15:16:41 -0500 (EST) Original-Received: from mail01.iro.umontreal.ca (unknown [172.31.2.1]) by pmg3.iro.umontreal.ca (Proxmox) with ESMTP id 7B4CA442A35; Fri, 28 Jan 2022 15:16:39 -0500 (EST) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/simple; d=iro.umontreal.ca; s=mail; t=1643400999; bh=ZzIahxQp6YpgG35HHaz5mlBq4/cpJ0EHPb+Ifchw2Hc=; h=From:To:Cc:Subject:References:Date:In-Reply-To:From; b=hAKZgWXa4LP5KvHLO4C+VsaTuxUugQCsMxFrmebXdzi8STcUwXuLsUSGXn086qB94 lsznHDcTSO4hSB4eMRcLDre7UVMxhb9KzHEe1PFTY6L8hTrXU2jEeTRGGQXTIWJe38 7sKjkBUft3PzuU+eajOEJFaWgrPbUyWBesw+dQsXhuVkg0fgbqr4gV3Cgh/6vAJCCX R6XNt3USBylMtHCA/vAuQ/wF6qi72u7y1FSN9vD5gnfpB88Ix6shyoL+8Dhb6+Zvgr dnnsuHv06SSP03Nw4IsL6sspO7RNSoW7XWsdzHV6diAlkSE9QFhdezWTeylqjso7lw SMsSTmPe2u2fw== Original-Received: from ceviche (76-10-138-212.dsl.teksavvy.com [76.10.138.212]) by mail01.iro.umontreal.ca (Postfix) with ESMTPSA id 4031E120865; Fri, 28 Jan 2022 15:16:39 -0500 (EST) In-Reply-To: <20220128195815.4DB24C423B9@vcs2.savannah.gnu.org> (ELPA Syncer's message of "Fri, 28 Jan 2022 14:58:15 -0500 (EST)") Received-SPF: pass client-ip=132.204.25.50; envelope-from=monnier@iro.umontreal.ca; helo=mailscanner.iro.umontreal.ca X-Spam_score_int: -23 X-Spam_score: -2.4 X-Spam_bar: -- X-Spam_report: (-2.4 / 5.0 requ) DKIM_SIGNED=0.1, DKIM_VALID=-0.1, DKIM_VALID_AU=-0.1, RCVD_IN_DNSWL_MED=-2.3, SPF_HELO_NONE=0.001, SPF_PASS=-0.001, T_SCC_BODY_TEXT_LINE=-0.01 autolearn=unavailable autolearn_force=no X-Spam_action: no action X-BeenThere: emacs-devel@gnu.org X-Mailman-Version: 2.1.29 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:285525 Archived-At: > (let ((v (cadr m))) > - (if (functionp v) m > - `(,(car m) > - ,(lambda (&rest _) v)))))) > + (if (functionp v) m `(,(car m) (lambda (&rest _) ,v)))))) But this reintroduces the use of a list-that-looks-like-a-function instead of a true function. BTW, one difference I can see is that the new code will basically pass `v` to `eval` whereas the code I had sent considers `v` to be a value already. So maybe the code I should have sent is along the lines of the patch below? Stefan diff --git a/elisp/geiser-impl.el b/elisp/geiser-impl.el index 53a7a824c3..3bc5af5e55 100644 --- a/elisp/geiser-impl.el +++ b/elisp/geiser-impl.el @@ -158,7 +158,7 @@ in order to determine its scheme flavour." (= 2 (length m)) (symbolp (car m))) (let ((v (cadr m))) - (if (functionp v) m `(,(car m) (lambda (&rest _) ,v)))))) + (if (functionp v) m `(,(car m) ,(lambda (&rest _) (eval v t))))))) (defun geiser-impl--define (file name parent methods) (let* ((methods (mapcar #'geiser-impl--normalize-method methods))