-
Notifications
You must be signed in to change notification settings - Fork 891
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
[FEA] Add left and right index iterators for row_operators #3257
Comments
An alternative approach is the |
@trevorsm7 can you comment on whether this is still a problem and important to fix? |
I think this is still an issue that should be fixed. It's easy for The |
Closing this in favor of #10508 |
Is your feature request related to a problem? Please describe.
Issue #3207 fixed row_lexicographic_comparator when the left and right are not views into the same table. However, there is still an issue with disambiguation between indices into the left table and indices into the right table. For example, rator with the ordered sequence on the left and the values sequence on the right, but
thrust::upper_bound
uses the operator with the values sequence on the left and the ordered sequence on the right. It is very easy to initialize the comparator with the table views in the wrong order and there is no feedback at compile time if it is wrong.Describe the solution you'd like
Add counting iterators with a strong typedef index type (similar to those in wrapper_types.hpp), such that the comparator operator() can be overloaded to disambiguate between (left_index, right_index) and (right_index, left_index). A same_index type could also be added to support cases where left and right are the same table and there is a single iterator, such as
thrust::sort
. Additionally, it might make sense to rename left/right or lhs/rhs to first/second to make it more clear that first may not always be left.The text was updated successfully, but these errors were encountered: