Skip to content
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

<mdspan>: Construct mappings from extents_type rvalues when necessary #4236

Merged
merged 1 commit into from
Dec 7, 2023

Conversation

StephanTLavavej
Copy link
Member

WG21-N4964 [mdspan.mdspan.cons]/10.2:

direct-non-list-initializes map_ with extents_type(exts)

We were correctly passing extents_type rvalues up to the _Mdspan_mapping_base layer, but that was incorrectly always copying.

Test coverage will be provided by std/containers/views/mdspan/mdspan/ctor.dh_span.pass.cpp in the upcoming libcxx update that I'm working on.

… rvalue when necessary.

N4964 [mdspan.mdspan.cons]/10.2 "direct-non-list-initializes map_ with extents_type(exts)"

Found by libcxx std/containers/views/mdspan/mdspan/ctor.dh_span.pass.cpp.
@StephanTLavavej StephanTLavavej added bug Something isn't working mdspan C++23 mdspan labels Dec 4, 2023
@StephanTLavavej StephanTLavavej requested a review from a team as a code owner December 4, 2023 22:29
@StephanTLavavej StephanTLavavej self-assigned this Dec 7, 2023
@StephanTLavavej
Copy link
Member Author

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

@StephanTLavavej StephanTLavavej merged commit b351b67 into microsoft:main Dec 7, 2023
37 checks passed
@StephanTLavavej StephanTLavavej deleted the mdspan-mapping branch December 7, 2023 16:49
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
bug Something isn't working mdspan C++23 mdspan
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants