mirror of
https://github.com/python/cpython.git
synced 2025-10-09 08:31:26 +00:00
gh-91320: Use _PyCFunction_CAST() (#92251)
Replace "(PyCFunction)(void(*)(void))func" cast with _PyCFunction_CAST(func). Change generated by the command: sed -i -e \ 's!(PyCFunction)(void(\*)(void)) *\([A-Za-z0-9_]\+\)!_PyCFunction_CAST(\1)!g' \ $(find -name "*.c")
This commit is contained in:
parent
551d02b3e6
commit
804f2529d8
31 changed files with 146 additions and 146 deletions
|
@ -2633,7 +2633,7 @@ static PyMethodDef ndarray_methods [] =
|
|||
{
|
||||
{ "tolist", ndarray_tolist, METH_NOARGS, NULL },
|
||||
{ "tobytes", ndarray_tobytes, METH_NOARGS, NULL },
|
||||
{ "push", (PyCFunction)(void(*)(void))ndarray_push, METH_VARARGS|METH_KEYWORDS, NULL },
|
||||
{ "push", _PyCFunction_CAST(ndarray_push), METH_VARARGS|METH_KEYWORDS, NULL },
|
||||
{ "pop", ndarray_pop, METH_NOARGS, NULL },
|
||||
{ "add_suboffsets", ndarray_add_suboffsets, METH_NOARGS, NULL },
|
||||
{ "memoryview_from_buffer", ndarray_memoryview_from_buffer, METH_NOARGS, NULL },
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue