Skip to content

subrange get<0> requires a copyable iterator - #2425

Merged
Stephan T. Lavavej (StephanTLavavej) merged 2 commits into
microsoft:mainfrom
CaseyCarter:ha_ha_ha_you_get_me
Jan 22, 2022
Merged

subrange get<0> requires a copyable iterator#2425
Stephan T. Lavavej (StephanTLavavej) merged 2 commits into
microsoft:mainfrom
CaseyCarter:ha_ha_ha_you_get_me

Conversation

@CaseyCarter

Copy link
Copy Markdown
Contributor

per LWG-3589.

Fixes #2399

@CaseyCarter Casey Carter (CaseyCarter) added LWG Library Working Group issue ranges C++20/23 ranges labels Dec 17, 2021
@CaseyCarter
Casey Carter (CaseyCarter) requested a review from a team as a code owner December 17, 2021 05:48

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

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

I sah what you did there

Comment thread stl/inc/xutility Outdated
Comment thread stl/inc/xutility
STATIC_ASSERT(test_tuple<subrange<int*, std::unreachable_sentinel_t, subrange_kind::unsized>>());
} // namespace test_subrange

namespace test_lwg_3589 {

Copy link
Copy Markdown
Contributor Author

Choose a reason for hiding this comment

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

"LWG" is capitalized on 26.

Copy link
Copy Markdown
Member

Choose a reason for hiding this comment

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

I can live with this, no need to reset testing.

STATIC_ASSERT(test_tuple<subrange<int*, std::unreachable_sentinel_t, subrange_kind::unsized>>());
} // namespace test_subrange

namespace test_lwg_3589 {

Copy link
Copy Markdown
Member

Choose a reason for hiding this comment

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

I can live with this, no need to reset testing.

@StephanTLavavej

Copy link
Copy Markdown
Member

I'm mirroring this to the MSVC-internal repo - please notify me if any further changes are pushed.

@StephanTLavavej
Stephan T. Lavavej (StephanTLavavej) merged commit 94bb6d2 into microsoft:main Jan 22, 2022
@StephanTLavavej

Copy link
Copy Markdown
Member

Thanks for implementing this LWG issue resolution! ✅ 🚀 🎉

@CaseyCarter
Casey Carter (CaseyCarter) deleted the ha_ha_ha_you_get_me branch August 21, 2024 16:49
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

LWG Library Working Group issue ranges C++20/23 ranges

Projects

None yet

Development

Successfully merging this pull request may close these issues.

LWG-3589 The const lvalue reference overload of get for subrange does not constrain I to be copyable when N == 0

4 participants