[SciPy-dev] Question about 64-bit integers being cast to double precision

Stephen Walton stephen.walton at csun.edu
Sun Oct 16 00:22:07 CDT 2005


Charles R Harris wrote:

>I think it is a good idea to keep double as the default, if only because
>Python expects it. If someone needs more control over the precision of
>arrays, why not do as c does and add functions sqrtf and sqrtl?
>  
>
Usages like sqrtf() and sqrtl() begin to look like pre-1975 Fortran, 
before generic functions were introduced.  I can't change Python's basic 
behavior, but would rather that sqrt(scipy_integer_array) be simply 
disallowed in favor of requiring the user to explicitly change the type 
of the array to float, double, or long double.




More information about the Scipy-dev mailing list