emacs-devel
[Top][All Lists]
Advanced

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: master 8f03888: * lisp/gnus/gnus-art.el: Fix up compiler warnings.


From: Stefan Monnier
Subject: Re: master 8f03888: * lisp/gnus/gnus-art.el: Fix up compiler warnings.
Date: Thu, 15 Jan 2015 17:44:36 -0500
User-agent: Gnus/5.13 (Gnus v5.13) Emacs/25.0.50 (gnu/linux)

> Looking at the macro, it looks like it tries to ensure that the buffer
> is unibyte, executes the form, and then returns the buffer to its
> previous byteness state?

Right, and this makes no sense.  As a general rule the unibyte/multibyte
state of a buffer should only be changed when the buffer is empty.
Anything else is just a gross hack that will sooner or later bite you.

> Looking at the callers, it seems like that's what they want, although
> I'm not sure.

The problem is that "change the buffer to uni/multibyte" doesn't itself
have a clear meaning, so yes: it's not clear what they want *because*
they use this macro.

It'll have to be fixed by hand, one by one, either by understanding
better what the code needs, or if that's too hard, by trial-and-error
(and adding corresponding tests).


        Stefan



reply via email to

[Prev in Thread] Current Thread [Next in Thread]