diff options
author | Nathaniel J. Smith <njs@pobox.com> | 2015-08-27 00:02:17 -0700 |
---|---|---|
committer | Nathaniel J. Smith <njs@pobox.com> | 2015-10-01 16:03:18 -0700 |
commit | 899325ec043688c751001662f5e7226e7e92e04e (patch) | |
tree | a309b1a2a7c2d8b7480eb5ecc7ddd6f49539c375 /doc/source | |
parent | 1765438b5f68eeb5c9b920e8df2760dc8e908cae (diff) | |
download | numpy-899325ec043688c751001662f5e7226e7e92e04e.tar.gz |
MAINT: cleanup dead code/arguments/fields from ufuncs
The check_return argument and ufunc object field was never used; ditto
for the "new" inner loop selector (which was never implemented), along
with associated typedefs. Since I was looking at this code anyway trying
to figure out which parts were actually in use, I figured I'd clear up
some of the brush to make it easier next time...
Diffstat (limited to 'doc/source')
-rw-r--r-- | doc/source/reference/c-api.types-and-structures.rst | 7 | ||||
-rw-r--r-- | doc/source/reference/c-api.ufunc.rst | 11 | ||||
-rw-r--r-- | doc/source/user/c-info.ufunc-tutorial.rst | 7 |
3 files changed, 8 insertions, 17 deletions
diff --git a/doc/source/reference/c-api.types-and-structures.rst b/doc/source/reference/c-api.types-and-structures.rst index 35ffc2d1e..d7342bd9e 100644 --- a/doc/source/reference/c-api.types-and-structures.rst +++ b/doc/source/reference/c-api.types-and-structures.rst @@ -681,7 +681,7 @@ PyUFunc_Type PyUFuncGenericFunction *functions; void **data; int ntypes; - int check_return; + int reserved1; const char *name; char *types; const char *doc; @@ -748,11 +748,6 @@ PyUFunc_Type specifies how many different 1-d loops (of the builtin data types) are available. - .. c:member:: int PyUFuncObject.check_return - - Obsolete and unused. However, it is set by the corresponding entry in - the main ufunc creation routine: :c:func:`PyUFunc_FromFuncAndData` (...). - .. c:member:: char *PyUFuncObject.name A string name for the ufunc. This is used dynamically to build diff --git a/doc/source/reference/c-api.ufunc.rst b/doc/source/reference/c-api.ufunc.rst index ee1822122..892ccbdc7 100644 --- a/doc/source/reference/c-api.ufunc.rst +++ b/doc/source/reference/c-api.ufunc.rst @@ -67,7 +67,7 @@ Functions .. c:function:: PyObject* PyUFunc_FromFuncAndData(PyUFuncGenericFunction* func, void** data, char* types, int ntypes, int nin, int nout, int identity, - char* name, char* doc, int check_return) + char* name, char* doc, int unused) Create a new broadcasting universal function from required variables. Each ufunc builds around the notion of an element-by-element @@ -121,15 +121,12 @@ Functions dynamically determined from the object and available when accessing the **__doc__** attribute of the ufunc. - :param check_return: - Unused and present for backwards compatibility of the C-API. A - corresponding *check_return* integer does exist in the ufunc - structure and it does get set with this value when the ufunc - object is created. + :param unused: + Unused and present for backwards compatibility of the C-API. .. c:function:: PyObject* PyUFunc_FromFuncAndDataAndSignature(PyUFuncGenericFunction* func, void** data, char* types, int ntypes, int nin, int nout, int identity, - char* name, char* doc, int check_return, char *signature) + char* name, char* doc, int unused, char *signature) This function is very similar to PyUFunc_FromFuncAndData above, but has an extra *signature* argument, to define generalized universal functions. diff --git a/doc/source/user/c-info.ufunc-tutorial.rst b/doc/source/user/c-info.ufunc-tutorial.rst index db25568b9..109e6adb5 100644 --- a/doc/source/user/c-info.ufunc-tutorial.rst +++ b/doc/source/user/c-info.ufunc-tutorial.rst @@ -1060,7 +1060,7 @@ automatically generates a ufunc from a C function with the correct signature. .. c:function:: PyObject *PyUFunc_FromFuncAndData( PyUFuncGenericFunction* func, void** data, char* types, int ntypes, int nin, int nout, int identity, - char* name, char* doc, int check_return) + char* name, char* doc, int unused) *func* @@ -1170,10 +1170,9 @@ automatically generates a ufunc from a C function with the correct signature. response to ``{ufunc_name}.__doc__``). Do not include the function signature or the name as this is generated automatically. - *check_return* + *unused* - Not presently used, but this integer value does get set in the - structure-member of similar name. + Unused; kept for compatiblity. Just set it to zero. .. index:: pair: ufunc; adding new |