bug-gnu-emacs
[Top][All Lists]
Advanced

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

bug#27158: 25.2; Eliminating old usage of completing-read from built-in


From: Dmitry Gutov
Subject: bug#27158: 25.2; Eliminating old usage of completing-read from built-in files
Date: Thu, 1 Jun 2017 01:41:14 +0300
User-agent: Mozilla/5.0 (X11; Linux x86_64; rv:54.0) Gecko/20100101 Thunderbird/54.0

On 5/31/17 6:44 PM, Ryan Thompson wrote:

The problem is that there is no one solution that floats everyone's boat. Whatever you choose, someone sinks (i.e. has broken completion). The only way to float everyone's boat is for the completion function to check which function called it and then change its behavior based on prior knowledge of what each caller expects.

Or ask the "sane" callers to call a different, new function.

I think we should change the calling convention of completion-read-function (while keeping completing-read the same, it will call completing-read-function passing (or DEF "") as the default).

The new completing-read-function can choose to get rid of the legacy behavior; this variable is not as encumbered by backward compatibility requirement as completing-read itself. Hopefully updating completing-read-default won't be too difficult.

Then we introduce completing-read-strict (as one naming example) which calls completing-read-function without the implicit default.

Going back to the beginning of this bug report, the new patch would convert all uses of completing-read that don't expect "" as the default to use completing-read-strict.

See also this previous discussion: http://lists.gnu.org/archive/html/emacs-devel/2016-01/msg01682.html





reply via email to

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