GNU bug report logs - #49661
(patches) Improve docs for revert-buffer and auto-revert-mode

Previous Next

Package: emacs;

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

Date: Tue, 20 Jul 2021 13:23:02 UTC

Severity: normal

Fixed in version 28.1

Done: Lars Ingebrigtsen <larsi <at> gnus.org>

Bug is archived. No further changes may be made.

To add a comment to this bug, you must first unarchive it, by sending
a message to control AT debbugs.gnu.org, with unarchive 49661 in the body.
You can then email your comments to 49661 AT debbugs.gnu.org in the normal way.

Toggle the display of automated, internal messages from the tracker.

View this report as an mbox folder, status mbox, maintainer mbox


Report forwarded to bug-gnu-emacs <at> gnu.org:
bug#49661; Package emacs. (Tue, 20 Jul 2021 13:23:02 GMT) Full text and rfc822 format available.

Acknowledgement sent to Konstantin Kharlamov <hi-angel <at> yandex.ru>:
New bug report received and forwarded. Copy sent to bug-gnu-emacs <at> gnu.org. (Tue, 20 Jul 2021 13:23:02 GMT) Full text and rfc822 format available.

Message #5 received at submit <at> debbugs.gnu.org (full text, mbox):

From: Konstantin Kharlamov <hi-angel <at> yandex.ru>
To: bug-gnu-emacs <at> gnu.org
Subject: (patches) Improve docs for revert-buffer and auto-revert-mode
Date: Tue, 20 Jul 2021 16:21:57 +0300
[Message part 1 (text/plain, inline)]
Patches attached.

The reasoning behind the changes as follow:

1. `revert-buffer`: its current docs only mention that it tries its best to keep markers, but it does not mention that it may fail to do so, and that there is a slower but better alternative to this function. The lack of it being mentioned resulted in me researching its code down to C, and also another maintainer testing a bug, and yet another contributor writing up a large post about the new alternative revert functions…¹ All of that could've been avoided had `revert-function` referred to the new alternative, so that's what the patch does.
2. `auto-revert-mode`: Even with the change in 1 it's still unclear how to make use of that for `auto-revert-mode`. It does not even mention that the mode may break markers, so a person would have to debug it and find out revert-buffer, which in turn mentions about the problem, but doesn't really mention how to fix the auto-revert-mode specifically. So let's save people time, and just have a paragraph about it as well.

1: https://github.com/magit/magit/issues/4442
[0001-Mention-that-revert-buffer-isn-t-best-for-markers-pr.patch (text/x-patch, attachment)]
[0002-Mention-that-auto-revert-mode-may-break-markers.patch (text/x-patch, attachment)]

Information forwarded to bug-gnu-emacs <at> gnu.org:
bug#49661; Package emacs. (Tue, 20 Jul 2021 14:41:02 GMT) Full text and rfc822 format available.

Message #8 received at 49661 <at> debbugs.gnu.org (full text, mbox):

From: Lars Ingebrigtsen <larsi <at> gnus.org>
To: Konstantin Kharlamov <hi-angel <at> yandex.ru>
Cc: 49661 <at> debbugs.gnu.org
Subject: Re: bug#49661: (patches) Improve docs for revert-buffer and
 auto-revert-mode
Date: Tue, 20 Jul 2021 16:39:54 +0200
Konstantin Kharlamov <hi-angel <at> yandex.ru> writes:

> Patches attached.

Thanks; applied to Emacs 28 (with some trivial white-space changes -- we
prefer two spaces after "." in doc strings).

-- 
(domestic pets only, the antidote for overdose, milk.)
   bloggy blog: http://lars.ingebrigtsen.no




bug marked as fixed in version 28.1, send any further explanations to 49661 <at> debbugs.gnu.org and Konstantin Kharlamov <hi-angel <at> yandex.ru> Request was from Lars Ingebrigtsen <larsi <at> gnus.org> to control <at> debbugs.gnu.org. (Tue, 20 Jul 2021 14:41:02 GMT) Full text and rfc822 format available.

bug archived. Request was from Debbugs Internal Request <help-debbugs <at> gnu.org> to internal_control <at> debbugs.gnu.org. (Wed, 18 Aug 2021 11:24:09 GMT) Full text and rfc822 format available.

This bug report was last modified 2 years and 252 days ago.

Previous Next


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