gh-99113: Add Py_MOD_PER_INTERPRETER_GIL_SUPPORTED (gh-104205)

Here we are doing no more than adding the value for Py_mod_multiple_interpreters and using it for stdlib modules.  We will start checking for it in gh-104206 (once PyInterpreterState.ceval.own_gil is added in gh-104204).
This commit is contained in:
Eric Snow 2023-05-05 15:11:27 -06:00 committed by GitHub
parent 1c420e138f
commit a9c6e0618f
No known key found for this signature in database
GPG key ID: 4AEE18F83AFDEB23
99 changed files with 144 additions and 4 deletions

View file

@ -110,12 +110,19 @@ static PyMethodDef module_methods[ ] = {
};
static PyModuleDef_Slot module_slots[] = {
{Py_mod_multiple_interpreters, Py_MOD_PER_INTERPRETER_GIL_SUPPORTED},
{0, NULL}
};
static struct PyModuleDef _posixshmemmodule = {
PyModuleDef_HEAD_INIT,
.m_name = "_posixshmem",
.m_doc = "POSIX shared memory module",
.m_size = 0,
.m_methods = module_methods,
.m_slots = module_slots,
};
/* Module init function */