diff options
author | Victor Stinner <vstinner@python.org> | 2024-02-21 10:46:00 (GMT) |
---|---|---|
committer | GitHub <noreply@github.com> | 2024-02-21 10:46:00 (GMT) |
commit | e4c34f04a197391576a692d77eaece1ea10abd87 (patch) | |
tree | 058b885d1c1bb090b4db8ea7763c28e4dcfd8df5 /Python/thread_pthread.h | |
parent | 69ab93082d14425aaac48b8393711c716575b132 (diff) | |
download | cpython-e4c34f04a197391576a692d77eaece1ea10abd87.zip cpython-e4c34f04a197391576a692d77eaece1ea10abd87.tar.gz cpython-e4c34f04a197391576a692d77eaece1ea10abd87.tar.bz2 |
gh-110850: Cleanup PyTime API: PyTime_t are nanoseconds (#115753)
PyTime_t no longer uses an arbitrary unit, it's always a number of
nanoseconds (64-bit signed integer).
* Rename _PyTime_FromNanosecondsObject() to _PyTime_FromLong().
* Rename _PyTime_AsNanosecondsObject() to _PyTime_AsLong().
* Remove pytime_from_nanoseconds().
* Remove pytime_as_nanoseconds().
* Remove _PyTime_FromNanoseconds().
Diffstat (limited to 'Python/thread_pthread.h')
-rw-r--r-- | Python/thread_pthread.h | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/Python/thread_pthread.h b/Python/thread_pthread.h index dee21f0..64cc600 100644 --- a/Python/thread_pthread.h +++ b/Python/thread_pthread.h @@ -495,7 +495,7 @@ PyThread_acquire_lock_timed(PyThread_type_lock lock, PY_TIMEOUT_T microseconds, timeout = _PyTime_FromMicrosecondsClamp(microseconds); } else { - timeout = _PyTime_FromNanoseconds(-1); + timeout = -1; } #ifdef HAVE_SEM_CLOCKWAIT |