Skip to content

Commit 5971c68

Browse files
committed
Add version guard
1 parent 09e0f1b commit 5971c68

File tree

2 files changed

+4
-0
lines changed

2 files changed

+4
-0
lines changed

pandas/_libs/src/datetime/pd_datetime.c

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -246,7 +246,9 @@ static int pandas_datetime_exec(PyObject *Py_UNUSED(module)) {
246246

247247
static PyModuleDef_Slot pandas_datetime_slots[] = {
248248
{Py_mod_exec, pandas_datetime_exec},
249+
#if PY_VERSION_HEX >= 0x030D0000
249250
{Py_mod_gil, Py_MOD_GIL_NOT_USED},
251+
#endif
250252
{0, NULL},
251253
};
252254

pandas/_libs/src/parser/pd_parser.c

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -162,7 +162,9 @@ static int pandas_parser_exec(PyObject *Py_UNUSED(module)) {
162162

163163
static PyModuleDef_Slot pandas_parser_slots[] = {
164164
{Py_mod_exec, pandas_parser_exec},
165+
#if PY_VERSION_HEX >= 0x030D0000
165166
{Py_mod_gil, Py_MOD_GIL_NOT_USED},
167+
#endif
166168
{0, NULL},
167169
};
168170

0 commit comments

Comments
 (0)