-
-
Notifications
You must be signed in to change notification settings - Fork 9.7k
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
BUG: fix hashing of long integers under python3 #3800
Conversation
python3 long_hash is more complex than int_hash so instead of copying into numpy call it via the Python capi. Same for long long for wich the numpy hash function is not correct with python 2.7 on i386. Will be slower but doesn't need adapting each timy python changes. closes numpy#3793
tested on amd64, i386, win32 python 2 and 3 |
All tests pass on Windows with Python 2.7 and 3.3, 32 and 64 bit. |
Looks good to me
|
Thanks Julian. |
BUG: fix hashing of long integers under python3
I think it should it be backported to 1.8. |
It's a bug, so probably should go into 1.7 also. What is the difference for python 2? |
Only issue I can think of with the stable release thing is that it might
|
python2 is only broken on 32 bit with long long types, e.g. np.int64(-2**32) |
#3747 has not been backported to 1.8 and 1.7, this PR depends on it. |
nevermind, I forgot to pull on the maintainance branch |
python3 long_hash is more complex than int_hash so instead of copying
into numpy call it via the Python capi.
Same for long long for wich the numpy hash function is not correct with
python 2.7 on i386.
Will be slower but doesn't need adapting each timy python changes.
closes #3793