-
Notifications
You must be signed in to change notification settings - Fork 1.5k
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
Implement ranges::rotate and ranges::rotate_copy #1073
Conversation
Urgh, from all the algorithms where I would not want to reduce an ICE out from rotate is high in the list |
I've got this fixed, just typing up a commit message. |
* Unqualify calls to `_Reverse_common`, which cannot be confused with a `_Meow_unchecked` function in `_STD`. * In `_Rotate_unchecked`: * Name the iterator value that's equal to the sentinel `_Final` instead of `_End` which has become conventional. * Avoid making an extra traversal ahead-of-time to find the final iterator of non-bidi ranges. * When we do need to find the final iterator value, start any traversal at `_Mid` instead of `_First`. * Let's not overload "sentinel" - which has enough meanings in Ranges - for `_Reverse_until_sentinel_unchecked`. * Don't test `constexpr rotate` at all with MSVC: it's extremely sensitive to VSO-938163. * Remove unnecessary bug workarounds from the `rotate_copy` test.
Correction: I had this fixed, and somehow managed to break it again while typing a commit message. |
This comment has been minimized.
This comment has been minimized.
This comment has been minimized.
This comment has been minimized.
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.
good to me! Looks
"That's obviously a rotate." -- Sean Parent |
I have been rotating to implement these algorithms but ended up with an ICE in my hand.