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#47049: [feature/native] macro-expansion cycle when compiling comp.el Date: Wed, 10 Mar 2021 18:17:15 +0200 Message-ID: <83pn07nfuc.fsf@gnu.org> References: <83zgzbnm7i.fsf@gnu.org> Injection-Info: ciao.gmane.io; posting-host="blaine.gmane.org:116.202.254.214"; logging-data="29091"; mail-complaints-to="usenet@ciao.gmane.io" Cc: 47049@debbugs.gnu.org To: Andrea Corallo , Stefan Monnier Original-X-From: bug-gnu-emacs-bounces+geb-bug-gnu-emacs=m.gmane-mx.org@gnu.org Wed Mar 10 17:39:43 2021 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 1lK1s6-0007OO-VP for geb-bug-gnu-emacs@m.gmane-mx.org; Wed, 10 Mar 2021 17:39:42 +0100 Original-Received: from localhost ([::1]:53574 helo=lists1p.gnu.org) by lists.gnu.org with esmtp (Exim 4.90_1) (envelope-from ) id 1lK1s5-0000zI-UK for geb-bug-gnu-emacs@m.gmane-mx.org; Wed, 10 Mar 2021 11:39:41 -0500 Original-Received: from eggs.gnu.org ([2001:470:142:3::10]:39866) by lists.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_256_GCM_SHA384:256) (Exim 4.90_1) (envelope-from ) id 1lK1X8-0004Bn-TN for bug-gnu-emacs@gnu.org; Wed, 10 Mar 2021 11:18:02 -0500 Original-Received: from debbugs.gnu.org ([209.51.188.43]:40133) by eggs.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_128_GCM_SHA256:128) (Exim 4.90_1) (envelope-from ) id 1lK1X8-0001Gq-Jp for bug-gnu-emacs@gnu.org; Wed, 10 Mar 2021 11:18:02 -0500 Original-Received: from Debian-debbugs by debbugs.gnu.org with local (Exim 4.84_2) (envelope-from ) id 1lK1X8-0001N6-F3 for bug-gnu-emacs@gnu.org; Wed, 10 Mar 2021 11:18:02 -0500 X-Loop: help-debbugs@gnu.org Resent-From: Eli Zaretskii Original-Sender: "Debbugs-submit" Resent-CC: bug-gnu-emacs@gnu.org Resent-Date: Wed, 10 Mar 2021 16:18:02 +0000 Resent-Message-ID: Resent-Sender: help-debbugs@gnu.org X-GNU-PR-Message: followup 47049 X-GNU-PR-Package: emacs Original-Received: via spool by 47049-submit@debbugs.gnu.org id=B47049.16153930465230 (code B ref 47049); Wed, 10 Mar 2021 16:18:02 +0000 Original-Received: (at 47049) by debbugs.gnu.org; 10 Mar 2021 16:17:26 +0000 Original-Received: from localhost ([127.0.0.1]:51679 helo=debbugs.gnu.org) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1lK1WY-0001MI-IX for submit@debbugs.gnu.org; Wed, 10 Mar 2021 11:17:26 -0500 Original-Received: from eggs.gnu.org ([209.51.188.92]:50148) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1lK1WX-0001M5-Ku for 47049@debbugs.gnu.org; Wed, 10 Mar 2021 11:17:25 -0500 Original-Received: from fencepost.gnu.org ([2001:470:142:3::e]:36834) by eggs.gnu.org with esmtp (Exim 4.90_1) (envelope-from ) id 1lK1WS-00015s-4d; Wed, 10 Mar 2021 11:17:20 -0500 Original-Received: from 84.94.185.95.cable.012.net.il ([84.94.185.95]:1581 helo=home-c4e4a596f7) by fencepost.gnu.org with esmtpsa (TLS1.2:RSA_AES_256_CBC_SHA1:256) (Exim 4.82) (envelope-from ) id 1lK1WO-0001Oj-Nb; Wed, 10 Mar 2021 11:17:18 -0500 In-Reply-To: (message from Andrea Corallo on Wed, 10 Mar 2021 16:05:10 +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" Xref: news.gmane.io gmane.emacs.bugs:202014 Archived-At: > From: Andrea Corallo > Cc: 47049@debbugs.gnu.org > Date: Wed, 10 Mar 2021 16:05:10 +0000 > > > I made some local modifications in comp.el, and used that modified > > comp.el for a while (by loading it manually at run time) to debug some > > problem. Then I undid those local modifications of comp.el (by saying > > "git checkout") and said "make" to rebuild Emacs. And I see this: > > > > ELC emacs-lisp/comp.elc > > Warning: Eager macro-expansion skipped due to cycle: > > => (load "comp.el") => (macroexpand-all (defalias 'comp-add-call-cstr )) => (macroexpand (comp-loop-insn-in-block )) => (load "comp.el") > > > > Why does this happen? > > I'm not sure, but I can reproduce it. > > I guess (just a guess) it might be because `comp-add-call-cstr' is using > a macro `comp-loop-insn-in-block' that is expanding with a > `cl-symbol-macrolet' inside? (no idea why this should be a problem). > > > could it be that while comp.el was modified it > > got native-compiled, and now that inconsistent comp.eln gets in the > > way? > > I think this has not to do specifically with native compilation. > > I see it goes away removing '(setq load-prefer-newer t)' from the > invocation tho. > > Perhaps somebody already more into the macro expansion business might > have some suggestion. Stefan, can you help, please?