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#64232: 28.2; Incorrect(?) byte compilation warning about =?UTF-8?Q?=E2=80=98ansi-color-apply-on-region=E2=80=99?= Date: Thu, 06 Jul 2023 09:43:44 +0300 Message-ID: <83ttuhilpb.fsf@gnu.org> References: <874jmzs23h.wl-zack@owlfolio.org> <83o7l5yt9k.fsf@gnu.org> <9c38fe1a-ee3a-4b6d-aaa7-33aa4909e331@app.fastmail.com> <87jzvoe3qk.fsf@web.de> <87wmznhr1q.fsf@web.de> <875y751tsz.fsf@web.de> <83wmzlsd4u.fsf@gnu.org> Mime-Version: 1.0 Content-Type: text/plain; charset=utf-8 Content-Transfer-Encoding: 8bit Injection-Info: ciao.gmane.io; posting-host="blaine.gmane.org:116.202.254.214"; logging-data="12659"; mail-complaints-to="usenet@ciao.gmane.io" Cc: 64232@debbugs.gnu.org To: michael_heerdegen@web.de, zack@owlfolio.org, monnier@iro.umontreal.ca Original-X-From: bug-gnu-emacs-bounces+geb-bug-gnu-emacs=m.gmane-mx.org@gnu.org Thu Jul 06 08:44:17 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 1qHIiu-00034y-TF for geb-bug-gnu-emacs@m.gmane-mx.org; Thu, 06 Jul 2023 08:44:17 +0200 Original-Received: from localhost ([::1] helo=lists1p.gnu.org) by lists.gnu.org with esmtp (Exim 4.90_1) (envelope-from ) id 1qHIig-0000Vi-UO; Thu, 06 Jul 2023 02:44:02 -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 1qHIig-0000VJ-13 for bug-gnu-emacs@gnu.org; Thu, 06 Jul 2023 02:44:02 -0400 Original-Received: from debbugs.gnu.org ([209.51.188.43]) by eggs.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_128_GCM_SHA256:128) (Exim 4.90_1) (envelope-from ) id 1qHIif-0005F5-NJ for bug-gnu-emacs@gnu.org; Thu, 06 Jul 2023 02:44:01 -0400 Original-Received: from Debian-debbugs by debbugs.gnu.org with local (Exim 4.84_2) (envelope-from ) id 1qHIif-0002qe-IP for bug-gnu-emacs@gnu.org; Thu, 06 Jul 2023 02:44:01 -0400 X-Loop: help-debbugs@gnu.org Resent-From: Eli Zaretskii Original-Sender: "Debbugs-submit" Resent-CC: bug-gnu-emacs@gnu.org Resent-Date: Thu, 06 Jul 2023 06:44:01 +0000 Resent-Message-ID: Resent-Sender: help-debbugs@gnu.org X-GNU-PR-Message: followup 64232 X-GNU-PR-Package: emacs Original-Received: via spool by 64232-submit@debbugs.gnu.org id=B64232.168862583310898 (code B ref 64232); Thu, 06 Jul 2023 06:44:01 +0000 Original-Received: (at 64232) by debbugs.gnu.org; 6 Jul 2023 06:43:53 +0000 Original-Received: from localhost ([127.0.0.1]:39371 helo=debbugs.gnu.org) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1qHIiW-0002pc-TM for submit@debbugs.gnu.org; Thu, 06 Jul 2023 02:43:53 -0400 Original-Received: from eggs.gnu.org ([209.51.188.92]:40452) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1qHIiU-0002p4-Hg for 64232@debbugs.gnu.org; Thu, 06 Jul 2023 02:43:51 -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 1qHIiO-0004Fa-P6; Thu, 06 Jul 2023 02:43:44 -0400 DKIM-Signature: v=1; a=rsa-sha256; q=dns/txt; c=relaxed/relaxed; d=gnu.org; s=fencepost-gnu-org; h=MIME-version:References:Subject:In-Reply-To:To:From: Date; bh=L6+mwFQ2ajVXvYe+CMyz5F3Sau7fUOdg6xxM1fKXFlU=; b=Q1l2H4Pvgs2b/zLkhyxr +gtHSapZmfhrDYajoHVUzzlAzWB8M5G1AR0h0Gst/aMUHxymQ26gDFcCp+WYA72d+yEbT56Ev6DHP NzUI/bVEyWhqHxoKgGjO2IXzKhodr/6FV7B7sn2NQDlRPNQ2lCwAEzytEC8ydvn7DOGwKXxpxquCs c3kX6BtWrxz1sOBZxi/NixXSa/RSsmR847j9sZ/8/mxg3GAq0NAySEWCFQOqoOL4JshcIXBVh4pz2 rrCJCApClvQ+jJvdSuUJOJH7lQg5BbPInV96L2o4LJgaHEOJ+rXSV5S3bVJDyMBUZ5WGpn/QWXNzX aaBOW9SqVWjAqA==; 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 1qHIiN-0007dQ-Pf; Thu, 06 Jul 2023 02:43:44 -0400 In-Reply-To: <83wmzlsd4u.fsf@gnu.org> (message from Eli Zaretskii on Fri, 30 Jun 2023 09:00:33 +0300) 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:264653 Archived-At: Ping! Any reasons this was not yet installed on master? > Cc: zack@owlfolio.org, 64232@debbugs.gnu.org, monnier@iro.umontreal.ca > Date: Fri, 30 Jun 2023 09:00:33 +0300 > From: Eli Zaretskii > > > From: Michael Heerdegen > > Cc: 64232@debbugs.gnu.org, eliz@gnu.org, zack@owlfolio.org > > Date: Fri, 30 Jun 2023 06:02:36 +0200 > > > > Stefan Monnier writes: > > > > > Someoneā„¢ should sit down and figure out how to make `bytecomp.el` keep > > > track of those things more reliably/predictably. > > > In the mean time, maybe we can simply tweak `byte-compile-eval` so it > > > never adds to `byte-compile-noruntime-functions` functions which have > > > already been seen/declared during the current compilation? > > > > > > > > > diff --git a/lisp/emacs-lisp/bytecomp.el b/lisp/emacs-lisp/bytecomp.el > > > index 99202185d8d..cfec4b3be06 100644 > > > --- a/lisp/emacs-lisp/bytecomp.el > > > +++ b/lisp/emacs-lisp/bytecomp.el > > > @@ -1128,7 +1128,8 @@ byte-compile-eval > > > ;; we arguably should add it to b-c-noruntime-functions, > > > ;; but it's not clear it's worth the trouble > > > ;; trying to recognize that case. > > > - (unless (get f 'function-history) > > > + (unless (or (get f 'function-history) > > > + (assq f byte-compile-function-environment)) > > > (push f byte-compile-noruntime-functions))))))))))))) > > > > Seems appropriate (and fixes this bug). > > > > Actually with that patch the situation looks already quite ok'ish to me. > > Please install this on master, and thanks. > > > >