From mboxrd@z Thu Jan 1 00:00:00 1970 Path: news.gmane.io!.POSTED.ciao.gmane.io!not-for-mail From: Juri Linkov Newsgroups: gmane.emacs.bugs Subject: bug#39597: 27.0.60: M-x occur adds fontification to fundamental-mode Date: Tue, 18 Feb 2020 02:12:32 +0200 Organization: LINKOV.NET Message-ID: <8736b8eosv.fsf@mail.linkov.net> References: <87imk960qb.fsf@gmail.com> Mime-Version: 1.0 Content-Type: text/plain Injection-Info: ciao.gmane.io; posting-host="ciao.gmane.io:159.69.161.202"; logging-data="30113"; mail-complaints-to="usenet@ciao.gmane.io" User-Agent: Gnus/5.13 (Gnus v5.13) Emacs/28.0.50 (x86_64-pc-linux-gnu) Cc: 39597@debbugs.gnu.org, Stefan Monnier To: =?UTF-8?Q?K=C3=A9vin?= Le Gouguec Original-X-From: bug-gnu-emacs-bounces+geb-bug-gnu-emacs=m.gmane-mx.org@gnu.org Tue Feb 18 01:16:16 2020 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 1j3qYi-0007fm-0i for geb-bug-gnu-emacs@m.gmane-mx.org; Tue, 18 Feb 2020 01:16:16 +0100 Original-Received: from localhost ([::1]:54902 helo=lists1p.gnu.org) by lists.gnu.org with esmtp (Exim 4.90_1) (envelope-from ) id 1j3qYg-0008MW-Pz for geb-bug-gnu-emacs@m.gmane-mx.org; Mon, 17 Feb 2020 19:16:15 -0500 Original-Received: from eggs.gnu.org ([2001:470:142:3::10]:37886) by lists.gnu.org with esmtp (Exim 4.90_1) (envelope-from ) id 1j3qYW-0008Lh-8w for bug-gnu-emacs@gnu.org; Mon, 17 Feb 2020 19:16:05 -0500 Original-Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.71) (envelope-from ) id 1j3qYV-0001aT-A5 for bug-gnu-emacs@gnu.org; Mon, 17 Feb 2020 19:16:04 -0500 Original-Received: from debbugs.gnu.org ([209.51.188.43]:33415) by eggs.gnu.org with esmtps (TLS1.0:RSA_AES_128_CBC_SHA1:16) (Exim 4.71) (envelope-from ) id 1j3qYV-0001aM-75 for bug-gnu-emacs@gnu.org; Mon, 17 Feb 2020 19:16:03 -0500 Original-Received: from Debian-debbugs by debbugs.gnu.org with local (Exim 4.84_2) (envelope-from ) id 1j3qYV-0000tM-3T for bug-gnu-emacs@gnu.org; Mon, 17 Feb 2020 19:16:03 -0500 X-Loop: help-debbugs@gnu.org Resent-From: Juri Linkov Original-Sender: "Debbugs-submit" Resent-CC: bug-gnu-emacs@gnu.org Resent-Date: Tue, 18 Feb 2020 00:16:03 +0000 Resent-Message-ID: Resent-Sender: help-debbugs@gnu.org X-GNU-PR-Message: followup 39597 X-GNU-PR-Package: emacs Original-Received: via spool by 39597-submit@debbugs.gnu.org id=B39597.15819849193358 (code B ref 39597); Tue, 18 Feb 2020 00:16:03 +0000 Original-Received: (at 39597) by debbugs.gnu.org; 18 Feb 2020 00:15:19 +0000 Original-Received: from localhost ([127.0.0.1]:39386 helo=debbugs.gnu.org) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1j3qXn-0000s6-HO for submit@debbugs.gnu.org; Mon, 17 Feb 2020 19:15:19 -0500 Original-Received: from bumble.birch.relay.mailchannels.net ([23.83.209.25]:64324) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1j3qXm-0000ry-Bs for 39597@debbugs.gnu.org; Mon, 17 Feb 2020 19:15:18 -0500 X-Sender-Id: dreamhost|x-authsender|jurta@jurta.org Original-Received: from relay.mailchannels.net (localhost [127.0.0.1]) by relay.mailchannels.net (Postfix) with ESMTP id 523E222C62; Tue, 18 Feb 2020 00:15:17 +0000 (UTC) Original-Received: from pdx1-sub0-mail-a38.g.dreamhost.com (100-96-206-172.trex.outbound.svc.cluster.local [100.96.206.172]) (Authenticated sender: dreamhost) by relay.mailchannels.net (Postfix) with ESMTPA id 943D922C47; Tue, 18 Feb 2020 00:15:16 +0000 (UTC) X-Sender-Id: dreamhost|x-authsender|jurta@jurta.org Original-Received: from pdx1-sub0-mail-a38.g.dreamhost.com ([TEMPUNAVAIL]. [64.90.62.162]) (using TLSv1.2 with cipher DHE-RSA-AES256-GCM-SHA384) by 0.0.0.0:2500 (trex/5.18.5); Tue, 18 Feb 2020 00:15:17 +0000 X-MC-Relay: Neutral X-MailChannels-SenderId: dreamhost|x-authsender|jurta@jurta.org X-MailChannels-Auth-Id: dreamhost X-Inform-Occur: 527e49fc1adae7e9_1581984917014_172547015 X-MC-Loop-Signature: 1581984917013:4034695155 X-MC-Ingress-Time: 1581984917013 Original-Received: from pdx1-sub0-mail-a38.g.dreamhost.com (localhost [127.0.0.1]) by pdx1-sub0-mail-a38.g.dreamhost.com (Postfix) with ESMTP id 123FAB26FE; Mon, 17 Feb 2020 16:15:12 -0800 (PST) DKIM-Signature: v=1; a=rsa-sha1; c=relaxed; d=linkov.net; h=from:to:cc :subject:references:date:in-reply-to:message-id:mime-version :content-type; s=linkov.net; bh=N3b5Wsog2d0EX6T2FPm4Rv3+XoY=; b= GykIv/UILG+lMflcjKUpjHw3ic5POp+7gx8KmZY2CKxGO2SbDfxOYjql/893nllZ YZbbrS7DqYpSFQ3TCBWb9h1tVRWMEAdlLZa2w+ZAEuCw42Ynqv/KZqLVi9xW3BT/ MayWyMIRtQ72xKlF49sxEEBsTfEa8nm+tCwbJF29aBI= Original-Received: from localhost.linkov.net (m91-129-103-27.cust.tele2.ee [91.129.103.27]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) (Authenticated sender: jurta@jurta.org) by pdx1-sub0-mail-a38.g.dreamhost.com (Postfix) with ESMTPSA id 431A6B27A4; Mon, 17 Feb 2020 16:15:08 -0800 (PST) X-DH-BACKEND: pdx1-sub0-mail-a38 In-Reply-To: <87imk960qb.fsf@gmail.com> ("=?UTF-8?Q?K=C3=A9vin?= Le Gouguec"'s message of "Fri, 14 Feb 2020 09:18:20 +0100") X-VR-OUT-STATUS: OK X-VR-OUT-SCORE: -100 X-VR-OUT-SPAMCAUSE: gggruggvucftvghtrhhoucdtuddrgedugedrjeejgddulecutefuodetggdotefrodftvfcurfhrohhfihhlvgemucggtfgfnhhsuhgsshgtrhhisggvpdfftffgtefojffquffvnecuuegrihhlohhuthemuceftddtnecusecvtfgvtghiphhivghnthhsucdlqddutddtmdenucfjughrpefhvffuohhfffgjkfgfgggtsehttdertddtredtnecuhfhrohhmpefluhhrihcunfhinhhkohhvuceojhhurhhisehlihhnkhhovhdrnhgvtheqnecukfhppeeluddruddvledruddtfedrvdejnecuvehluhhsthgvrhfuihiivgeptdenucfrrghrrghmpehmohguvgepshhmthhppdhhvghloheplhhotggrlhhhohhsthdrlhhinhhkohhvrdhnvghtpdhinhgvthepledurdduvdelrddutdefrddvjedprhgvthhurhhnqdhprghthheplfhurhhiucfnihhnkhhovhcuoehjuhhriheslhhinhhkohhvrdhnvghtqedpmhgrihhlfhhrohhmpehjuhhriheslhhinhhkohhvrdhnvghtpdhnrhgtphhtthhopehkvghvihhnrdhlvghgohhughhuvggtsehgmhgrihhlrdgtohhm X-BeenThere: debbugs-submit@debbugs.gnu.org X-Mailman-Version: 2.1.18 Precedence: list X-detected-operating-system: by eggs.gnu.org: GNU/Linux 2.2.x-3.x [generic] X-Received-From: 209.51.188.43 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:176171 Archived-At: > I think commit fb16313025 (2018-12-18T23:10:09Z!juri@linkov.net) had an > unintended side-effect on fundamental-mode. From emacs -Q: This commit contains this change: diff --git a/lisp/replace.el b/lisp/replace.el index dcae12e9b7..b8f231eb55 100644 --- a/lisp/replace.el +++ b/lisp/replace.el @@ -1907,10 +1907,8 @@ occur-engine global-matches))) (defun occur-engine-line (beg end &optional keep-props) - (if (and keep-props (if (boundp 'jit-lock-mode) jit-lock-mode) - (text-property-not-all beg end 'fontified t)) - (if (fboundp 'jit-lock-fontify-now) - (jit-lock-fontify-now beg end))) + (if (and keep-props font-lock-mode) + (font-lock-ensure beg end)) (if (and keep-props (not (eq occur-excluded-properties t))) (let ((str (buffer-substring beg end))) (remove-list-of-text-properties > - C-x b repro RET > - foo RET "bar" RET baz > - M-s o . RET > > In emacs 26.3, the Occur buffer pops up and not much else happens; > starting with emacs 27, font-lock-string-face is applied to "bar". > > I haven't dug much more than that; FWIW however, emacs 26.3 already > applied font-lock-string-face to double-quoted strings when running > (font-lock-ensure) in a fundamental buffer, so maybe the right fix > belongs e.g. somewhere in font-lock-set-defaults? Stefan, could you suggest what to do with font-lock-ensure to not highlight double-quoted strings in fundamental-mode?