From mboxrd@z Thu Jan 1 00:00:00 1970 Path: news.gmane.org!.POSTED!not-for-mail From: Stefan Monnier Newsgroups: gmane.emacs.devel Subject: Re: file-name-as-directory: Update doc. string Date: Mon, 12 Sep 2016 18:20:17 -0400 Message-ID: References: <83a8fd9hfb.fsf@gnu.org> NNTP-Posting-Host: blaine.gmane.org Mime-Version: 1.0 Content-Type: text/plain X-Trace: blaine.gmane.org 1473718673 29563 195.159.176.226 (12 Sep 2016 22:17:53 GMT) X-Complaints-To: usenet@blaine.gmane.org NNTP-Posting-Date: Mon, 12 Sep 2016 22:17:53 +0000 (UTC) User-Agent: Gnus/5.13 (Gnus v5.13) Emacs/25.1.50 (gnu/linux) To: emacs-devel@gnu.org Original-X-From: emacs-devel-bounces+ged-emacs-devel=m.gmane.org@gnu.org Tue Sep 13 00:17:50 2016 Return-path: Envelope-to: ged-emacs-devel@m.gmane.org Original-Received: from lists.gnu.org ([208.118.235.17]) by blaine.gmane.org with esmtp (Exim 4.84_2) (envelope-from ) id 1bjZXs-0006gP-Ga for ged-emacs-devel@m.gmane.org; Tue, 13 Sep 2016 00:17:44 +0200 Original-Received: from localhost ([::1]:45430 helo=lists.gnu.org) by lists.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1bjZXq-0001Qx-J4 for ged-emacs-devel@m.gmane.org; Mon, 12 Sep 2016 18:17:42 -0400 Original-Received: from eggs.gnu.org ([2001:4830:134:3::10]:38295) by lists.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1bjZXU-0001FN-I6 for emacs-devel@gnu.org; Mon, 12 Sep 2016 18:17:21 -0400 Original-Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.71) (envelope-from ) id 1bjZXP-0004CE-F6 for emacs-devel@gnu.org; Mon, 12 Sep 2016 18:17:20 -0400 Original-Received: from [195.159.176.226] (port=55139 helo=blaine.gmane.org) by eggs.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1bjZXP-0004Ab-84 for emacs-devel@gnu.org; Mon, 12 Sep 2016 18:17:15 -0400 Original-Received: from list by blaine.gmane.org with local (Exim 4.84_2) (envelope-from ) id 1bjZXI-0002qO-7s for emacs-devel@gnu.org; Tue, 13 Sep 2016 00:17:08 +0200 X-Injected-Via-Gmane: http://gmane.org/ Original-Lines: 17 Original-X-Complaints-To: usenet@blaine.gmane.org Cancel-Lock: sha1:Rc2SXJuWow1Ma6gjHdqnlClDtY4= X-detected-operating-system: by eggs.gnu.org: GNU/Linux 2.2.x-3.x [generic] X-Received-From: 195.159.176.226 X-BeenThere: emacs-devel@gnu.org X-Mailman-Version: 2.1.21 Precedence: list List-Id: "Emacs development discussions." List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: emacs-devel-bounces+ged-emacs-devel=m.gmane.org@gnu.org Original-Sender: "Emacs-devel" Xref: news.gmane.org gmane.emacs.devel:207402 Archived-At: > Yeah, it's a right sentence, but unnecessary: don't bring us any useful > information. You could also pass FILE, the input of > `file-name-as-directory', > as second argument to expand-file-name (e-f-n). > When i read this doc, i understand that e-f-n just accepts > directory names as the second arg, which is wrong. That seems the case at > the time this sentence was added, but not anymore. As a general rule, Emacs doesn't care if a file name has a final slash or not when the arg is known to be a directory (as is the case for the second arg of expand-file-name). There are some exceptions, but these are the ones that need to be documented LOUDLY (or fixed). Stefan