Skip to content

Conversation

@CaseyCarter
Copy link
Contributor

Implement helper ranges::_Rewrap_subrange to use in ranges::search and ranges::find_end.

Perma-workaround VSO-1141368, a failure in MSVC to properly handle lifetime extension when binding a temporary returned from a non-static member function to a reference in a constexpr context. (This seems to also affect structured bindings which look similar "under the covers".)

Partially addresses #39.

Implement helper `ranges::_Rewrap_subrange` to use in `ranges::search` and `ranges::find_end`.

Perma-workaround VSO-1141368, a failure in MSVC to properly handle lifetime extension when binding a temporary returned from a non-static member function to a reference in a constexpr context. (This seems to also affect structured bindings which look similar "under the covers".)

Partially addresses microsoft#39.
@CaseyCarter CaseyCarter added the cxx20 C++20 feature label Jun 15, 2020
@CaseyCarter CaseyCarter requested a review from a team as a code owner June 15, 2020 02:35
@CaseyCarter CaseyCarter mentioned this pull request Jun 15, 2020
Copy link
Contributor

@miscco miscco left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

One minuscule nit

... with `_STL_INTERNAL_STATIC_ASSERT` when we don't want to pay the throughput cost of constraints.
@StephanTLavavej StephanTLavavej self-assigned this Jun 23, 2020
@StephanTLavavej StephanTLavavej merged commit 3c13998 into microsoft:master Jun 24, 2020
@StephanTLavavej
Copy link
Member

Thanks for implementing this algorithm! Onward to ranges::boyer_moore_search! 😹

@CaseyCarter CaseyCarter deleted the search branch June 24, 2020 13:29
@StephanTLavavej StephanTLavavej added the ranges C++20/23 ranges label Jul 22, 2020
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

cxx20 C++20 feature ranges C++20/23 ranges

Projects

None yet

Development

Successfully merging this pull request may close these issues.

4 participants