diff options
author | Victor Stinner <victor.stinner@gmail.com> | 2015-03-27 17:16:17 (GMT) |
---|---|---|
committer | Victor Stinner <victor.stinner@gmail.com> | 2015-03-27 17:16:17 (GMT) |
commit | a47b881d86d46ba7c1ee3e007448339e1ed5e2d3 (patch) | |
tree | 80c5c02954314a3fb3da42966a315ac3eb6f6bd5 /Include | |
parent | 4bfb460d883bd224b61a0e7403a09ea093947890 (diff) | |
download | cpython-a47b881d86d46ba7c1ee3e007448339e1ed5e2d3.zip cpython-a47b881d86d46ba7c1ee3e007448339e1ed5e2d3.tar.gz cpython-a47b881d86d46ba7c1ee3e007448339e1ed5e2d3.tar.bz2 |
Issue #22117: time.time() now uses the new _PyTime_t API
* Add _PyTime_GetSystemClockWithInfo()
Diffstat (limited to 'Include')
-rw-r--r-- | Include/pytime.h | 8 |
1 files changed, 8 insertions, 0 deletions
diff --git a/Include/pytime.h b/Include/pytime.h index 9446b33..1648d03 100644 --- a/Include/pytime.h +++ b/Include/pytime.h @@ -145,6 +145,14 @@ PyAPI_FUNC(int) _PyTime_AsTimeval(_PyTime_t t, struct timeval *tv, _PyTime_round_t round); +/* Get the current time from the system clock. + * Fill clock information if info is not NULL. + * Raise an exception and return -1 on error, return 0 on success. + */ +PyAPI_FUNC(int) _PyTime_GetSystemClockWithInfo( + _PyTime_t *t, + _Py_clock_info_t *info); + /* Get the time of a monotonic clock, i.e. a clock that cannot go backwards. The clock is not affected by system clock updates. The reference point of the returned value is undefined, so that only the difference between the |