From mboxrd@z Thu Jan 1 00:00:00 1970 Path: news.gmane.io!.POSTED.blaine.gmane.org!not-for-mail From: Stefan Monnier via "Bug reports for GNU Emacs, the Swiss army knife of text editors" Newsgroups: gmane.emacs.bugs Subject: bug#69573: Eager macro-expansion failure: (wrong-type-argument integer-or-marker-p nil) Date: Sat, 09 Mar 2024 09:47:06 -0500 Message-ID: References: <28a41cd9-3abe-47bf-b3d5-fed723dde32b@medialab.sissa.it> <875xy0qjzf.fsf@web.de> <812c2400-07b5-451a-89bc-4e9e4b60fb44@medialab.sissa.it> <87r0gmbvnc.fsf@web.de> <871q8mbn7e.fsf@web.de> <87zfv8uivz.fsf@web.de> Reply-To: Stefan Monnier Mime-Version: 1.0 Content-Type: text/plain Injection-Info: ciao.gmane.io; posting-host="blaine.gmane.org:116.202.254.214"; logging-data="6659"; mail-complaints-to="usenet@ciao.gmane.io" User-Agent: Gnus/5.13 (Gnus v5.13) Cc: Michael Heerdegen , Gabriele Nicolardi , 69573@debbugs.gnu.org To: Andrea Corallo Original-X-From: bug-gnu-emacs-bounces+geb-bug-gnu-emacs=m.gmane-mx.org@gnu.org Sat Mar 09 15:48:01 2024 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 1rixzV-0001Um-4e for geb-bug-gnu-emacs@m.gmane-mx.org; Sat, 09 Mar 2024 15:48:01 +0100 Original-Received: from localhost ([::1] helo=lists1p.gnu.org) by lists.gnu.org with esmtp (Exim 4.90_1) (envelope-from ) id 1rixz3-00078V-Gp; Sat, 09 Mar 2024 09:47:33 -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 1rixz1-00075R-Am for bug-gnu-emacs@gnu.org; Sat, 09 Mar 2024 09:47:31 -0500 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 1rixz1-0008QX-26 for bug-gnu-emacs@gnu.org; Sat, 09 Mar 2024 09:47:31 -0500 Original-Received: from Debian-debbugs by debbugs.gnu.org with local (Exim 4.84_2) (envelope-from ) id 1rixzW-0008N8-62 for bug-gnu-emacs@gnu.org; Sat, 09 Mar 2024 09:48:02 -0500 X-Loop: help-debbugs@gnu.org Resent-From: Stefan Monnier Original-Sender: "Debbugs-submit" Resent-CC: bug-gnu-emacs@gnu.org Resent-Date: Sat, 09 Mar 2024 14:48:02 +0000 Resent-Message-ID: Resent-Sender: help-debbugs@gnu.org X-GNU-PR-Message: followup 69573 X-GNU-PR-Package: emacs Original-Received: via spool by 69573-submit@debbugs.gnu.org id=B69573.170999566932159 (code B ref 69573); Sat, 09 Mar 2024 14:48:02 +0000 Original-Received: (at 69573) by debbugs.gnu.org; 9 Mar 2024 14:47:49 +0000 Original-Received: from localhost ([127.0.0.1]:32771 helo=debbugs.gnu.org) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1rixzJ-0008Md-6e for submit@debbugs.gnu.org; Sat, 09 Mar 2024 09:47:49 -0500 Original-Received: from mailscanner.iro.umontreal.ca ([132.204.25.50]:48998) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1rixzH-0008MQ-0q for 69573@debbugs.gnu.org; Sat, 09 Mar 2024 09:47:48 -0500 Original-Received: from pmg2.iro.umontreal.ca (localhost.localdomain [127.0.0.1]) by pmg2.iro.umontreal.ca (Proxmox) with ESMTP id A8C7A80CC9; Sat, 9 Mar 2024 09:47:08 -0500 (EST) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/simple; d=iro.umontreal.ca; s=mail; t=1709995627; bh=3ajoPY2Vhjr7n8t5rDdPQa3dQ9PzEmROpMv6xKG/t3o=; h=From:To:Cc:Subject:In-Reply-To:References:Date:From; b=DrVywGu8jm9iQwPQTX1spPPMw5mm/R9xhUhW/2CTaaqFJtJb5IBqZL+rmOFYjrKXV 8dvcAv7RmVGsUkwR1yl1u6I9BTwJGAbNTM98+wvuPiIVtigfq+6tt45yxBdCbHjhSM VyaXatqRDzE2lmhumuS9dDMek9VNI+L0BXWka3Ck962UlBDLKbOTJ8LJndA/ozWOiC dMOS5nZ3jHrWyr5Gei6EUwQ4wtxmV/VZU8o9YCvUGZzVgCcgj5p3qSqSHieRtGplL7 IBQ3kz7JTrvcfpHtFtmSJoibI+BI8M/uRKW/fFzWnUDGXPT3aby2Ic8qwVE9BSwl/y +ZBYDXZx8Axsw== Original-Received: from mail01.iro.umontreal.ca (unknown [172.31.2.1]) by pmg2.iro.umontreal.ca (Proxmox) with ESMTP id B5A0380799; Sat, 9 Mar 2024 09:47:07 -0500 (EST) Original-Received: from pastel (69-165-153-56.dsl.teksavvy.com [69.165.153.56]) by mail01.iro.umontreal.ca (Postfix) with ESMTPSA id 844CD1203C3; Sat, 9 Mar 2024 09:47:07 -0500 (EST) In-Reply-To: <87zfv8uivz.fsf@web.de> (Michael Heerdegen's message of "Sat, 09 Mar 2024 05:30:24 +0100") 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:281341 Archived-At: >> (defalias 're-search-forward-ifpmod (symbol-function 're-search-forward) ...) [...] > Stefan, can you help maybe? Gabriele then does this: [...] > and we have found that this causes weird errors because at least some > definitions, like `forward-paragraph', call `re-search-forward-ifpmod' > afterwards. This seems to happen only when using a native compiled Sounds like a problem in the code that installs trampolines. Andrea? If we look at `fset`, the C code does: if (!NILP (Vnative_comp_enable_subr_trampolines) && SUBRP (function) && !SUBR_NATIVE_COMPILEDP (function)) CALLN (Ffuncall, Qcomp_subr_trampoline_install, symbol); so indeed if the SUBR_NATIVE_COMPILEDP function is stored in another symbol, we will still call Qcomp_subr_trampoline_install, even tho it's a case where it should not be necessary, and I suspect this can lead to the kind of problems mentioned above, if we do something like (defalias 'foo (symbol-function 'bar)) (fset 'foo ) where native calls to `bar` could end up redirected to the definition of `foo` :-( Stefan