From mboxrd@z Thu Jan 1 00:00:00 1970 Path: news.gmane.io!.POSTED.blaine.gmane.org!not-for-mail From: Eli Zaretskii Newsgroups: gmane.emacs.bugs Subject: bug#64642: 29.0.92; Native compiler doesn't compile dynamically bound functions. Date: Sat, 15 Jul 2023 12:53:51 +0300 Message-ID: <838rbhcxg0.fsf@gnu.org> References: Injection-Info: ciao.gmane.io; posting-host="blaine.gmane.org:116.202.254.214"; logging-data="36421"; mail-complaints-to="usenet@ciao.gmane.io" Cc: 64642@debbugs.gnu.org To: Alan Mackenzie , Andrea Corallo Original-X-From: bug-gnu-emacs-bounces+geb-bug-gnu-emacs=m.gmane-mx.org@gnu.org Sat Jul 15 11:54:20 2023 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 1qKbym-0009Fa-0W for geb-bug-gnu-emacs@m.gmane-mx.org; Sat, 15 Jul 2023 11:54:20 +0200 Original-Received: from localhost ([::1] helo=lists1p.gnu.org) by lists.gnu.org with esmtp (Exim 4.90_1) (envelope-from ) id 1qKbyW-000164-3s; Sat, 15 Jul 2023 05:54:04 -0400 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 1qKbyU-00015W-RC for bug-gnu-emacs@gnu.org; Sat, 15 Jul 2023 05:54:02 -0400 Original-Received: from debbugs.gnu.org ([2001:470:142:5::43]) by eggs.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_128_GCM_SHA256:128) (Exim 4.90_1) (envelope-from ) id 1qKbyU-00038R-Jo for bug-gnu-emacs@gnu.org; Sat, 15 Jul 2023 05:54:02 -0400 Original-Received: from Debian-debbugs by debbugs.gnu.org with local (Exim 4.84_2) (envelope-from ) id 1qKbyU-00051U-GB for bug-gnu-emacs@gnu.org; Sat, 15 Jul 2023 05:54:02 -0400 X-Loop: help-debbugs@gnu.org Resent-From: Eli Zaretskii Original-Sender: "Debbugs-submit" Resent-CC: bug-gnu-emacs@gnu.org Resent-Date: Sat, 15 Jul 2023 09:54:02 +0000 Resent-Message-ID: Resent-Sender: help-debbugs@gnu.org X-GNU-PR-Message: followup 64642 X-GNU-PR-Package: emacs Original-Received: via spool by 64642-submit@debbugs.gnu.org id=B64642.168941482019274 (code B ref 64642); Sat, 15 Jul 2023 09:54:02 +0000 Original-Received: (at 64642) by debbugs.gnu.org; 15 Jul 2023 09:53:40 +0000 Original-Received: from localhost ([127.0.0.1]:44202 helo=debbugs.gnu.org) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1qKby7-00050o-S5 for submit@debbugs.gnu.org; Sat, 15 Jul 2023 05:53:40 -0400 Original-Received: from eggs.gnu.org ([2001:470:142:3::10]:51100) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1qKby4-00050X-D4 for 64642@debbugs.gnu.org; Sat, 15 Jul 2023 05:53:37 -0400 Original-Received: from fencepost.gnu.org ([2001:470:142:3::e]) by eggs.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_256_GCM_SHA384:256) (Exim 4.90_1) (envelope-from ) id 1qKbxy-00030K-Hd; Sat, 15 Jul 2023 05:53:30 -0400 DKIM-Signature: v=1; a=rsa-sha256; q=dns/txt; c=relaxed/relaxed; d=gnu.org; s=fencepost-gnu-org; h=References:Subject:In-Reply-To:To:From:Date: mime-version; bh=K1/Z5r3zB3m8szju7dleXij6dhwhUyondAQDDGRY10Y=; b=EJE66AeipNIk neKkn46RSgbZPotG1jascv9TLs1kiv28ISHwascJz2X2DmBmemUVgJTeosOrcB4k3btzdOJmns/yn xLdTbaU+XyErdL5xwbObfg4zf9Y8FTFCl1wTuCqaNzXKJlTos4AbdEGeizTPsXLXOBDO/uAQwMQQb HgNjgm3JQl0O+d1HDRG5vorH7gkxNyYfUMc8u1CRvYubDd1MvE55ge5b91qIn8cE8ulKKWgflJDkf Av/S2suM08P60j0IG8X/SkDfxrlyRSAkTEyKC66l3IHM/AwiRDIvAQ0uxgwwN3zeRUhyqmS1ChGUh KjGtWKgMUauA6/6TFjzzzA==; Original-Received: from [87.69.77.57] (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 1qKbxy-0005UM-0y; Sat, 15 Jul 2023 05:53:30 -0400 In-Reply-To: (message from Alan Mackenzie on Sat, 15 Jul 2023 09:38:13 +0000) 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:265186 Archived-At: > Date: Sat, 15 Jul 2023 09:38:13 +0000 > From: Alan Mackenzie > > Hello, Emacs. > > In the Emacs 29 pretest version (or the master version): > (i) emacs -Q > (ii) C-x b foo.el > (iii) M-x emacs-lisp-mode > Don't set lexical-binding in this buffer. > (iv) Enter a function called foo: > (defun foo () "foo doc string" > (lambda (bar) "lambda doc string" (car bar))) > (v) With point after the function, evaluate it with C-x C-e. > > (vi) M-: (native-compile 'foo) > This signals an error, native-compiler-error-dyn-func. This is a bug. > > ######################################################################### > > The immediate cause of the bug is in the version of > comp-spill-lap-function which processes named functions (comp.el). > Unlike the other version of the cl-defmethod (which processes lambda > functions), there is no code for dynamic functions here. > > If the intention is not to process dynamic functions, this should be > indicated by an error message rather than a signal. Personally, I feel > that dynamic functions ought to be handled in Emacs-29. > > Fixing this bug should be relatively straightforward, since it should > only involve copying and adapting the corresponding code in the lambda > version of comp-spill-lap-function. Adding Andrea. It is unlikely that this will be fixed in Emacs 29, unless the fix is so simple that will surprise me.