From mboxrd@z Thu Jan 1 00:00:00 1970 Path: news.gmane.io!.POSTED.blaine.gmane.org!not-for-mail From: Eli Zaretskii Newsgroups: gmane.emacs.bugs Subject: bug#62732: 29.0.60; uniquify-trailing-separator-p affects any buffer whose name matches a dir in CWD Date: Mon, 10 Jul 2023 22:12:31 +0300 Message-ID: <83fs5v8tsw.fsf@gnu.org> References: <87h6tpn8d5.fsf@catern.com> <87edotn7sx.fsf@catern.com> <87edlhm6wq.fsf@catern.com> <87o7kklf9c.fsf@catern.com> <83r0pf9b7d.fsf@gnu.org> Injection-Info: ciao.gmane.io; posting-host="blaine.gmane.org:116.202.254.214"; logging-data="20009"; mail-complaints-to="usenet@ciao.gmane.io" Cc: sbaugh@catern.com, 62732@debbugs.gnu.org To: Stefan Monnier Original-X-From: bug-gnu-emacs-bounces+geb-bug-gnu-emacs=m.gmane-mx.org@gnu.org Mon Jul 10 21:13:28 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 1qIwK7-00052N-Os for geb-bug-gnu-emacs@m.gmane-mx.org; Mon, 10 Jul 2023 21:13:27 +0200 Original-Received: from localhost ([::1] helo=lists1p.gnu.org) by lists.gnu.org with esmtp (Exim 4.90_1) (envelope-from ) id 1qIwJl-0006Nq-29; Mon, 10 Jul 2023 15:13:05 -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 1qIwJi-0006Kz-SC for bug-gnu-emacs@gnu.org; Mon, 10 Jul 2023 15:13:02 -0400 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 1qIwJi-0002sn-Js for bug-gnu-emacs@gnu.org; Mon, 10 Jul 2023 15:13:02 -0400 Original-Received: from Debian-debbugs by debbugs.gnu.org with local (Exim 4.84_2) (envelope-from ) id 1qIwJi-0003kp-0S for bug-gnu-emacs@gnu.org; Mon, 10 Jul 2023 15:13:02 -0400 X-Loop: help-debbugs@gnu.org Resent-From: Eli Zaretskii Original-Sender: "Debbugs-submit" Resent-CC: bug-gnu-emacs@gnu.org Resent-Date: Mon, 10 Jul 2023 19:13:01 +0000 Resent-Message-ID: Resent-Sender: help-debbugs@gnu.org X-GNU-PR-Message: followup 62732 X-GNU-PR-Package: emacs Original-Received: via spool by 62732-submit@debbugs.gnu.org id=B62732.168901635114392 (code B ref 62732); Mon, 10 Jul 2023 19:13:01 +0000 Original-Received: (at 62732) by debbugs.gnu.org; 10 Jul 2023 19:12:31 +0000 Original-Received: from localhost ([127.0.0.1]:49153 helo=debbugs.gnu.org) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1qIwJC-0003k3-Sy for submit@debbugs.gnu.org; Mon, 10 Jul 2023 15:12:31 -0400 Original-Received: from eggs.gnu.org ([209.51.188.92]:43694) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1qIwJA-0003jq-JN for 62732@debbugs.gnu.org; Mon, 10 Jul 2023 15:12:29 -0400 Original-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 1qIwJ5-0002pj-1H; Mon, 10 Jul 2023 15:12:23 -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=nMqQGS8Hmf9BWolGlZSVlhdCIgoUfmE3ceWidDCUN0U=; b=c+/MO8+A5qiD NE454NvsxLrZK4A1tM952ZHK2/aeYrdV1mHG86IdvL3okITomiEm+XPrXiqRgy0OL3TL8/98sj9Q9 l9J+JsFl+O2PrBG+rlsHM2zlYVMisHI2Xs8rFGSewIWT1tBwi1khFXkTRkTShoBeXBGWxaw+76gqG YWhqU+vJmPhzqNgjpUEGmolz/9uqgz2HWS+rHK2vUXamaj+xWcjyh0buqKCkT1FWmonAdwxNyCuF7 tVXL7JNC5V6CDvoRztCfk5hIxhq+zd/iTRb53h7YlaUlw6h+HpmTzYBto0DBQq6htLY2JOz6SJTW4 NQEBbyV6QvEmQmaFDVO8sA==; Original-Received: from [87.69.77.57] (helo=home-c4e4a596f7) by fencepost.gnu.org with esmtpsa (TLS1.2:ECDHE_RSA_AES_256_GCM_SHA384:256) (Exim 4.90_1) (envelope-from ) id 1qIwJ4-00007A-HP; Mon, 10 Jul 2023 15:12:22 -0400 In-Reply-To: (message from Stefan Monnier on Mon, 10 Jul 2023 12:53:00 -0400) 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:264900 Archived-At: > From: Stefan Monnier > Cc: sbaugh@catern.com, 62732@debbugs.gnu.org > Date: Mon, 10 Jul 2023 12:53:00 -0400 > > > Callers shouldn't know to much about the internals of the callee. > > Indeed: currently `create-file-buffer` doesn't pay attention to the file > system at all, it just creates a buffer with a name based on the > FILENAME that's passed. Spencer's patch just offers more control to the > callers by making `create-file-buffer` respect the choice of the callers > (whether they used a file name or a dire name, which is an important > distinction in Emacs's file name APIs, not just here). > > There's no need for the callers to know about the internals of > the callee. If they call `create-file-buffer` with /foo/bar/baz the > buffer will be called "baz" and if they call it with /foo/bar/baz/ the > buffer will be called "baz/" (depending on > `uniquify-trailing-separator-p`, of course). > It's the most natural/obvious semantics. Wasn't the fact that the trailing slash was absent part of the reason for the bug this tries to fix? If so, then this is not just "if you want it, use it", is it?