[SciPy-Dev] ticket #1102, long -> npy_intp

Pauli Virtanen pav@iki...
Thu Jun 17 06:35:02 CDT 2010

Thu, 17 Jun 2010 19:28:17 +0800, Ralf Gommers wrote:
> Can any C guru confirm that the patch in
> http://projects.scipy.org/scipy/ticket/1102 is correct? It works on my
> 32-bit system and fixes a 64-bit problem. Do I understand correctly that
> long varies in size for 32/64-bit and npy_intp does not, therefore the
> latter is preferred?

Yes, sizeof(npy_intp) is the same as the pointer size, and may be 
different from sizeof(long).

The patch seems OK, especially as the code later on tries to access the 
data as intp*.

Pauli Virtanen

More information about the SciPy-Dev mailing list