[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
emacs-30 d664227f81a: ; More accurate documentation of 'file-newer-than-
From: |
Eli Zaretskii |
Subject: |
emacs-30 d664227f81a: ; More accurate documentation of 'file-newer-than-file-p' |
Date: |
Thu, 10 Oct 2024 04:04:39 -0400 (EDT) |
branch: emacs-30
commit d664227f81aed98097520877a16c5369403a6a2d
Author: Eli Zaretskii <eliz@gnu.org>
Commit: Eli Zaretskii <eliz@gnu.org>
; More accurate documentation of 'file-newer-than-file-p'
* doc/lispref/files.texi (File Attributes):
* src/fileio.c (Ffile_newer_than_file_p): Say the comparison uses
the last-modification times. (Bug#73709)
---
doc/lispref/files.texi | 3 ++-
src/fileio.c | 3 ++-
2 files changed, 4 insertions(+), 2 deletions(-)
diff --git a/doc/lispref/files.texi b/doc/lispref/files.texi
index 70db8521481..5c63f192447 100644
--- a/doc/lispref/files.texi
+++ b/doc/lispref/files.texi
@@ -1299,7 +1299,8 @@ and modification.
This function returns @code{t} if the file @var{filename1} is
newer than file @var{filename2}. If @var{filename1} does not
exist, it returns @code{nil}. If @var{filename1} does exist, but
-@var{filename2} does not, it returns @code{t}.
+@var{filename2} does not, it returns @code{t}. Otherwise, it compares
+the times of last modification of the files.
In the following example, assume that the file @file{aug-19} was written
on the 19th, @file{aug-20} was written on the 20th, and the file
diff --git a/src/fileio.c b/src/fileio.c
index 7afe3e75737..2db2760916b 100644
--- a/src/fileio.c
+++ b/src/fileio.c
@@ -3788,7 +3788,8 @@ DEFUN ("unix-sync", Funix_sync, Sunix_sync, 0, 0, "",
DEFUN ("file-newer-than-file-p", Ffile_newer_than_file_p,
Sfile_newer_than_file_p, 2, 2, 0,
doc: /* Return t if file FILE1 is newer than file FILE2.
If FILE1 does not exist, the answer is nil;
-otherwise, if FILE2 does not exist, the answer is t. */)
+otherwise, if FILE2 does not exist, the answer is t.
+For existing files, this compares their last-modified times. */)
(Lisp_Object file1, Lisp_Object file2)
{
struct stat st1, st2;
[Prev in Thread] |
Current Thread |
[Next in Thread] |
- emacs-30 d664227f81a: ; More accurate documentation of 'file-newer-than-file-p',
Eli Zaretskii <=