aboutsummaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorChong Yidong2011-08-08 12:06:34 -0400
committerChong Yidong2011-08-08 12:06:34 -0400
commit51a714e101630c9f40d460339123c2bf89d4d1ca (patch)
tree6285b9f752a6059a4ae0162c1f41ed94202f0f5f
parent37e11a631937986f03f6216655ea1c964f7286aa (diff)
downloademacs-51a714e101630c9f40d460339123c2bf89d4d1ca.tar.gz
emacs-51a714e101630c9f40d460339123c2bf89d4d1ca.zip
Fix explanation about setting the time zone in Lisp manual.
* doc/lispref/os.texi (Time of Day): Remove set-time-zone-rule, and recommend using setenv instead.
-rw-r--r--doc/lispref/ChangeLog5
-rw-r--r--doc/lispref/os.texi36
2 files changed, 22 insertions, 19 deletions
diff --git a/doc/lispref/ChangeLog b/doc/lispref/ChangeLog
index f08ee3a227c..bf170100922 100644
--- a/doc/lispref/ChangeLog
+++ b/doc/lispref/ChangeLog
@@ -1,3 +1,8 @@
12011-08-08 Chong Yidong <cyd@stupidchicken.com>
2
3 * os.texi (Time of Day): Remove set-time-zone-rule, and recommend
4 using setenv instead.
5
12011-07-28 Eli Zaretskii <eliz@gnu.org> 62011-07-28 Eli Zaretskii <eliz@gnu.org>
2 7
3 * display.texi (Bidirectional Display): Document the fact that 8 * display.texi (Bidirectional Display): Document the fact that
diff --git a/doc/lispref/os.texi b/doc/lispref/os.texi
index 5f422065c5b..8533b77b219 100644
--- a/doc/lispref/os.texi
+++ b/doc/lispref/os.texi
@@ -1143,6 +1143,18 @@ get with the function @code{file-attributes}.
1143@xref{Definition of file-attributes}. 1143@xref{Definition of file-attributes}.
1144@end defun 1144@end defun
1145 1145
1146@defun float-time &optional time-value
1147This function returns the current time as a floating-point number of
1148seconds since the epoch. The argument @var{time-value}, if given,
1149specifies a time to convert instead of the current time. The argument
1150should have the same form as for @code{current-time-string} (see
1151above). Thus, it accepts the output of @code{current-time} and
1152@code{file-attributes} (@pxref{Definition of file-attributes}).
1153
1154@emph{Warning}: Since the result is floating point, it may not be
1155exact. Do not use this function if precise time stamps are required.
1156@end defun
1157
1146@defun current-time-zone &optional time-value 1158@defun current-time-zone &optional time-value
1147This function returns a list describing the time zone that the user is 1159This function returns a list describing the time zone that the user is
1148in. 1160in.
@@ -1165,25 +1177,11 @@ times obtained from @code{current-time} (see above) and from
1165@code{file-attributes}. @xref{Definition of file-attributes}. 1177@code{file-attributes}. @xref{Definition of file-attributes}.
1166@end defun 1178@end defun
1167 1179
1168@defun set-time-zone-rule tz 1180The current time zone is determined by the @samp{TZ} environment
1169This function specifies the local time zone according to @var{tz}. If 1181variable. @xref{System Environment}. For example, you can tell Emacs
1170@var{tz} is @code{nil}, that means to use an implementation-defined 1182to use universal time with @code{(setenv "TZ" "UTC0")}. If @samp{TZ}
1171default time zone. If @var{tz} is @code{t}, that means to use 1183is not in the environment, Emacs uses a platform-dependent default
1172Universal Time. Otherwise, @var{tz} should be a string specifying a 1184time zone.
1173time zone rule.
1174@end defun
1175
1176@defun float-time &optional time-value
1177This function returns the current time as a floating-point number of
1178seconds since the epoch. The argument @var{time-value}, if given,
1179specifies a time to convert instead of the current time. The argument
1180should have the same form as for @code{current-time-string} (see
1181above). Thus, it accepts the output of @code{current-time} and
1182@code{file-attributes} (@pxref{Definition of file-attributes}).
1183
1184@emph{Warning}: Since the result is floating point, it may not be
1185exact. Do not use this function if precise time stamps are required.
1186@end defun
1187 1185
1188@node Time Conversion 1186@node Time Conversion
1189@section Time Conversion 1187@section Time Conversion