mirror of
https://github.com/psycopg/psycopg2.git
synced 2024-11-25 18:33:44 +03:00
_PyInterpreterState_Get() has become public in Python 3.13
Since 3.13.0a1 it has been renamed to PyInterpreterStateGet() Source: https://github.com/python/cpython/pull/106321
This commit is contained in:
parent
a971c11d50
commit
829a7a2be9
|
@ -392,7 +392,10 @@ psyco_set_error(PyObject *exc, cursorObject *curs, const char *msg)
|
||||||
static int
|
static int
|
||||||
psyco_is_main_interp(void)
|
psyco_is_main_interp(void)
|
||||||
{
|
{
|
||||||
#if PY_VERSION_HEX >= 0x03080000
|
#if PY_VERSION_HEX >= 0x030d0000
|
||||||
|
/* tested with Python 3.13.0a6 */
|
||||||
|
return PyInterpreterState_Get() == PyInterpreterState_Main();
|
||||||
|
#elif PY_VERSION_HEX >= 0x03080000
|
||||||
/* tested with Python 3.8.0a2 */
|
/* tested with Python 3.8.0a2 */
|
||||||
return _PyInterpreterState_Get() == PyInterpreterState_Main();
|
return _PyInterpreterState_Get() == PyInterpreterState_Main();
|
||||||
#else
|
#else
|
||||||
|
|
Loading…
Reference in New Issue
Block a user