unofficial mirror of bug-gnu-emacs@gnu.org 
 help / color / mirror / code / Atom feed
From: Lars Ingebrigtsen <larsi@gnus.org>
To: Michael Heerdegen <michael_heerdegen@web.de>
Cc: Arash Esbati <arash@gnu.org>,
	Stefan Monnier <monnier@iro.umontreal.ca>,
	Drew Adams <drew.adams@oracle.com>,
	56380@debbugs.gnu.org
Subject: bug#56380: 29.0.50; completing-read: INITIAL-INPUT arg
Date: Tue, 05 Jul 2022 13:33:12 +0200	[thread overview]
Message-ID: <87v8sb4ww7.fsf@gnus.org> (raw)
In-Reply-To: <878rp9840g.fsf@web.de> (Michael Heerdegen's message of "Mon, 04 Jul 2022 14:18:55 +0200")

Michael Heerdegen <michael_heerdegen@web.de> writes:

> The docstring of `completing-read' says the argument INITIAL-INPUT is
> deprecated - yet there are over 30 nontrivial uses in Emacs' own Elisp
> sources.  So, although we currently don't want that this argument is
> used just to insert a default input, it's sometimes not possible to
> avoid using it.

[...]

> +  for POSITION.)  Don't use this argument to insert a default value --
> +  use DEF for that.  You can use INITIAL-INPUT, for example, to insert
> +  a prefix common to all completion candidates.  See
> +  `minibuffer-with-setup-hook' for a general method to prepare the
> +  minibuffer.

It's an improvement on the original text, but this makes it sound like
inserting a common prefix is something callers are expected to do.  (But
instead it's a super rare special case that virtually nobody would
actually do in practice.)  So I'd rather just remove that sentence about
what you can use INITIAL-INPUT for.

-- 
(domestic pets only, the antidote for overdose, milk.)
   bloggy blog: http://lars.ingebrigtsen.no





  reply	other threads:[~2022-07-05 11:33 UTC|newest]

Thread overview: 4+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2022-07-04 12:18 bug#56380: 29.0.50; completing-read: INITIAL-INPUT arg Michael Heerdegen
2022-07-05 11:33 ` Lars Ingebrigtsen [this message]
2022-07-05 12:49   ` Arash Esbati
2022-07-05 14:50     ` Drew Adams

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

  List information: https://www.gnu.org/software/emacs/

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=87v8sb4ww7.fsf@gnus.org \
    --to=larsi@gnus.org \
    --cc=56380@debbugs.gnu.org \
    --cc=arash@gnu.org \
    --cc=drew.adams@oracle.com \
    --cc=michael_heerdegen@web.de \
    --cc=monnier@iro.umontreal.ca \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
Code repositories for project(s) associated with this public inbox

	https://git.savannah.gnu.org/cgit/emacs.git

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for read-only IMAP folder(s) and NNTP newsgroup(s).