doc: clarify reltime()

Closes #5301
This commit is contained in:
Justin M. Keyes 2016-09-05 20:11:26 -04:00
parent df99c6493d
commit d9d2c2fcc0

View File

@ -5480,14 +5480,23 @@ reltime([{start} [, {end}]]) *reltime()*
the item depends on the system. It can be passed to the item depends on the system. It can be passed to
|reltimestr()| to convert it to a string or |reltimefloat()| |reltimestr()| to convert it to a string or |reltimefloat()|
to convert to a float. to convert to a float.
Without an argument it returns the current time.
With one argument is returns the time passed since the time Without an argument it returns the current "relative time",
an implementation-dependent value meaningful only in the
context of:
1. comparison with other reltime() results
2. |reltimestr()|
3. |reltimefloat()|
With one argument it returns the time passed since the time
specified in the argument. specified in the argument.
With two arguments it returns the time passed between {start} With two arguments it returns the time passed between {start}
and {end}. and {end}.
The {start} and {end} arguments must be values returned by The {start} and {end} arguments must be values returned by
reltime(). reltime().
Note: |localtime()| returns the current (non-relative) time.
reltimefloat({time}) *reltimefloat()* reltimefloat({time}) *reltimefloat()*
Return a Float that represents the time value of {time}. Return a Float that represents the time value of {time}.
Unit of time is seconds. Unit of time is seconds.