From mboxrd@z Thu Jan 1 00:00:00 1970 Path: news.gmane.io!.POSTED.blaine.gmane.org!not-for-mail From: Heime 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: Wed, 23 Aug 2023 11:57:55 +0000 Message-ID: References: <83jztmro8z.fsf@gnu.org> Reply-To: Heime Mime-Version: 1.0 Content-Type: text/plain; charset=utf-8 Content-Transfer-Encoding: quoted-printable Injection-Info: ciao.gmane.io; posting-host="blaine.gmane.org:116.202.254.214"; logging-data="38901"; mail-complaints-to="usenet@ciao.gmane.io" Cc: 65459@debbugs.gnu.org, Stefan Monnier To: Eli Zaretskii Original-X-From: bug-gnu-emacs-bounces+geb-bug-gnu-emacs=m.gmane-mx.org@gnu.org Wed Aug 23 13:59:33 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 1qYmWK-0009vx-Ns for geb-bug-gnu-emacs@m.gmane-mx.org; Wed, 23 Aug 2023 13:59:32 +0200 Original-Received: from localhost ([::1] helo=lists1p.gnu.org) by lists.gnu.org with esmtp (Exim 4.90_1) (envelope-from ) id 1qYmVo-0006EH-NK; Wed, 23 Aug 2023 07:59:00 -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 1qYmVn-0006Bn-0s for bug-gnu-emacs@gnu.org; Wed, 23 Aug 2023 07:58:59 -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 1qYmVm-00041Q-OJ for bug-gnu-emacs@gnu.org; Wed, 23 Aug 2023 07:58:58 -0400 Original-Received: from Debian-debbugs by debbugs.gnu.org with local (Exim 4.84_2) (envelope-from ) id 1qYmVq-00011N-3k for bug-gnu-emacs@gnu.org; Wed, 23 Aug 2023 07:59:02 -0400 X-Loop: help-debbugs@gnu.org Resent-From: Heime Original-Sender: "Debbugs-submit" Resent-CC: bug-gnu-emacs@gnu.org Resent-Date: Wed, 23 Aug 2023 11:59: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.16927919023870 (code B ref 65459); Wed, 23 Aug 2023 11:59:02 +0000 Original-Received: (at 65459) by debbugs.gnu.org; 23 Aug 2023 11:58:22 +0000 Original-Received: from localhost ([127.0.0.1]:33059 helo=debbugs.gnu.org) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1qYmVC-00010L-89 for submit@debbugs.gnu.org; Wed, 23 Aug 2023 07:58:22 -0400 Original-Received: from mail-4324.protonmail.ch ([185.70.43.24]:28799) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1qYmV9-000105-Bp for 65459@debbugs.gnu.org; Wed, 23 Aug 2023 07:58:20 -0400 DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=protonmail.com; s=protonmail3; t=1692791889; x=1693051089; bh=ZW48oK5gfr17Vf/wg+Yvq/wcJvzFl4/mMyEViB0kmhs=; h=Date:To:From:Cc:Subject:Message-ID:In-Reply-To:References: Feedback-ID:From:To:Cc:Date:Subject:Reply-To:Feedback-ID: Message-ID:BIMI-Selector; b=GPz5dAYa6UnqCsB18eQUw+xobbqjEBWn/DU+eT5on3kbbkvcEecfB0ugu/kRK3WDI EiiBD4atSKtQdxKy5okUezt3T2TXmIw12MlhhB0zqQM3+m6K6AqvDIiF6DhMnp8Ap+ hnvMeOP6FE6NPdR1IFXiXyqIWoK3pci/qYx1sJQg8t8GsbFVV8ByYJVLgZH7w6Ys+c /wXGjCGZO7XRd+/rxJBPnhgltQkoDZsPNDrFGwtmdJoRdvcugnJerc48MVdoXaGPG2 N5foxOD8IeRgWl2zHrVnA2dCvgAKGFJo4Lc9pCO0tI36QH+YAoYicR0h/pqsdhZ6RE LBUvqG2S7iyHA== In-Reply-To: <83jztmro8z.fsf@gnu.org> Feedback-ID: 57735886:user:proton 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:268233 Archived-At: Sent with Proton Mail secure email. ------- Original Message ------- On Wednesday, August 23rd, 2023 at 11:29 PM, Eli Zaretskii w= rote: > > Date: Tue, 22 Aug 2023 22:04:06 +0000 > > From: Heime via "Bug reports for GNU Emacs, > > the Swiss army knife of text editors" bug-gnu-emacs@gnu.org > >=20 > > The completing-read function in Emacs allows you to create a simple > > interactive prompt where the user can type to complete a string based > > on a given collection. REQUIRE-MATCH determines whether the input > > must match an item in the collection. > >=20 > > I find the design of completing-read as half-baked because INITIAL-VALU= E > > always works as an independent entity, always unaware of COLLECTION and > > REQUIRE-MATCH >=20 >=20 > "Half-baked" is a harsh qualification. I don't think it makes your > arguments more attractive or convincing, so my advice is to avoid such > derogatory epithets on issues which you have just recently learned and > about which you might still be missing quite a lot. How can we describe it - primitive - then. What lots am I missing about=20 the behaviour of INITIAL-VALUE being independent about the state of the=20 other variables ? And that entries in collection always start from index zero when cycling is used. I have found its capability limited, having actually used it. Nevertheless, if I am missing on things, I would be glad to be corrected=20 so that I can change my code accordingly.=20 =20 > In any case, from where I stand, any significant changes in the API of > completing-read that are backward incompatible are out of the question > at this stage, and if this discussion leads to a conclusion that an > incompatible API could be useful, it will have to be a separate API. I expected that as the functionalities get enhanced, some deficiencies also get pumped up. Giving more control to the programmer about what=20 gets displayed in the minibuffer. =20 > > Thus, there exists no capabilities for possible interactions that could > > influence how the completion works. > >=20 > > For instance, suppose you want INITIAL-INPUT to be takes from collectio= n, > > and then have cycling start from a certain element after INITIAL-INPUT > > is displayed. You can't. The only thing you can do is select an option > > by automatically completing as much as possible. > >=20 > > As for the cycling part, no proper functionality has been introduced. I= NITIAL-INPUT > > is there just to insert something to the minibuffer without any regard = to possible > > restriction that one might want imposed on it and what gets displayed a= fter INITIAL-VALUE. >=20 >=20 > Adding Stefan. >