[Top][All Lists]

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

Re: [PATCH] `completing-read`: Add `group-function` support to completio

From: Daniel Mendler
Subject: Re: [PATCH] `completing-read`: Add `group-function` support to completion metadata (REVISED PATCH VERSION 2)
Date: Tue, 11 May 2021 21:46:17 +0200

On 5/11/21 9:22 PM, Eli Zaretskii wrote:
> Why not provide a defcustom that can accept both simple value, for the
> most popular sort methods, and also allow function values for advanced
> users?

This is exactly what I did. If the user selects "No sorting" the value
identity is taken and if the value "Sort alphabetically" is selected,
the value completions-group-sort-alphabetically is taken. There is no
point in introducing another symbolic indirection. We could add more
options in case some more reasonable group sortings come up. There is no
need for a newbie to directly manipulate functions.

> Thanks.  Now try putting yourself into the shoes of a newbie and try
> imagining what can he/she make out of this doc string.  "Function
> taking and returning an alist"? really?

The snippet which I just sent is a proposal. Up to now there has been a
bit of back and forth of how the grouping feature is best implemented.
Under these circumstances it does not make sense to send a fully
polished patch each time. But by now the discussion seems to have
somehow concluded, or at least I interpret that there is some agreement
between the participants of the discussion which was mostly Juri,
Stefan, Dmitry and myself.


reply via email to

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