[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
master 864847bf3c: Document time-convert FORM argument as mandatory
From: |
Basil L. Contovounesios |
Subject: |
master 864847bf3c: Document time-convert FORM argument as mandatory |
Date: |
Sat, 13 Aug 2022 15:19:19 -0400 (EDT) |
branch: master
commit 864847bf3c9f041256e32353b323ddafee86f6da
Author: Basil L. Contovounesios <contovob@tcd.ie>
Commit: Basil L. Contovounesios <contovob@tcd.ie>
Document time-convert FORM argument as mandatory
This is a followup to commit b70369c557 of 2022-08-05
"time-convert): Deprecate calls without an explicit FORM arg".
* doc/lispref/os.texi (Time Conversion):
* src/timefns.c (Ftime_convert): Describe FORM argument as required
as per the advertised calling convention.
---
doc/lispref/os.texi | 10 +++++-----
src/timefns.c | 5 ++---
2 files changed, 7 insertions(+), 8 deletions(-)
diff --git a/doc/lispref/os.texi b/doc/lispref/os.texi
index d591b219cd..3582801841 100644
--- a/doc/lispref/os.texi
+++ b/doc/lispref/os.texi
@@ -1544,11 +1544,11 @@ as traditional Gregorian years do; for example, the
year number
@defun time-convert time form
This function converts a time value into a Lisp timestamp.
-The optional @var{form} argument specifies the timestamp form to be
-returned. If @var{form} is the symbol @code{integer}, this function
-returns an integer count of seconds. If @var{form} is a positive
-integer, it specifies a clock frequency and this function returns an
-integer-pair timestamp @code{(@var{ticks} . @var{form})}. If @var{form} is
+The @var{form} argument specifies the timestamp form to be returned.
+If @var{form} is the symbol @code{integer}, this function returns an
+integer count of seconds. If @var{form} is a positive integer, it
+specifies a clock frequency and this function returns an integer-pair
+timestamp @code{(@var{ticks} . @var{form})}. If @var{form} is
@code{t}, this function treats it as a positive integer suitable for
representing the timestamp; for example, it is treated as 1000000000
if @var{time} is @code{nil} and the platform timestamp has nanosecond
diff --git a/src/timefns.c b/src/timefns.c
index 8b1e729d4f..7db50ea81c 100644
--- a/src/timefns.c
+++ b/src/timefns.c
@@ -1714,11 +1714,10 @@ usage: (encode-time TIME &rest OBSOLESCENT-ARGUMENTS)
*/)
}
DEFUN ("time-convert", Ftime_convert, Stime_convert, 1, 2, 0,
- doc: /* Convert TIME value to a Lisp timestamp.
-With optional FORM, convert to that timestamp form.
+ doc: /* Convert TIME value to a Lisp timestamp of the given FORM.
Truncate the returned value toward minus infinity.
-If FORM is nil (the default), return the same form as `current-time'.
+If FORM is nil, return the same form as `current-time'.
If FORM is a positive integer, return a pair of integers (TICKS . FORM),
where TICKS is the number of clock ticks and FORM is the clock frequency
[Prev in Thread] |
Current Thread |
[Next in Thread] |
- master 864847bf3c: Document time-convert FORM argument as mandatory,
Basil L. Contovounesios <=