Support for 64bit integers (rebased) - #66
Merged
paurkedal merged 6 commits intoSep 25, 2025
Merged
Conversation
- Field.int: Accept conversions from 64 bit integers. This can
overflow, but on 64 bit platforms there is a large usable range
which has been accepted in the past. We may consider adding overflow
detection, though.
- Field.int64: Accept conversions from smaller integers.
Contributor
|
Hello, Could you please suggest if you are going to merge this? |
paurkedal
commented
Sep 9, 2025
Comment on lines
+111
to
+118
| | `Int64 i, `Int x | `Int x, `Int64 i -> Int64.(equal i (of_int x)) | ||
| | `Int64 i, `Float x | `Float x, `Int64 i -> Int64.to_float i = x | ||
| | `UInt64 i, `Int x | `Int x, `UInt64 i -> Unsigned.UInt64.(equal i (of_int x)) | ||
| | `UInt64 i, `Float x | `Float x, `UInt64 i -> Int64.to_float (Unsigned.UInt64.to_int64 i) = x | ||
| | `UInt64 i, `Int64 x | `Int64 x, `UInt64 i -> Int64.equal (Unsigned.UInt64.to_int64 i) x | ||
| | `Int _, _ | _, `Int _ -> false | ||
| | `Int64 _, _ | _, `Int64 _ -> false | ||
| | `UInt64 _, _ | _, `UInt64 _ -> false |
Collaborator
Author
There was a problem hiding this comment.
It looks you like are missing `Int64 _, `Int64 _ and `UInt64 _, `UIint64 _ cases here.
Collaborator
Author
|
Looks good, and I can see I already tentatively approved it in my comment to #43 Apr 10, so let's merge it, but please have a look at my comment on |
`Int64 _, `Int64 _ and `UInt64 _, `UIint64 _
Add cases to equal_field
Collaborator
Author
|
Thanks for the contribution! |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
This includes #43, my extra integer conversions, and rebases it on the current master branch.