From mboxrd@z Thu Jan 1 00:00:00 1970 Path: news.gmane.io!.POSTED.blaine.gmane.org!not-for-mail From: Stefan Monnier via "Bug reports for GNU Emacs, the Swiss army knife of text editors" Newsgroups: gmane.emacs.bugs Subject: bug#65459: completing-read INITIAL-VALUE unaware of COLLECTION and REQUIRE-MATCH Date: Thu, 24 Aug 2023 09:36:55 -0400 Message-ID: References: <83jztmro8z.fsf@gnu.org> Reply-To: Stefan Monnier Mime-Version: 1.0 Content-Type: text/plain Injection-Info: ciao.gmane.io; posting-host="blaine.gmane.org:116.202.254.214"; logging-data="20042"; mail-complaints-to="usenet@ciao.gmane.io" User-Agent: Gnus/5.13 (Gnus v5.13) Cc: Eli Zaretskii , 65459@debbugs.gnu.org To: Heime Original-X-From: bug-gnu-emacs-bounces+geb-bug-gnu-emacs=m.gmane-mx.org@gnu.org Thu Aug 24 15:38:11 2023 Return-path: Envelope-to: geb-bug-gnu-emacs@m.gmane-mx.org Original-Received: from lists.gnu.org ([209.51.188.17]) by ciao.gmane.io with esmtps (TLS1.2:ECDHE_RSA_AES_256_GCM_SHA384:256) (Exim 4.92) (envelope-from ) id 1qZAXL-00050P-4Y for geb-bug-gnu-emacs@m.gmane-mx.org; Thu, 24 Aug 2023 15:38:11 +0200 Original-Received: from localhost ([::1] helo=lists1p.gnu.org) by lists.gnu.org with esmtp (Exim 4.90_1) (envelope-from ) id 1qZAX9-0005s2-L1; Thu, 24 Aug 2023 09:37:59 -0400 Original-Received: from eggs.gnu.org ([2001:470:142:3::10]) by lists.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_256_GCM_SHA384:256) (Exim 4.90_1) (envelope-from ) id 1qZAX8-0005rf-Od for bug-gnu-emacs@gnu.org; Thu, 24 Aug 2023 09:37:58 -0400 Original-Received: from debbugs.gnu.org ([2001:470:142:5::43]) by eggs.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_128_GCM_SHA256:128) (Exim 4.90_1) (envelope-from ) id 1qZAX8-0006Ld-Gm for bug-gnu-emacs@gnu.org; Thu, 24 Aug 2023 09:37:58 -0400 Original-Received: from Debian-debbugs by debbugs.gnu.org with local (Exim 4.84_2) (envelope-from ) id 1qZAXC-00061j-35 for bug-gnu-emacs@gnu.org; Thu, 24 Aug 2023 09:38:02 -0400 X-Loop: help-debbugs@gnu.org Resent-From: Stefan Monnier Original-Sender: "Debbugs-submit" Resent-CC: bug-gnu-emacs@gnu.org Resent-Date: Thu, 24 Aug 2023 13:38:02 +0000 Resent-Message-ID: Resent-Sender: help-debbugs@gnu.org X-GNU-PR-Message: followup 65459 X-GNU-PR-Package: emacs Original-Received: via spool by 65459-submit@debbugs.gnu.org id=B65459.169288423623112 (code B ref 65459); Thu, 24 Aug 2023 13:38:02 +0000 Original-Received: (at 65459) by debbugs.gnu.org; 24 Aug 2023 13:37:16 +0000 Original-Received: from localhost ([127.0.0.1]:36399 helo=debbugs.gnu.org) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1qZAWR-00060i-R0 for submit@debbugs.gnu.org; Thu, 24 Aug 2023 09:37:16 -0400 Original-Received: from mailscanner.iro.umontreal.ca ([132.204.25.50]:24894) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1qZAWP-00060U-PY for 65459@debbugs.gnu.org; Thu, 24 Aug 2023 09:37:14 -0400 Original-Received: from pmg2.iro.umontreal.ca (localhost.localdomain [127.0.0.1]) by pmg2.iro.umontreal.ca (Proxmox) with ESMTP id EC8E180595; Thu, 24 Aug 2023 09:37:03 -0400 (EDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/simple; d=iro.umontreal.ca; s=mail; t=1692884222; bh=s5KTqooXMQzZUVtL1eGRJE96arRavzUB3yL4+D2Qwf8=; h=From:To:Cc:Subject:In-Reply-To:References:Date:From; b=ovHZ2YCAAiUS7tTbzGrhdbmTer3CahqbzRNAVgGWnXmOkj/5/2f5msve0nNR1pAEW TFA72lfEgv1rtX055JcF0CA317YVjHq3k8U5gV14X72sMGT90DCXVDn/d3YCMyODbT oMa/JT7fGexlQPD0TqfZ0PCrCC5VDmylOKg+w5p/FpX4eSzW10HqjL4iFFhJTL6Doo 6HB0KgqRT0GCy1Sn8E2bvjWhlCsJO1VSQ6b0cW7SeFD/X14Sp+PmNwnU/PComXbQ9K aqToBE2yRjXgk8x/N0EOOglRc578NwbjTnwARRq8z/diAiDMood+R0LUPWc68nGfs0 5//HlAV77PLOg== Original-Received: from mail01.iro.umontreal.ca (unknown [172.31.2.1]) by pmg2.iro.umontreal.ca (Proxmox) with ESMTP id 8B1148037F; Thu, 24 Aug 2023 09:37:02 -0400 (EDT) Original-Received: from pastel (unknown [104.247.227.249]) by mail01.iro.umontreal.ca (Postfix) with ESMTPSA id 649991202E2; Thu, 24 Aug 2023 09:37:02 -0400 (EDT) In-Reply-To: (Heime's message of "Thu, 24 Aug 2023 09:02:06 +0000") X-BeenThere: debbugs-submit@debbugs.gnu.org X-Mailman-Version: 2.1.18 Precedence: list X-BeenThere: bug-gnu-emacs@gnu.org List-Id: "Bug reports for GNU Emacs, the Swiss army knife of text editors" List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: bug-gnu-emacs-bounces+geb-bug-gnu-emacs=m.gmane-mx.org@gnu.org Original-Sender: bug-gnu-emacs-bounces+geb-bug-gnu-emacs=m.gmane-mx.org@gnu.org Xref: news.gmane.io gmane.emacs.bugs:268338 Archived-At: > It is not, because the intention is on prefilling the minibuffer with > "alpha" rather than considering "alpha" as DEF. Could you explain why this is important in your case? > It appears that the maintainers might not be prioritizing the initial > intention of prefilling the minibuffer. Currently, their emphasis > seems to be on encouraging developers to either utilize the "DEF" > approach or actively discourage the use of "INITIAL". But, I haven't > come across a clear and well-founded reasoning behind these shifts > in approach. Not sure what you mean by "shifts". AFAIK this behavior has been with Emacs "forever": most minibuffers start empty (but with an associated default value) rather than starting with an initial value. This originally comes presumably from the absence of `transient-mark-mode` (or associated visual highlighting, both of which were introduced in Emacs-19) which means that it was annoying having to erase "alpha" before you can type "beta". Starting with a non-empty minibuffer does happen occasionally, most importantly for `read-file-name` where we do expect that this initial input will very likely be a part of the name the user will end up typing, so its rare that the users need to erase it before they can type the file name they want. > But this is only easily done only when collection is actually being > constructed in-place via the 'let' clause. But once COLLECTION > starts getting imported from somewhere else (via a call to same other > function for instance), your suggested solution is impossible > to achieve. That's partly why I've asked about a concrete example showing the wider context :-) Stefan