Hi all,

I would like to deprecate three C-API functions (more may come later)
in https://github.com/numpy/numpy/pull/15427

The functions are:
  * PyArray_GetArrayParamsFromObject
  * PyUfunc_GenericCall
  * PyUFunc_SetUsesArraysAsData

I could not find downstream usage for any of these and they seem useful
only on first glance to me.

The first one is too complex (regarding scalars), simply converting to
an array first should be just as well.
The second one is almost identical to `PyObject_Call`. And the third
one is not even documented and while the idea is sound, I am not sure
that there are any cases where it is useful [0]

My idea is to add the deprecation warning now, and if nobody notices it
remove them as soon as 1.19 is released.

- Sebastian


[0] It seems useful for user datatypes/loop, but using it for those
does not seem possible (or at least straight forward), since they are
usually stored in a way not accessible through this function.

Attachment: signature.asc
Description: This is a digitally signed message part

_______________________________________________
NumPy-Discussion mailing list
NumPy-Discussion@python.org
https://mail.python.org/mailman/listinfo/numpy-discussion

Reply via email to