diff options
author | Christophe Troestler <Christophe.Troestler@umons.ac.be> | 2017-02-17 22:17:16 +0100 |
---|---|---|
committer | Christophe Troestler <Christophe.Troestler@umons.ac.be> | 2017-02-17 22:17:16 +0100 |
commit | af092cccff1d100eb43e76b62eae97e8ccfde5a1 (patch) | |
tree | 01a7e8a4b51a31e374ef8bdfed66bf71c9584703 /otherlibs/unix | |
parent | 9e2177ed87839da1465b995558096bd2f1fbaa39 (diff) | |
download | ocaml-af092cccff1d100eb43e76b62eae97e8ccfde5a1.tar.gz |
Document how to perform the inverse of (gm|local)time
The goal is to make the documentation slightly more self contained on
the links between the time functions.
Diffstat (limited to 'otherlibs/unix')
-rw-r--r-- | otherlibs/unix/unix.mli | 7 |
1 files changed, 5 insertions, 2 deletions
diff --git a/otherlibs/unix/unix.mli b/otherlibs/unix/unix.mli index 6762c25316..0c8165ebe2 100644 --- a/otherlibs/unix/unix.mli +++ b/otherlibs/unix/unix.mli @@ -970,11 +970,14 @@ val gettimeofday : unit -> float val gmtime : float -> tm (** Convert a time in seconds, as returned by {!Unix.time}, into a date and - a time. Assumes UTC (Coordinated Universal Time), also known as GMT. *) + a time. Assumes UTC (Coordinated Universal Time), also known as GMT. + To perform the inverse conversion, set the TZ environment variable + to "UTC", use {!mktime}, and then restore the original value of TZ. *) val localtime : float -> tm (** Convert a time in seconds, as returned by {!Unix.time}, into a date and - a time. Assumes the local time zone. *) + a time. Assumes the local time zone. + The function performing the inverse conversion is {!mktime}. *) val mktime : tm -> float * tm (** Convert a date and time, specified by the [tm] argument, into |