From mboxrd@z Thu Jan 1 00:00:00 1970 Path: news.gmane.org!not-for-mail From: Eli Zaretskii Newsgroups: gmane.emacs.devel Subject: Re: convert-standard-filename Date: Sun, 07 Aug 2011 19:18:03 +0300 Message-ID: <834o1t19hg.fsf@gnu.org> References: <83vcufaaqf.fsf@gnu.org> <83hb5vvwdp.fsf@gnu.org> Reply-To: Eli Zaretskii NNTP-Posting-Host: lo.gmane.org X-Trace: dough.gmane.org 1312733937 27118 80.91.229.12 (7 Aug 2011 16:18:57 GMT) X-Complaints-To: usenet@dough.gmane.org NNTP-Posting-Date: Sun, 7 Aug 2011 16:18:57 +0000 (UTC) Cc: sds@gnu.org, emacs-devel@gnu.org To: Stefan Monnier Original-X-From: emacs-devel-bounces+ged-emacs-devel=m.gmane.org@gnu.org Sun Aug 07 18:18:53 2011 Return-path: Envelope-to: ged-emacs-devel@m.gmane.org Original-Received: from lists.gnu.org ([140.186.70.17]) by lo.gmane.org with esmtp (Exim 4.69) (envelope-from ) id 1Qq63x-0004Aq-4U for ged-emacs-devel@m.gmane.org; Sun, 07 Aug 2011 18:18:53 +0200 Original-Received: from localhost ([::1]:52308 helo=lists.gnu.org) by lists.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1Qq63w-0006pp-Aw for ged-emacs-devel@m.gmane.org; Sun, 07 Aug 2011 12:18:52 -0400 Original-Received: from eggs.gnu.org ([140.186.70.92]:39916) by lists.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1Qq63t-0006pK-U1 for emacs-devel@gnu.org; Sun, 07 Aug 2011 12:18:50 -0400 Original-Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.71) (envelope-from ) id 1Qq63s-0004hm-LB for emacs-devel@gnu.org; Sun, 07 Aug 2011 12:18:49 -0400 Original-Received: from mtaout20.012.net.il ([80.179.55.166]:45086) by eggs.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1Qq63s-0004hg-DU; Sun, 07 Aug 2011 12:18:48 -0400 Original-Received: from conversion-daemon.a-mtaout20.012.net.il by a-mtaout20.012.net.il (HyperSendmail v2007.08) id <0LPK00700FPR8M00@a-mtaout20.012.net.il>; Sun, 07 Aug 2011 19:18:05 +0300 (IDT) Original-Received: from HOME-C4E4A596F7 ([84.228.94.185]) by a-mtaout20.012.net.il (HyperSendmail v2007.08) with ESMTPA id <0LPK007H0FY31490@a-mtaout20.012.net.il>; Sun, 07 Aug 2011 19:18:05 +0300 (IDT) In-reply-to: X-012-Sender: halo1@inter.net.il X-detected-operating-system: by eggs.gnu.org: Solaris 10 (beta) X-Received-From: 80.179.55.166 X-BeenThere: emacs-devel@gnu.org X-Mailman-Version: 2.1.14 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-bounces+ged-emacs-devel=m.gmane.org@gnu.org Xref: news.gmane.org gmane.emacs.devel:142960 Archived-At: > From: Stefan Monnier > Cc: sds@gnu.org, emacs-devel@gnu.org > Date: Sun, 07 Aug 2011 11:33:53 -0400 > > >> But how should it decide what is relative and what is not, e.g. in the > >> case of "c:/foo" (or worse "c:foo") mentioned in the docstring? > > Why by file-name-absolute-p, of course ;-) > > This would mean that the input is interpreted in an OS-dependent way. > It would seem to make more sense to say that the arg to > convert-filename-argument (or its new replacement) should be > a Unix-style filename, i.e. "C:" is always interpreted as > a relative file name, even under Window or DOS. Although it makes sense, that would change the current semantics, and probably break some existing code out there. > How 'bout a file-name-equal, which could also try to account for > case-sensitivity? He-he, I was arguing for years that file names are not strings and cannot be compared as strings. Finally I have someone who agrees ;-) There's also the case of 8+3 aliases of long file names on Windows, we bumped into that some time ago (the value of temporary-file-directory on Windows uses the 8+3 alias, because that's how Windows sets up the environment variable). > Hmm... I didn't check all uses of doc-8+3-filename, but at least the one > in files.el can't be replaced by file-name-equal. They all can. dos-8+3-filename was introduced _only_ to be able to compare and match file names as strings.