diff options
author | Serhiy Storchaka <storchaka@gmail.com> | 2018-11-27 11:27:31 (GMT) |
---|---|---|
committer | GitHub <noreply@github.com> | 2018-11-27 11:27:31 (GMT) |
commit | 62be74290aca26d16f3f55ece7ff6dad14e60e8d (patch) | |
tree | 656625bee7ca61fd87c6370407162522d8fb277f /Modules/_multiprocessing | |
parent | 81524022d0c0df7a41f9b2b2df41e2ebe140e610 (diff) | |
download | cpython-62be74290aca26d16f3f55ece7ff6dad14e60e8d.zip cpython-62be74290aca26d16f3f55ece7ff6dad14e60e8d.tar.gz cpython-62be74290aca26d16f3f55ece7ff6dad14e60e8d.tar.bz2 |
bpo-33012: Fix invalid function cast warnings with gcc 8. (GH-6749)
Fix invalid function cast warnings with gcc 8
for method conventions different from METH_NOARGS, METH_O and
METH_VARARGS excluding Argument Clinic generated code.
Diffstat (limited to 'Modules/_multiprocessing')
-rw-r--r-- | Modules/_multiprocessing/semaphore.c | 4 |
1 files changed, 2 insertions, 2 deletions
diff --git a/Modules/_multiprocessing/semaphore.c b/Modules/_multiprocessing/semaphore.c index b1d3a21..e15adfb 100644 --- a/Modules/_multiprocessing/semaphore.c +++ b/Modules/_multiprocessing/semaphore.c @@ -581,11 +581,11 @@ semlock_afterfork(SemLockObject *self, PyObject *Py_UNUSED(ignored)) */ static PyMethodDef semlock_methods[] = { - {"acquire", (PyCFunction)semlock_acquire, METH_VARARGS | METH_KEYWORDS, + {"acquire", (PyCFunction)(void(*)(void))semlock_acquire, METH_VARARGS | METH_KEYWORDS, "acquire the semaphore/lock"}, {"release", (PyCFunction)semlock_release, METH_NOARGS, "release the semaphore/lock"}, - {"__enter__", (PyCFunction)semlock_acquire, METH_VARARGS | METH_KEYWORDS, + {"__enter__", (PyCFunction)(void(*)(void))semlock_acquire, METH_VARARGS | METH_KEYWORDS, "enter the semaphore/lock"}, {"__exit__", (PyCFunction)semlock_release, METH_VARARGS, "exit the semaphore/lock"}, |