bug-gnu-emacs
[Top][All Lists]
Advanced

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Documentation of file-exists-p in the elisp manual could be better...


From: Dan Katz
Subject: Documentation of file-exists-p in the elisp manual could be better...
Date: Thu, 05 Jun 2003 14:05:03 -0400
User-agent: Gnus/5.1003 (Gnus v5.10.3) Emacs/21.3 (gnu/linux)

In GNU Emacs 21.3.2 (i386-pc-linux-gnu, X toolkit, Xaw3d scroll bars)
 of 2003-04-24 on raven, modified by Debian



Hi.

I went looking for a way to find out if a directory existed, and ended
up using file-exists-p.  Looking at the elisp manual, however, did not
make it clear whether this was the correct approach or whether it was
"working by accident."  In particular, the elisp manual description of
file-exists-p was not really clear whether (or how) this function
would (or should) work for directories, sym-links, etc.  While it
seems to basically "do the right thing", I suggest that the
documentation needs to be a bit more explicit about notions of
"generalized" files and how the file-handling functions apply.

The docstring for file-exists-p was not much use in this regard,
although it's link to file-attributes is what led me to suspect that
file-exists-p might be the correct approach for directories as well.
That's a rather indirect hint, however.

I hope this documentation commentary is useful.

Dan






reply via email to

[Prev in Thread] Current Thread [Next in Thread]