[NumPy-Tickets] [NumPy] #1931: np.left_shift and np.right_shift fail on np.uint64 scalar types

NumPy Trac numpy-tickets@scipy....
Sat Aug 13 13:35:35 CDT 2011


#1931: np.left_shift and np.right_shift fail on np.uint64 scalar types
------------------------+---------------------------------------------------
 Reporter:  tlatorre    |       Owner:  somebody   
     Type:  defect      |      Status:  new        
 Priority:  high        |   Milestone:  Unscheduled
Component:  numpy.core  |     Version:  1.6.0      
 Keywords:              |  
------------------------+---------------------------------------------------

Comment(by charris):

 This is because the shift number is converted as a signed type and there
 is no signed integer type big enough to hold a uint64. The shift operators
 need to be special cased, they can also fail on Intel because the hardware
 masks out the unneeded bits, i.e., for int32 only the lower 5 bits are
 looked at.

-- 
Ticket URL: <http://projects.scipy.org/numpy/ticket/1931#comment:1>
NumPy <http://projects.scipy.org/numpy>
My example project


More information about the NumPy-Tickets mailing list