PEP 410: drop int type, add an argument against the datetime type
This commit is contained in:
parent
79b06628e2
commit
7bed2dcc53
|
@ -53,9 +53,8 @@ Add a *timestamp* optional argument to:
|
|||
* time module: clock(), clock_gettime(), clock_getres(), time() and
|
||||
wallclock()
|
||||
|
||||
The *timestamp* argument is a type, there are three supported types:
|
||||
The *timestamp* argument is a type, there are two supported types:
|
||||
|
||||
* int
|
||||
* float
|
||||
* decimal.Decimal
|
||||
|
||||
|
@ -68,7 +67,8 @@ precision) in functions having timestamp arguments:
|
|||
* time.gmtime(), time.localtime()
|
||||
* os.utimensat(), os.futimens()
|
||||
|
||||
The os.stat_float_times() is deprecated: use timestamp=int argument instead.
|
||||
The os.stat_float_times() is deprecated: use an explicit cast using int()
|
||||
instead.
|
||||
|
||||
.. note::
|
||||
The decimal module is implemented in Python and is slow, but there is a C
|
||||
|
@ -123,6 +123,9 @@ with the Python license.
|
|||
datetime.datetime
|
||||
-----------------
|
||||
|
||||
Most functions returning timestamps don't have a known starting point or
|
||||
timezone information, and so cannot be converted to datetime.datetime.
|
||||
|
||||
datetime.datetime only supports microsecond resolution, but can be enhanced
|
||||
to support nanosecond.
|
||||
|
||||
|
|
Loading…
Reference in New Issue