Skip to content
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

UInt64 can't handle 2**64 - 1 #19

Open
heftig opened this issue Nov 11, 2014 · 1 comment
Open

UInt64 can't handle 2**64 - 1 #19

heftig opened this issue Nov 11, 2014 · 1 comment

Comments

@heftig
Copy link

heftig commented Nov 11, 2014

Attempting to construct a UInt64(2 ** 64 - 1) fails with an OverflowError. I think Int64 and UInt64 should be be based on long, not int, as the latter is only guaranteed to fit 32 bits, signed. Even on x86_64 the signedness prevents its use for UInt64.

@cocagne
Copy link
Owner

cocagne commented Nov 19, 2014

That's probably right thing to do. My only concern is whether such a change might break existing applications though I suspect it would not.

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

No branches or pull requests

2 participants