GNU bug report logs - #64596
30.0.50; On FIXME: in src/buffer.c:1481 (force-mode-line-update)

Previous Next

Package: emacs;

Reported by: Ihor Radchenko <yantar92 <at> posteo.net>

Date: Thu, 13 Jul 2023 13:01:02 UTC

Severity: normal

Found in version 30.0.50

Full log


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

From: Ihor Radchenko <yantar92 <at> posteo.net>
To: Eli Zaretskii <eliz <at> gnu.org>
Cc: monnier <at> iro.umontreal.ca, 64596 <at> debbugs.gnu.org
Subject: Re: bug#64596: 30.0.50; On FIXME: in src/buffer.c:1481
 (force-mode-line-update)
Date: Sun, 16 Jul 2023 20:12:34 +0000
Eli Zaretskii <eliz <at> gnu.org> writes:

>> From: Ihor Radchenko <yantar92 <at> posteo.net>
>> Cc: Eli Zaretskii <eliz <at> gnu.org>, 64596 <at> debbugs.gnu.org
>> Date: Sun, 16 Jul 2023 10:22:38 +0000
>> 
>> Stefan Monnier <monnier <at> iro.umontreal.ca> writes:
>> 
>> >>   . prevent_redisplay_optimizations_p flag of a buffer
>> >>   . must_be_updated_p flag of a window
>> >
>> > No idea what these mean.
>> > The name `must_be_updated_p` makes it sound to me like it's redundant
>> > with the `redisplay` flag above.
>> 
>> I agree about must_be_updated_p. I had exactly same though that it is
>> redundant with redisplay flag when reading the code.
>
> Actually, the must_be_updated_p flag is not for xdisp.c, i.e. not for
> redisplay_window and its subroutines.  It is for update_window, which
> is the last, 3rd, stage of a redisplay cycle, most of the code of
> which is in dispnew.c.  That's where the newly computed glyph matrix
> of a window is compared to its current matrix, and Emacs decides what,
> if anything, should be actually written to the glass.  What happens
> with this flag is that redisplay_window and friends _set_ this flag
> for windows that dispnew.c _must_ update.  The flag is tested in
> dispnew.c, see there for its use and comments.

I see.

I have to say that these flag names are very disorienting.
I have first seen this flag while reading xdisp.c, and it was not obvious
at all what it does.

The name must_be_updated has no link with glyph matrix terminology, and
it is only explained in the commentary in window.h. But then, at the
point of reading commentary I was not yet familiar with xdisp...

-- 
Ihor Radchenko // yantar92,
Org mode contributor,
Learn more about Org mode at <https://orgmode.org/>.
Support Org development at <https://liberapay.com/org-mode>,
or support my work at <https://liberapay.com/yantar92>




This bug report was last modified 1 year and 328 days ago.

Previous Next


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