[SciPy-dev] Warnings about incompatibilities ahead
oliphant.travis at ieee.org
Fri Dec 2 15:24:36 CST 2005
This is a warning regarding changes to the C-API of scipy core I'm going
to check in (hopefully by the end of the day).
1) PyArray_Typecode structure is going away --- I always hated it. All
C-API interfaces that use it will instead take a pointer to
PyArray_Descr *. If the C-API actually used the funny fortran member of
the structure, a new argument called fortran will be placed in the
2) The itemsize member on the array is going back into the PyArray_Descr
where it belongs. Note that PyArray_ITEMSIZE(self) will not be affected
its just that
3) There will be a new attribute .descr that returns the PyArray_Descr
object (it's now a real object).
4) New C-API calls will be added.
These changes are being made to facilitated nested records, but I think
they are good changes anyway and now is better than later. I'm the one
who has to pay the biggest price by fixing all the code in scipy core to
get rid of PyArray_Typecode, references to self->itemsize and to allow
for dynamic PyArray_Descr * objects.
I noticed people are starting to use the C-API, so this is a warning not
to 1) use PyArray_Typecode and 2) use direct access to the itemsize
member of an array.
More information about the Scipy-dev