From mboxrd@z Thu Jan 1 00:00:00 1970 Path: news.gmane.io!.POSTED.blaine.gmane.org!not-for-mail From: Augusto Stoffel Newsgroups: gmane.emacs.bugs Subject: bug#53126: 29.0.50; [PATCH] Lazy highlight/count when reading query-replace string, etc. Date: Wed, 23 Mar 2022 21:30:24 +0100 Message-ID: <87czic76ov.fsf@gmail.com> References: <87sftyweb2.fsf@gmail.com> <86k0f9xnrn.fsf@mail.linkov.net> <87tuedp6pl.fsf@gmail.com> <861r1g7n3b.fsf@mail.linkov.net> <87o84jcx5x.fsf@gmail.com> <8635lvif0r.fsf@mail.linkov.net> <87mtidip1w.fsf@gmail.com> <86sfrjia5u.fsf@mail.linkov.net> <87ilseyks7.fsf@gmail.com> <868rt9wwji.fsf@mail.linkov.net> <871qz11w82.fsf@gmail.com> <86ilsc7e31.fsf@mail.linkov.net> <87tubwz9dd.fsf@gmail.com> <86sfrc2zr8.fsf@mail.linkov.net> <87o820iedv.fsf@gmail.com> <86h77s2wqo.fsf@mail.linkov.net> <87k0coibrt.fsf@gmail.com> <864k3o3j1g.fsf@mail.linkov.net> <87k0ck7b55.fsf@gmail.com> <86lex01m4a.fsf@mail.linkov.net> <86ee2s1lip.fsf@mail.linkov.net> Mime-Version: 1.0 Content-Type: text/plain Injection-Info: ciao.gmane.io; posting-host="blaine.gmane.org:116.202.254.214"; logging-data="39024"; mail-complaints-to="usenet@ciao.gmane.io" User-Agent: Gnus/5.13 (Gnus v5.13) Emacs/28.0.91 (gnu/linux) Cc: 53126@debbugs.gnu.org To: Juri Linkov Original-X-From: bug-gnu-emacs-bounces+geb-bug-gnu-emacs=m.gmane-mx.org@gnu.org Wed Mar 23 21:31:24 2022 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 1nX7db-000A00-5F for geb-bug-gnu-emacs@m.gmane-mx.org; Wed, 23 Mar 2022 21:31:23 +0100 Original-Received: from localhost ([::1]:49210 helo=lists1p.gnu.org) by lists.gnu.org with esmtp (Exim 4.90_1) (envelope-from ) id 1nX7dZ-0004L5-Uf for geb-bug-gnu-emacs@m.gmane-mx.org; Wed, 23 Mar 2022 16:31:21 -0400 Original-Received: from eggs.gnu.org ([209.51.188.92]:39154) by lists.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_256_GCM_SHA384:256) (Exim 4.90_1) (envelope-from ) id 1nX7dG-0004KB-Bs for bug-gnu-emacs@gnu.org; Wed, 23 Mar 2022 16:31:06 -0400 Original-Received: from debbugs.gnu.org ([209.51.188.43]:52271) by eggs.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_128_GCM_SHA256:128) (Exim 4.90_1) (envelope-from ) id 1nX7dG-0008CK-3H for bug-gnu-emacs@gnu.org; Wed, 23 Mar 2022 16:31:02 -0400 Original-Received: from Debian-debbugs by debbugs.gnu.org with local (Exim 4.84_2) (envelope-from ) id 1nX7dF-00027y-Qg for bug-gnu-emacs@gnu.org; Wed, 23 Mar 2022 16:31:01 -0400 X-Loop: help-debbugs@gnu.org Resent-From: Augusto Stoffel Original-Sender: "Debbugs-submit" Resent-CC: bug-gnu-emacs@gnu.org Resent-Date: Wed, 23 Mar 2022 20:31:01 +0000 Resent-Message-ID: Resent-Sender: help-debbugs@gnu.org X-GNU-PR-Message: followup 53126 X-GNU-PR-Package: emacs X-GNU-PR-Keywords: patch Original-Received: via spool by 53126-submit@debbugs.gnu.org id=B53126.16480674348138 (code B ref 53126); Wed, 23 Mar 2022 20:31:01 +0000 Original-Received: (at 53126) by debbugs.gnu.org; 23 Mar 2022 20:30:34 +0000 Original-Received: from localhost ([127.0.0.1]:46168 helo=debbugs.gnu.org) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1nX7cn-00027C-Vy for submit@debbugs.gnu.org; Wed, 23 Mar 2022 16:30:34 -0400 Original-Received: from mail-ed1-f47.google.com ([209.85.208.47]:35605) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1nX7cm-00026y-4k for 53126@debbugs.gnu.org; Wed, 23 Mar 2022 16:30:32 -0400 Original-Received: by mail-ed1-f47.google.com with SMTP id k10so3272589edj.2 for <53126@debbugs.gnu.org>; Wed, 23 Mar 2022 13:30:32 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20210112; h=from:to:cc:subject:references:date:in-reply-to:message-id :user-agent:mime-version; bh=IqzZGPNRVNPWebmUYUGCCslJoHqh8sKV4OZD1dSzsHs=; b=npg1EFJuBTtRaY09UkhSbi3/k6ROgqmfo0io1Ni+BKhCthYG+lwb272TStKq/xwK5D 2h7FsJS0FGZ+DjeVXxRMi94pHxfaCmIFSHLTb6dXolZDdlM875/q5kWBJomw+cuZDWDF Pq/ScXZ0923MVWyjnsJ3NE0zwa2jF+FaqC4bE9PlSVXCQMqP/ojDG+3ZXBF0P18dzCsw fhN8eg+JnVEMUQxvobw4J20RphlfGbVfq85EChHsueJ1l2iFTly4r4gBgtqB5lX/4Gi1 cASir4pa7yl30L81PHI/txdfldaSswryD/kv8osM3U2tfXvfgF6SN+0j30BqDuQSjLJu eLyg== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20210112; h=x-gm-message-state:from:to:cc:subject:references:date:in-reply-to :message-id:user-agent:mime-version; bh=IqzZGPNRVNPWebmUYUGCCslJoHqh8sKV4OZD1dSzsHs=; b=NntXSB11z61HlhdWpUV65UDA6CLBOk9u9A7OVaTx9PNPZJqHL0CYCisx3MtMf21qf8 CpQ3BBsz3LC0O2ot62oEOFCg3NRTWMJEoDQZPd2A6lha1vIOx1CKB8g237ym56mE32cf 9MODq6z588BtJ3+2/j6MiCivYF2eMyWMUqlfzQISkQSQO5NI6bbreHeFTCwyk+6S9OpN gMl4at/C99ZJj+ppjosdeD/h2GJh+r9vAUxkRrf7TBzo8SGfjL69sU4+oDnm4dZr6BuY sHdDEZ51/1WHSUQjwkzoFhVGja4L6SLpyHPesOnKcBreeGf6wduAodKhZWWOtLHdS3wl NA2Q== X-Gm-Message-State: AOAM531vsoUgglFCKqv5d6BGlxfABrtJWGRqKfOTrq104DZHovKTGqGw 2yyZbKbnKPzL8GzdP5HEhJsylbGBqqE= X-Google-Smtp-Source: ABdhPJxF7SzIeKOlR6/fKV1DmtoyZKh0gTzKK2HI3/IJ6+ToO+RsHpn0z6QCLoiX6IKuMEu2r5/TfQ== X-Received: by 2002:a05:6402:35d4:b0:419:64e3:4ad1 with SMTP id z20-20020a05640235d400b0041964e34ad1mr2532447edc.260.1648067426078; Wed, 23 Mar 2022 13:30:26 -0700 (PDT) Original-Received: from ars3 ([2a02:8109:8ac0:56d0::758e]) by smtp.gmail.com with ESMTPSA id b8-20020a056402350800b00419407f0dd9sm410005edd.0.2022.03.23.13.30.24 (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Wed, 23 Mar 2022 13:30:25 -0700 (PDT) In-Reply-To: <86ee2s1lip.fsf@mail.linkov.net> (Juri Linkov's message of "Wed, 23 Mar 2022 22:06:38 +0200") 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:228837 Archived-At: On Wed, 23 Mar 2022 at 22:06, Juri Linkov wrote: >>> + (with-minibuffer-selected-window >> >> Thanks, I confirm your patch fixes the problem. >> But before pushing it, I'd like to understand >> how your previous patches changed the order >> of the buffer list? Before your changes, >> (cadr (buffer-list)) returned the original buffer, >> but now it returns the minibuffer. > > Probably the buffer order is changed by > with-minibuffer-selected-window in > minibuffer-lazy-highlight--after-change. > This is fine, so I pushed your patch. FTR, I just tested and the culprit is not the with-minibuffer-selected-window from minibuffer-lazy-highlight--after-change (which makes sense, since that macro uses NORECORD internally), but rather the calls to `select-window' without NORECORD argument in isearch.el.