[Numpy-discussion] Possible errors in type promotion in binary ufuncs

Travis E. Oliphant oliphant@enthought....
Tue May 27 15:02:17 CDT 2008

Charles R Harris wrote:
> Attached as a zip file. The mailing list is still stuck in the 
> microzone, 40kb limit.

The type promotion rules are the same for all the ufuncs.   I'm not sure 
what the value is in going over each binary ufunc one-by-one.    The 
behavior is based on how ufuncs are found and the casting rules.

In other words, these are not independently coded,  so why are you going 
over each one separately.

Your symmetry concern is minor in my mind.  You are worried about the 
difference between 'i' and 'l' for the output types.   These are the 
same type on 32-bit platforms and which one is selected is a function of 
how the ufuncs are found.

It is true that we have over-registered ufuncs on some platforms (i.e. 
we don't need an 'i' and an 'l' ufunc inner loop when they are the same 


More information about the Numpy-discussion mailing list