diff options
| author | Eli Zaretskii | 2014-12-04 09:58:19 +0200 |
|---|---|---|
| committer | Eli Zaretskii | 2014-12-04 09:58:19 +0200 |
| commit | 2bef807c322b44cf63db85e4b60001a76cbe3d9f (patch) | |
| tree | 276c63de005f8ec78523ffa9415a56dcfa0748da /lisp | |
| parent | a0363ffa9931cf751a92577ab1b0a7acbae4c4e7 (diff) | |
| download | emacs-2bef807c322b44cf63db85e4b60001a76cbe3d9f.tar.gz emacs-2bef807c322b44cf63db85e4b60001a76cbe3d9f.zip | |
lisp/files.el (file-tree-walk): Doc fix.
Diffstat (limited to 'lisp')
| -rw-r--r-- | lisp/ChangeLog | 4 | ||||
| -rw-r--r-- | lisp/files.el | 13 |
2 files changed, 14 insertions, 3 deletions
diff --git a/lisp/ChangeLog b/lisp/ChangeLog index 819e0d0a1b2..9c729bc936f 100644 --- a/lisp/ChangeLog +++ b/lisp/ChangeLog | |||
| @@ -1,3 +1,7 @@ | |||
| 1 | 2014-12-04 Eli Zaretskii <eliz@gnu.org> | ||
| 2 | |||
| 3 | * files.el (file-tree-walk): Doc fix. | ||
| 4 | |||
| 1 | 2014-12-04 Rupert Swarbrick <ruperts@broadcom.com> (tiny change) | 5 | 2014-12-04 Rupert Swarbrick <ruperts@broadcom.com> (tiny change) |
| 2 | RĂ¼diger Sonderfeld <ruediger@c-plusplus.net> | 6 | RĂ¼diger Sonderfeld <ruediger@c-plusplus.net> |
| 3 | 7 | ||
diff --git a/lisp/files.el b/lisp/files.el index 740a00a41e3..0f54a22d61e 100644 --- a/lisp/files.el +++ b/lisp/files.el | |||
| @@ -730,10 +730,17 @@ The path separator is colon in GNU and GNU-like systems." | |||
| 730 | (error "No such directory found via CDPATH environment variable")))) | 730 | (error "No such directory found via CDPATH environment variable")))) |
| 731 | 731 | ||
| 732 | (defun file-tree-walk (dir action &rest args) | 732 | (defun file-tree-walk (dir action &rest args) |
| 733 | "Walk DIR executing ACTION on each path, with ARGS as additional arguments. | 733 | "Walk DIR executing ACTION on each file, with ARGS as additional arguments. |
| 734 | Each call gets as arguments DIR, a file path, and optional ARGS. | 734 | For each file, the function calls ACTION as follows: |
| 735 | |||
| 736 | \(ACTION DIRECTORY BASENAME ARGS\) | ||
| 737 | |||
| 738 | Where DIRECTORY is the leading directory of the file, | ||
| 739 | BASENAME is the basename of the file, | ||
| 740 | and ARGS are as specified in the call to this function, or nil if omitted. | ||
| 741 | |||
| 735 | The ACTION is applied to each subdirectory before descending into | 742 | The ACTION is applied to each subdirectory before descending into |
| 736 | it, and if nil is returned at that point the descent will be | 743 | it, and if nil is returned at that point, the descent will be |
| 737 | prevented. Directory entries are sorted with string-lessp." | 744 | prevented. Directory entries are sorted with string-lessp." |
| 738 | (cond ((file-directory-p dir) | 745 | (cond ((file-directory-p dir) |
| 739 | (or (char-equal ?/ (aref dir (1- (length dir)))) | 746 | (or (char-equal ?/ (aref dir (1- (length dir)))) |