Skip to content

Python3: all integers are now 64 bits integers and so if the target is a 32 bit integer we must always do the conversion #14

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

Open
wants to merge 1 commit into
base: master
Choose a base branch
from

Conversation

sweinst
Copy link
Contributor

@sweinst sweinst commented Oct 2, 2014

No description provided.

…bit integer we must always do the conversion
@tonyroberts
Copy link
Member

PyLong_AsLong returns a 32 bit long in python 3, so I don't think that your comment that all integers in python 3 are 64 bit is accurate (in fact the python integer type can be > than 64 bit as well). All python integer numbers are the python type 'long', but that is not the same as saying they're all the same as the C type 'long long'.

@tonyroberts
Copy link
Member

Looking at the code, I would think that removing the PyLong_Check for python3 would be a sufficient change? (Runtime.PyInt_AsLong calls PyLong_AsLong under python 3)

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants