On 4/22/07, Christian Marquardt <[EMAIL PROTECTED]> wrote:

Hello,

The following is what I expected...

   >>> y = 1234
   >>> x = array([1], dtype = "uint64")
   >>> print x + y, (x + y).dtype.type
   [1235] <type 'numpy.uint64'>

but is this the way it should be? (numpy 1.0.2, Linux, Intel comilers)

   >>> print x[0] + y, type(x[0] + y)
   1235.0 <type 'numpy.float64'>


Looks like a bug to me:

In [5]: x = array([1],dtype=uint64)

In [6]: type(x[0])
Out[6]: <type 'numpy.uint64'>

In [7]: type(x[0]+1)
Out[7]: <type 'numpy.float64'>

Chuck
_______________________________________________
Numpy-discussion mailing list
[email protected]
http://projects.scipy.org/mailman/listinfo/numpy-discussion

Reply via email to