GNU bug report logs - #50762
diff-update-on-the-fly doesn't update hunk headers while regexp-replacing lines

Previous Next

Package: emacs;

Reported by: Konstantin Kharlamov <hi-angel <at> yandex.ru>

Date: Thu, 23 Sep 2021 15:58:01 UTC

Severity: normal

Done: Konstantin Kharlamov <Hi-Angel <at> yandex.ru>

Bug is archived. No further changes may be made.

Full log


View this message in rfc822 format

From: help-debbugs <at> gnu.org (GNU bug Tracking System)
To: Konstantin Kharlamov <Hi-Angel <at> yandex.ru>
Cc: tracker <at> debbugs.gnu.org
Subject: bug#50762: closed (diff-update-on-the-fly doesn't update hunk
 headers while regexp-replacing lines)
Date: Thu, 22 May 2025 08:47:02 +0000
[Message part 1 (text/plain, inline)]
Your message dated Thu, 22 May 2025 11:46:46 +0300
with message-id <411446547bfeef624a04e3790cd1ddbb0eeeb84e.camel <at> yandex.ru>
and subject line 
has caused the debbugs.gnu.org bug report #50762,
regarding diff-update-on-the-fly doesn't update hunk headers while regexp-replacing lines
to be marked as done.

(If you believe you have received this mail in error, please contact
help-debbugs <at> gnu.org.)


-- 
50762: https://debbugs.gnu.org/cgi/bugreport.cgi?bug=50762
GNU Bug Tracking System
Contact help-debbugs <at> gnu.org with problems
[Message part 2 (message/rfc822, inline)]
From: Konstantin Kharlamov <hi-angel <at> yandex.ru>
To: bug-gnu-emacs <at> gnu.org
Subject: diff-update-on-the-fly doesn't update hunk headers while
 regexp-replacing lines
Date: Thu, 23 Sep 2021 18:56:48 +0300
As title says. I think due to this bug it would make sense to have diff-update-on-the-fly set to nil by default.

# Steps to reproduce

1. In Emacs repo, `git checkout 72f8a9dd08132119a` (arbitrary commit for the sake of testcase) 
2. Create a patch from Emacs repo with `git format-patch -1 --stdout > /tmp/1.patch`, open it.
3. Note that 1st hunk has value `-2883,10 +2883,13`
4. Use regexp-replace aka `C-M-%` with `(.*^J\+.* → line1` (please replace ^J here with C-q C-j)
5. When asked for matches, press `!`, so all lines are replaced
6. Look at the first hunk again

## Expected

It changes its value to recalculation that should be happening

## Actual

It still has the older value, no recalculation has happened.



[Message part 3 (message/rfc822, inline)]
From: Konstantin Kharlamov <Hi-Angel <at> yandex.ru>
To: 50762-done <at> debbugs.gnu.org
Date: Thu, 22 May 2025 11:46:46 +0300
Thus, closing


This bug report was last modified 35 days ago.

Previous Next


GNU bug tracking system
Copyright (C) 1999 Darren O. Benham, 1997,2003 nCipher Corporation Ltd, 1994-97 Ian Jackson.