Skip to content

Commit

Permalink
Fix 'gil_slot set but not used' warning
Browse files Browse the repository at this point in the history
  • Loading branch information
swtaarrs committed May 1, 2024
1 parent 8846586 commit 99bc5cb
Showing 1 changed file with 2 additions and 0 deletions.
2 changes: 2 additions & 0 deletions Objects/moduleobject.c
Original file line number Diff line number Diff line change
Expand Up @@ -392,6 +392,8 @@ PyModule_FromDefAndSpec2(PyModuleDef* def, PyObject *spec, int module_api_versio
((PyModuleObject*)m)->md_def = def;
#ifdef Py_GIL_DISABLED
((PyModuleObject*)m)->md_gil = gil_slot;
#else
(void)gil_slot;
#endif
} else {
if (def->m_size > 0 || def->m_traverse || def->m_clear || def->m_free) {
Expand Down

0 comments on commit 99bc5cb

Please sign in to comment.