From mboxrd@z Thu Jan 1 00:00:00 1970 Path: news.gmane.io!.POSTED.blaine.gmane.org!not-for-mail From: Gregory Heytings Newsgroups: gmane.emacs.bugs Subject: bug#60264: 29.0.60; Strange file completion candidates for shadowed file paths Date: Fri, 23 Dec 2022 17:38:08 +0000 Message-ID: References: <87ili3xikc.fsf@daniel-mendler.de> <83h6xm8udx.fsf@gnu.org> Mime-Version: 1.0 Content-Type: text/plain; charset=us-ascii; format=flowed Injection-Info: ciao.gmane.io; posting-host="blaine.gmane.org:116.202.254.214"; logging-data="36174"; mail-complaints-to="usenet@ciao.gmane.io" Cc: Daniel Mendler , Eli Zaretskii , 60264@debbugs.gnu.org To: Stefan Monnier Original-X-From: bug-gnu-emacs-bounces+geb-bug-gnu-emacs=m.gmane-mx.org@gnu.org Fri Dec 23 18:39:12 2022 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 1p8m0l-0009EG-TU for geb-bug-gnu-emacs@m.gmane-mx.org; Fri, 23 Dec 2022 18:39:12 +0100 Original-Received: from localhost ([::1] helo=lists1p.gnu.org) by lists.gnu.org with esmtp (Exim 4.90_1) (envelope-from ) id 1p8m0d-0003cu-Te; Fri, 23 Dec 2022 12:39:03 -0500 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 1p8m0c-0003cY-9P for bug-gnu-emacs@gnu.org; Fri, 23 Dec 2022 12:39:02 -0500 Original-Received: from debbugs.gnu.org ([209.51.188.43]) by eggs.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_128_GCM_SHA256:128) (Exim 4.90_1) (envelope-from ) id 1p8m0c-0001bH-1f for bug-gnu-emacs@gnu.org; Fri, 23 Dec 2022 12:39:02 -0500 Original-Received: from Debian-debbugs by debbugs.gnu.org with local (Exim 4.84_2) (envelope-from ) id 1p8m0b-0007kK-JG for bug-gnu-emacs@gnu.org; Fri, 23 Dec 2022 12:39:01 -0500 X-Loop: help-debbugs@gnu.org Resent-From: Gregory Heytings Original-Sender: "Debbugs-submit" Resent-CC: bug-gnu-emacs@gnu.org Resent-Date: Fri, 23 Dec 2022 17:39:01 +0000 Resent-Message-ID: Resent-Sender: help-debbugs@gnu.org X-GNU-PR-Message: followup 60264 X-GNU-PR-Package: emacs Original-Received: via spool by 60264-submit@debbugs.gnu.org id=B60264.167181709329756 (code B ref 60264); Fri, 23 Dec 2022 17:39:01 +0000 Original-Received: (at 60264) by debbugs.gnu.org; 23 Dec 2022 17:38:13 +0000 Original-Received: from localhost ([127.0.0.1]:37946 helo=debbugs.gnu.org) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1p8lzo-0007js-TU for submit@debbugs.gnu.org; Fri, 23 Dec 2022 12:38:13 -0500 Original-Received: from heytings.org ([95.142.160.155]:42514) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1p8lzm-0007jm-Ju for 60264@debbugs.gnu.org; Fri, 23 Dec 2022 12:38:11 -0500 DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=heytings.org; s=20220101; t=1671817089; bh=p/Lr1v4WTBOpJ6ll4puI2GrZ93cPyvgS/M9jBU2QlIY=; h=Date:From:To:cc:Subject:In-Reply-To:Message-ID:References:From; b=PKZIUi/OLDRFe9Iz+dzYR+0jqjN8GjCq/JEbCpHZ7biZCsDPmLOpSJ7ps3aH1TA8+ vchlIxUN/t2K7TsLz62Gj71Dffeo4WZVkvj3mK7IQA6EkgwdmRALtq6Jn53ht07bGZ 1ihDZ8sWnrRCH8NyzmFQhaHBNESyWgJhrCiveQdd72JX9L7H7tf6fBnQWJVm4KkkQO ZFh0gAmzTc9AowGM+beL5T6bebPImikDBEeigYsYubqxg3OMu9ZSx+JfJBRZ4UZKb+ uVCK7zMtaxAxiPxErBEn77iOYntp/fgjRBditJErny59C3p/ZfTahJzvwPRzz6+uje 7a1HdwGo2yjCw== In-Reply-To: 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:251742 Archived-At: >>> 1. Start emacs -Q >>> 2. C-x C-f >>> 3. Delete the entire minibuffer input >>> 4. Enter /etc//s >>> 5. Press ? >>> >>> You will see candidates like etc//sbin/. The candidates can get even >>> stranger. If you enter /etc//etc//etc/s then you will get candidates >>> like etc//etc//etc//sbin/. I can reproduce this bug on 27 and 29. I >>> haven't tried 28, but the issue should exist there too. >> >> I don't think it's a bug (look at what the minibuffer shows in those >> cases), perhaps just a minor aesthetic thing, but I'm adding Stefan in >> case he has comments. > > He's right, that's a bug. *Completions* normally only shows the list of > matching files in the final directory, so complete filenames. It's even > more true here where the "excess" is not even really part of the file > name since it'll be stripped away by `substitute-in-file-name`. > > E.g. if you replace "/etc//s" with "~//s" in the example, we show the > correct list. > It's a bug indeed, but a very old one, it's also present in Emacs 24-25-26-27-28.