[Numpy-discussion] ULONG not in UINT16, UINT32, UINT64 under 64-bit windows, is this possible?
Pearu Peterson
pearu.peterson at gmail.com
Mon Aug 15 08:50:40 EDT 2011
Hi,
A student of mine using 32-bit numpy 1.5 under 64-bit Windows 7 noticed that
giving a numpy array with dtype=uint32 to an extension module the
following codelet would fail:
switch(PyArray_TYPE(ARR)) {
case PyArray_UINT16: /* do smth */ break;
case PyArray_UINT32: /* do smth */ break;
case PyArray_UINT64: /* do smth */ break;
default: /* raise type error exception */
}
The same test worked fine under Linux.
Checking the value of PyArray_TYPE(ARR) (=8) showed that it corresponds to
NPY_ULONG (when counting the items in the enum definition).
Is this situation possible where NPY_ULONG does not correspond to a 16 or 32
or 64 bit integer?
Or does this indicate a bug somewhere for this particular platform?
Thanks,
Pearu
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://mail.python.org/pipermail/numpy-discussion/attachments/20110815/5d1b7136/attachment.html>
More information about the NumPy-Discussion
mailing list