summaryrefslogtreecommitdiffstats
path: root/Python
diff options
context:
space:
mode:
authorVictor Stinner <vstinner@python.org>2023-06-01 11:41:56 (GMT)
committerGitHub <noreply@github.com>2023-06-01 11:41:56 (GMT)
commitec0082ca460f6b5eaf987536d28d6bc252322307 (patch)
tree0eb0150c09e917aa1b37acffa3c6168d625a080a /Python
parent9ab587b7146618866cee52c220aecf7bd5b44b02 (diff)
downloadcpython-ec0082ca460f6b5eaf987536d28d6bc252322307.zip
cpython-ec0082ca460f6b5eaf987536d28d6bc252322307.tar.gz
cpython-ec0082ca460f6b5eaf987536d28d6bc252322307.tar.bz2
gh-105182: Remove PyEval_AcquireLock() and PyEval_InitThreads() (#105183)
Remove functions in the C API: * PyEval_AcquireLock() * PyEval_ReleaseLock() * PyEval_InitThreads() * PyEval_ThreadsInitialized() But keep these functions in the stable ABI. Mention "make regen-limited-abi" in "make regen-all".
Diffstat (limited to 'Python')
-rw-r--r--Python/ceval_gil.c13
1 files changed, 9 insertions, 4 deletions
diff --git a/Python/ceval_gil.c b/Python/ceval_gil.c
index b9bdb74..536991f 100644
--- a/Python/ceval_gil.c
+++ b/Python/ceval_gil.c
@@ -496,7 +496,8 @@ _PyEval_ThreadsInitialized(void)
return gil_created(gil);
}
-int
+// Function removed in the Python 3.13 API but kept in the stable ABI.
+PyAPI_FUNC(int)
PyEval_ThreadsInitialized(void)
{
return _PyEval_ThreadsInitialized();
@@ -584,7 +585,8 @@ _PyEval_FiniGIL(PyInterpreterState *interp)
interp->ceval.gil = NULL;
}
-void
+// Function removed in the Python 3.13 API but kept in the stable ABI.
+PyAPI_FUNC(void)
PyEval_InitThreads(void)
{
/* Do nothing: kept for backward compatibility */
@@ -597,7 +599,9 @@ _PyEval_Fini(void)
_Py_PrintSpecializationStats(1);
#endif
}
-void
+
+// Function removed in the Python 3.13 API but kept in the stable ABI.
+PyAPI_FUNC(void)
PyEval_AcquireLock(void)
{
PyThreadState *tstate = _PyThreadState_GET();
@@ -606,7 +610,8 @@ PyEval_AcquireLock(void)
take_gil(tstate);
}
-void
+// Function removed in the Python 3.13 API but kept in the stable ABI.
+PyAPI_FUNC(void)
PyEval_ReleaseLock(void)
{
PyThreadState *tstate = _PyThreadState_GET();