From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: from eggs.gnu.org (eggs.gnu.org [IPv6:2001:470:142:3::10]) by sourceware.org (Postfix) with ESMTPS id 237EB3858CDB for ; Fri, 12 Apr 2024 18:44:55 +0000 (GMT) DMARC-Filter: OpenDMARC Filter v1.4.2 sourceware.org 237EB3858CDB Authentication-Results: sourceware.org; dmarc=pass (p=none dis=none) header.from=gnu.org Authentication-Results: sourceware.org; spf=pass smtp.mailfrom=gnu.org ARC-Filter: OpenARC Filter v1.0.0 sourceware.org 237EB3858CDB Authentication-Results: server2.sourceware.org; arc=none smtp.remote-ip=2001:470:142:3::10 ARC-Seal: i=1; a=rsa-sha256; d=sourceware.org; s=key; t=1712947497; cv=none; b=k/8gCQurFAQVFrzHAaU91ysRjbRSe/IOVJOmhNvcddZCCbx9mK10BM1P4eeKlwoMSBK6jjRSlqGeA5V/ugivXlUIwIX8cdxcU9ceshMDuDrU5TjH1MM9Rhj5/wltIKql6raV46I3cSAzYOEDrB7VzPRQ7OFYEkIgGhM0kguHEvo= ARC-Message-Signature: i=1; a=rsa-sha256; d=sourceware.org; s=key; t=1712947497; c=relaxed/simple; bh=HpouCBdUhRvVhIKl2waQL00TWQj/PYHUZBQxEgnthaM=; h=DKIM-Signature:Date:Message-Id:From:To:Subject; b=VNVcEs6ylGMg149EsE4KHXWBykLH6cucbRaURbbDf/lE8c67Alq6TJOiU1mtuTL9PiCcH2EDTxWwT4x7aSm3AbF2Z1Wq56fI+U3uAmPR/DKoUCJDrCGcoexkqvDcccpl7bRQJcJXImbSyzXMqdvhTRzEE/hU63yYnHVk3Vsyp7Y= ARC-Authentication-Results: i=1; server2.sourceware.org Received: from fencepost.gnu.org ([2001:470:142:3::e]) by eggs.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_256_GCM_SHA384:256) (Exim 4.90_1) (envelope-from ) id 1rvLtO-0000WO-8D; Fri, 12 Apr 2024 14:44:54 -0400 DKIM-Signature: v=1; a=rsa-sha256; q=dns/txt; c=relaxed/relaxed; d=gnu.org; s=fencepost-gnu-org; h=References:Subject:In-Reply-To:To:From:Date: mime-version; bh=unjGRcZmkUi12iyuAK+zoJ7T7UBIV87cyXmG5tQRL+w=; b=sNkZDi2ZO6zd vHcRMas6geq4+if1hgy3G6chd2Iyrr898V/sIESNDUY7XmHSySOFoVap5gsK1hw5cD0+maxZJ/MAB kDWP4yoq/+3VBAhTgewmr/JGnDTaVZOoouunGBptppLWqB72ThYEbK8mmNMyd8shMav9uNiY0Ct5C ikIo3hiJQHLg6Wy7x/hW+YPp2PqBAhfASfX8hRDvCi0WKAziJi0nErDKeXEin9n/U90b2oLSDO9e7 CE1O6LcOOVTcesmzR+wamas70daR6n0MUZDcSCme2E0eNiUlHmwsudmcnhEdmd7F2ALqbNbTUaEN5 ivDd42uVo3ajOUUT6odrUA==; Date: Fri, 12 Apr 2024 21:44:51 +0300 Message-Id: <865xwms9ng.fsf@gnu.org> From: Eli Zaretskii To: Andrew Burgess Cc: lsix@lancelotsix.com, gdb-patches@sourceware.org In-Reply-To: <87pluu4gwb.fsf@redhat.com> (message from Andrew Burgess on Fri, 12 Apr 2024 18:42:12 +0100) Subject: Re: [PATCH 4/6] gdb: add match formatter mechanism for 'complete' command output References: <6adc14efeac88ecd9501c0c8c53b622099333792.1711712401.git.aburgess@redhat.com> <20240330234918.fk4gdzmdeoojia27@octopus> <86ttknaqsx.fsf@gnu.org> <87pluu4gwb.fsf@redhat.com> X-Spam-Status: No, score=-0.7 required=5.0 tests=BAYES_00,DKIMWL_WL_HIGH,DKIM_SIGNED,DKIM_VALID,DKIM_VALID_AU,DKIM_VALID_EF,SPF_HELO_PASS,SPF_PASS,TXREP autolearn=ham autolearn_force=no version=3.4.6 X-Spam-Checker-Version: SpamAssassin 3.4.6 (2021-04-09) on server2.sourceware.org List-Id: > From: Andrew Burgess > Cc: gdb-patches@sourceware.org > Date: Fri, 12 Apr 2024 18:42:12 +0100 > > > (gdb) file '/tmp/xx > > => (gdb) file '/tmp/xx/' > > (gdb) file '/tmp/xx/'a > > => (gdb) file '/tmp/xx/abcd' > > > > That is, allow to type after the closing quote, and remove the closing > > quote before trying to complete. This way, the user can use > > '/tmp/xx/' if that is what she needs, or continue typing and > > completing if not. > > That does sound better. I think there are still things that would need > figuring out. For example, what if the user didn't do the second tab > completion, but just kept typing. > > (gdb) file '/tmp/xx > => (gdb) file '/tmp/xx/' > (gdb) file '/tmp/xx/'abcd > => ?? What would this do? > > What if there really was a file /tmp/xx/'abcd ? What happens then? ENTER does the same as TAB, and then submits the result. So GDB will see '/tmp/xx/abcd' in that case.