[Top][All Lists]

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

Re: Change in files.el

From: Dmitry Gutov
Subject: Re: Change in files.el
Date: Sat, 28 Jan 2017 18:31:29 +0300
User-agent: Mozilla/5.0 (X11; Linux x86_64; rv:51.0) Gecko/20100101 Thunderbird/51.0

On 28.01.2017 17:57, Eli Zaretskii wrote:

These sound minor to me (and the last two are also possible without
the requirement, AFAIU).  By contrast, insisting on a function value
instead of the default nil forces me to go through at least one more
level of indirection when I need to understand what happens in a
function that references such variables, which sounds like a more
serious trouble from my POV.

It's just one more level of indirection. We routinely deal with dozens of them. This above rule should just be adhered consistently, and the indirection won't be a surprise every time.

On the plus side, you might get a smaller function that calls the -default one, because some code will be extracted.

Finally, the default value of save-some-buffers-default-predicate can be #'ignore or #'identity (it's either this, or the previous paragraph, I'm not familiar with the code enough to be sure).

I was up to my neck in this when I
needed to document all the various optional behaviors implemented in
isearch.el, and bumped into similar issues several times elsewhere.

isearch.el and etags.el have more egregious problems, such as extensive use of dynamic bindings.

reply via email to

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