[Top][All Lists]
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
Re: Behavior of directory-files on Windows
From: |
Thierry Volpiatto |
Subject: |
Re: Behavior of directory-files on Windows |
Date: |
Fri, 02 Dec 2011 11:46:48 +0100 |
User-agent: |
Gnus/5.13 (Gnus v5.13) Emacs/24.0.92 (gnu/linux) |
Eli Zaretskii <address@hidden> writes:
>> From: Thierry Volpiatto <address@hidden>
>> Cc: Juanma Barranquero <address@hidden>, address@hidden
>> Date: Thu, 01 Dec 2011 18:34:17 +0100
>>
>> one is able to do: (find-file "c:/.") but when he list directory
>> this file ("c:/.") is not present.
>
> That's because "c:/." is canonicalized to "c:/" before passing it to
> the appropriate system APIs. IOW, the above is not a proof that "."
> should exist;
Sure, but that still obscure, as (file-exists-p "c:/.") return t.
> every system does such canonicalization at some point.
So why not doing it in Emacs?
I think adding both c:/. and c:/.. to listing of directory-files doesn't
arm.
It's what I did here (in anything) and it is nice feature IMO.
On GNU/Linux, having "." and ".." in (directory-files "/") is not a
problem.
Do you think this can create problems in some places?
--
Thierry
Get my Gnupg key:
gpg --keyserver pgp.mit.edu --recv-keys 59F29997
- Re: Behavior of directory-files on Windows, (continued)
Re: Behavior of directory-files on Windows, Eli Zaretskii, 2011/12/01