Skip to content

Add strided_slice updates with integral_constant_like support (P3663 piece 2 of N)#450

Merged
crtrott merged 5 commits intostablefrom
copilot/add-strided-slice-updates
Feb 23, 2026
Merged

Add strided_slice updates with integral_constant_like support (P3663 piece 2 of N)#450
crtrott merged 5 commits intostablefrom
copilot/add-strided-slice-updates

Conversation

Copy link
Copy Markdown
Contributor

Copilot AI commented Feb 20, 2026

  • Explore codebase and understand PR Implement P3663 (Future-proof submdspan_mapping) #408 changes needed
  • Add remove_cvref_t content to __p0009_bits/utility.hpp (instead of new header)
  • Create __p2630_bits/integral_constant_like.hpp with equality_comparable backport + integral_constant_like content
  • Update __p2630_bits/strided_slice.hpp with new type checks using is_integral_constant_like_v
  • Add tests/test_strided_slice.cpp
  • Update tests/CMakeLists.txt to include the new test
  • Build and verify: all tests pass (C++17 with/without P3663, C++20)
  • Address review: remove #if defined(MDSPAN_IMPL_ENABLE_P3663) guards from test (test is now unconditional)
  • Address review: remove the operator() block and its comment from my_integral_constant

💡 You can make Copilot smarter by setting up custom instructions, customizing its development environment and configuring Model Context Protocol (MCP) servers. Learn more Copilot coding agent tips in the docs.

Co-authored-by: crtrott <9490481+crtrott@users.noreply.github.com>
Copilot AI changed the title [WIP] Add changes to strided_slice definition and headers Add strided_slice updates with integral_constant_like support (P3663 piece 2 of N) Feb 20, 2026
Copilot AI requested a review from crtrott February 20, 2026 20:05
@crtrott crtrott marked this pull request as ready for review February 20, 2026 20:08
Copy link
Copy Markdown
Contributor

@mhoemmen mhoemmen left a comment

Choose a reason for hiding this comment

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

Thanks!

template<class OffsetType, class ExtentType, class StrideType>
void test_strided_slice(OffsetType offset, ExtentType extent, StrideType stride)
{
// Some compilers are bad at CTAD for aggregates.
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.

It would be nice if this worked! It's just that Clang is somehow bad at this.

Co-authored-by: Mark Hoemmen <mhoemmen@users.noreply.github.com>
Copy link
Copy Markdown
Member

@crtrott crtrott left a comment

Choose a reason for hiding this comment

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

The test can be unconditional. Nothing is protected by that macro.

…_strided_slice

Co-authored-by: crtrott <9490481+crtrott@users.noreply.github.com>
Copilot AI requested a review from crtrott February 20, 2026 21:15
@crtrott crtrott merged commit 80fc772 into stable Feb 23, 2026
30 checks passed
@crtrott crtrott deleted the copilot/add-strided-slice-updates branch February 23, 2026 20:18
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

3 participants