Disable PYBIND11_ASSERT_GIL_HELD_INCREF_DECREF generally for PyPy (not just PyPy Windows). (#4751)

This commit is contained in:
Ralf W. Grosse-Kunstleve 2023-07-15 12:55:00 -07:00 committed by GitHub
parent 0620d71638
commit ec1b57c50c
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23

View File

@ -324,10 +324,7 @@ PYBIND11_WARNING_POP
#endif
// See description of PR #4246:
#if !defined(NDEBUG) && !defined(PY_ASSERT_GIL_HELD_INCREF_DECREF) \
&& !(defined(PYPY_VERSION) \
&& defined(_MSC_VER)) /* PyPy Windows: pytest hangs indefinitely at the end of the \
process (see PR #4268) */ \
#if !defined(NDEBUG) && !defined(PY_ASSERT_GIL_HELD_INCREF_DECREF) && !defined(PYPY_VERSION) \
&& !defined(PYBIND11_ASSERT_GIL_HELD_INCREF_DECREF)
# define PYBIND11_ASSERT_GIL_HELD_INCREF_DECREF
#endif