-
Notifications
You must be signed in to change notification settings - Fork 1.1k
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
Handle idx and size unification in wrap_index manually. #5984
Conversation
@esc Recreation of previous PR with some git history issues. |
/AzurePipelines run |
Azure Pipelines successfully started running 1 pipeline(s). |
@stuartarchibald Yes, that is right. |
/AzurePipelines run |
Azure Pipelines successfully started running 1 pipeline(s). |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Thanks for the patch, couple of minor things to resolve else looks good.
Co-authored-by: stuartarchibald <stuartarchibald@users.noreply.github.com>
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Thanks for the patch!
Resolves #5442
wrap_index has to compare idx and size and to do that they need to be the same bitwidth. If one is signed and the other unsigned then the old code to unify to the same bitwidth (based on numpy rules) would also switch the type to double. In this PR, we keep the incoming integer types but just extend the bitwidth to be the max of the incoming types. We handle signedness extension correctly as well.