[Numpy-discussion] Integers to negative integer powers, time for a decision.

Krisztián Horváth raksi.raksi at gmail.com
Sat Oct 8 15:43:06 EDT 2016


Sorry, I was not clear enough. I meant that the second option (always
float) would be more coherent with Python3.

On Oct 8, 2016 9:36 PM, "Charles R Harris" <charlesr.harris at gmail.com>
wrote:



On Sat, Oct 8, 2016 at 1:31 PM, Krisztián Horváth <raksi.raksi at gmail.com>
wrote:

> Hello,
>
> I think it should be consistent with Python3. So, it should give back a
> float.
>
> Best regards,
> Krisztian
>
>
Can't do that and also return integers for positive powers. It isn't
possible to have behavior completely compatible with python for arrays:
can't have mixed type returns, can't have arbitrary precision integers.

Chuck

_______________________________________________
NumPy-Discussion mailing list
NumPy-Discussion at scipy.org
https://mail.scipy.org/mailman/listinfo/numpy-discussion
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://mail.python.org/pipermail/numpy-discussion/attachments/20161008/254fad31/attachment.html>


More information about the NumPy-Discussion mailing list