From mboxrd@z Thu Jan 1 00:00:00 1970 Path: news.gmane.io!.POSTED.blaine.gmane.org!not-for-mail From: Juri Linkov Newsgroups: gmane.emacs.bugs Subject: bug#49761: file-cache-minibuffer-complete has become unusable for duplicate file names in MacOSX 27.x emacs Date: Sun, 01 Aug 2021 11:40:50 +0300 Organization: LINKOV.NET Message-ID: <87k0l5j1u1.fsf@mail.linkov.net> References: <87o8alvwby.fsf@mail.linkov.net> <83bl6lrnrh.fsf@gnu.org> <878s1pvunb.fsf@mail.linkov.net> <838s1osyv1.fsf@gnu.org> <87y29ovrgj.fsf@mail.linkov.net> <87v94su45t.fsf@mail.linkov.net> <8335rws641.fsf@gnu.org> <87lf5nisyo.fsf@mail.linkov.net> Mime-Version: 1.0 Content-Type: text/plain Injection-Info: ciao.gmane.io; posting-host="blaine.gmane.org:116.202.254.214"; logging-data="19359"; mail-complaints-to="usenet@ciao.gmane.io" User-Agent: Gnus/5.13 (Gnus v5.13) Emacs/28.0.50 (x86_64-pc-linux-gnu) Cc: 49761@debbugs.gnu.org To: Aaron Cohen Original-X-From: bug-gnu-emacs-bounces+geb-bug-gnu-emacs=m.gmane-mx.org@gnu.org Sun Aug 01 10:43:10 2021 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 1mA73u-0004sF-0l for geb-bug-gnu-emacs@m.gmane-mx.org; Sun, 01 Aug 2021 10:43:10 +0200 Original-Received: from localhost ([::1]:50336 helo=lists1p.gnu.org) by lists.gnu.org with esmtp (Exim 4.90_1) (envelope-from ) id 1mA73s-0002g7-Vm for geb-bug-gnu-emacs@m.gmane-mx.org; Sun, 01 Aug 2021 04:43:08 -0400 Original-Received: from eggs.gnu.org ([2001:470:142:3::10]:59410) by lists.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_256_GCM_SHA384:256) (Exim 4.90_1) (envelope-from ) id 1mA72q-0001ds-AU for bug-gnu-emacs@gnu.org; Sun, 01 Aug 2021 04:42:07 -0400 Original-Received: from debbugs.gnu.org ([209.51.188.43]:52193) by eggs.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_128_GCM_SHA256:128) (Exim 4.90_1) (envelope-from ) id 1mA72o-0002ze-8L for bug-gnu-emacs@gnu.org; Sun, 01 Aug 2021 04:42:03 -0400 Original-Received: from Debian-debbugs by debbugs.gnu.org with local (Exim 4.84_2) (envelope-from ) id 1mA72o-0003Dr-0G for bug-gnu-emacs@gnu.org; Sun, 01 Aug 2021 04:42:02 -0400 X-Loop: help-debbugs@gnu.org Resent-From: Juri Linkov Original-Sender: "Debbugs-submit" Resent-CC: bug-gnu-emacs@gnu.org Resent-Date: Sun, 01 Aug 2021 08:42:01 +0000 Resent-Message-ID: Resent-Sender: help-debbugs@gnu.org X-GNU-PR-Message: followup 49761 X-GNU-PR-Package: emacs Original-Received: via spool by 49761-submit@debbugs.gnu.org id=B49761.162780727712328 (code B ref 49761); Sun, 01 Aug 2021 08:42:01 +0000 Original-Received: (at 49761) by debbugs.gnu.org; 1 Aug 2021 08:41:17 +0000 Original-Received: from localhost ([127.0.0.1]:35504 helo=debbugs.gnu.org) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1mA725-0003Ck-Fv for submit@debbugs.gnu.org; Sun, 01 Aug 2021 04:41:17 -0400 Original-Received: from relay9-d.mail.gandi.net ([217.70.183.199]:33675) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1mA722-0003CT-R6; Sun, 01 Aug 2021 04:41:15 -0400 Original-Received: (Authenticated sender: juri@linkov.net) by relay9-d.mail.gandi.net (Postfix) with ESMTPSA id D7E48FF806; Sun, 1 Aug 2021 08:41:07 +0000 (UTC) In-Reply-To: (Aaron Cohen's message of "Fri, 30 Jul 2021 11:20:51 -0700") 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" Xref: news.gmane.io gmane.emacs.bugs:211038 Archived-At: tags 49761 fixed close 49761 28.0.50 thanks > Well, it's now the default behavior. It wasn't previously. :-) And new is not always better ;-) So now the new behavior (that became old now) was fixed in the master branch for Emacs 28, and all test cases that you presented work completely as expected. Thanks for helping to understand where the problem was. BTW, after the fix, the following additional information is not necessary, but I discovered that in old versions you can use the prefix argument to force C-TAB cycling. An excerpt from etc/NEWS.20: ** file-cache-minibuffer-complete now accepts a prefix argument. With a prefix argument, it does not try to do completion of the file name within its directory; it only checks for other directories that contain the same file name. Thus, given the file name Makefile, and assuming that a file Makefile.in exists in the same directory, ordinary file-cache-minibuffer-complete will try to complete Makefile to Makefile.in and will therefore never look for other directories that have Makefile. A prefix argument tells it not to look for longer names such as Makefile.in, so that instead it will look for other directories--just as if the name were already complete in its present directory. and a comment from bindings.el: ;; The prefix argument works around a bug in the minibuffer completion. ;; The completion function doesn't distinguish between the states: ;; ;; "Multiple completions of name" (eg, Makefile, Makefile.in) ;; "Name available in multiple directories" (/tmp/Makefile, ~me/Makefile) ;; ;; The default is to do the former; a prefix arg forces the latter.