diff options
author | Inada Naoki <songofacandy@gmail.com> | 2022-03-23 08:11:22 (GMT) |
---|---|---|
committer | GitHub <noreply@github.com> | 2022-03-23 08:11:22 (GMT) |
commit | 894d0ea5afa822c23286e9e68ed80bb1122b402d (patch) | |
tree | 7837fd6c7ee0183e18a9fd824f9aec28d995a45b /Python/pystate.c | |
parent | 795b365e8a6dfbeaa75780ed7807f8116f4537ca (diff) | |
download | cpython-894d0ea5afa822c23286e9e68ed80bb1122b402d.zip cpython-894d0ea5afa822c23286e9e68ed80bb1122b402d.tar.gz cpython-894d0ea5afa822c23286e9e68ed80bb1122b402d.tar.bz2 |
bpo-46864: Suppress deprecation warnings for ob_shash. (GH-32042)
Diffstat (limited to 'Python/pystate.c')
-rw-r--r-- | Python/pystate.c | 5 |
1 files changed, 4 insertions, 1 deletions
diff --git a/Python/pystate.c b/Python/pystate.c index 1b4e31b..3e28a6a 100644 --- a/Python/pystate.c +++ b/Python/pystate.c @@ -47,10 +47,13 @@ extern "C" { static PyThreadState *_PyGILState_GetThisThreadState(struct _gilstate_runtime_state *gilstate); static void _PyThreadState_Delete(PyThreadState *tstate, int check_current); - +/* Suppress deprecation warning for PyBytesObject.ob_shash */ +_Py_COMP_DIAG_PUSH +_Py_COMP_DIAG_IGNORE_DEPR_DECLS /* We use "initial" if the runtime gets re-used (e.g. Py_Finalize() followed by Py_Initialize(). */ static const _PyRuntimeState initial = _PyRuntimeState_INIT; +_Py_COMP_DIAG_POP static int alloc_for_runtime(PyThread_type_lock *plock1, PyThread_type_lock *plock2, |