Subject: Re: bug#25807: 24.5; List-Directory closes with error when invalid path is typed instead of prompting the user to fix it

From: Eli Zaretskii <[email-masked]>
Date: Sat, 25 Mar 2017 22:45:14 +0300

> From: Andreas Politz <[email-masked]>
> Cc: Colin <[email-masked]>,  [email-masked]
> Date: Sat, 25 Mar 2017 20:28:18 +0100
> 
> Eli Zaretskii <[email-masked]> writes:
> 
> > [...] We are looking for a way to reject non-existing directories, but
> > accept existing ones and wildcards, when the user types RET in these
> > cases.
> 
> I think in order to do that we would have to figure out whether a given
> filename expands to some existing filenames or not, and this also for
> handled ones.  The last part of which seems to be difficult.

Why is the last part difficult?  directory-files already supports
that, doesn't it?  And completion examines matching files as part of
its thing, so I hoped there's already an option to get that for free.

> A more simpler and less general approach would be the addition of a
> user-option, i.e.  list-directory-use-wildcards.

The function in question already supports widlcards, so moving that
support to a new option would be a step backward, I think.