[Numpy-discussion] NumPy beta release plan
oliphant at ee.byu.edu
Mon Jul 10 14:06:10 CDT 2006
Russell E. Owen wrote:
>In article <44AF5BFA.70509 at ieee.org>,
> Travis Oliphant <oliphant.travis at ieee.org> wrote:
>>3) C-API names have prefix PyArray_ (like always), NPY_ or npy_.
>> The NPY_ and npy_ prefixes are new and were done to remove the
>> likelihood of name collisions when NumPy is used with another
>> library. The old (and un-prefixed) names are accessible by
>> importing numpy/noprefix.h instead of numpy/arrayobject.h
>This may be too late or too picky, but...
>This seems like too many choices, leading to possible confusion when
>reading other people's extensions or the numpy code itself. Could you
>standardize on one (I like npy_) or two (if you have to keep PyArray_
>for some reason and can't put it in a backwards-compatibility header
There is a logic behind it though.
The C-API function calls all have PyArray_ prefixes (as always in Numeric)
The macro captialized constants have NPY_ prefixes
Newly defined types with lower-case names have npy_ prefixes
More information about the Numpy-discussion