GNU bug report logs - #17073
24.3.50; file-symlink-p doesn't return t as described in the doc

Previous Next

Package: emacs;

Reported by: Michael Heerdegen <michael_heerdegen <at> web.de>

Date: Sun, 23 Mar 2014 19:34:03 UTC

Severity: minor

Found in version 24.3.50

Fixed in version 24.4

Done: Glenn Morris <rgm <at> gnu.org>

Bug is archived. No further changes may be made.

Full log


View this message in rfc822 format

From: Eli Zaretskii <eliz <at> gnu.org>
To: Juanma Barranquero <lekktu <at> gmail.com>
Cc: michael_heerdegen <at> web.de, rgm <at> gnu.org, 17073 <at> debbugs.gnu.org
Subject: bug#17073: 24.3.50; file-symlink-p doesn't return t as described in the doc
Date: Mon, 24 Mar 2014 05:52:31 +0200
> From: Juanma Barranquero <lekktu <at> gmail.com>
> Date: Mon, 24 Mar 2014 01:25:36 +0100
> 
> Perhaps it's me, but I don't find the doc for this function (in the
> elisp reference) particularly clear
> 
>  -- Function: file-symlink-p filename
>      If the file FILENAME is a symbolic link, the `file-symlink-p'
>      function returns the (non-recursive) link target as a string.
> 
> Here it agrees with your interpretation, so at least that is clear.
> 
>      (Determining the file name that the link points to from the target
>      is nontrivial.)  First, this function recursively follows symbolic
>      links at all levels of parent directories.
> 
> IIUC, it's saying (above) that it does not follow symbolic links to
> files recursively. But (below) that it does follow recursively
> symbolic links to directories, until it finds a file (or a symbolic
> link to a file). Is that?

The difference is between the file (a.k.a. "basename") part of the
file name, and the leading directories part.  And yes, it is true.




This bug report was last modified 11 years and 62 days ago.

Previous Next


GNU bug tracking system
Copyright (C) 1999 Darren O. Benham, 1997,2003 nCipher Corporation Ltd, 1994-97 Ian Jackson.