[libcxx] [llvm] [libc++] Implement P2442R1 `std::views::chunk` (PR #171234)
Hristo Hristov via llvm-commits
llvm-commits at lists.llvm.org
Tue Dec 9 09:13:46 PST 2025
H-G-Hristov wrote:
> > Thanks! I've merely made quick style checks as for now.
>
> @frederick-vs-ja Thank you very much for your code review! I've applied all your suggestions in the recent new-pushed-commits.
>
> This is my first time contributing to libc++, if there is still anything wrong on my code, please point it out! :)
>
> > Thank you for working on this. This is just a quick review.
> > Please follow the guidelines: https://libcxx.llvm.org/Contributing.html#pre-commit-check-list https://libcxx.llvm.org/CodingGuidelines.html
> > Make sure to test `noexcept`, such as: `static_assert(noexcept(it.end()));` and for constness if applicable.
>
> @H-G-Hristov Thank you for you code review too!
>
> * I've adjusted the test files, now they have correct head (synopis for what being tseted, sorted includes, etc.) and correct format (the comment style, one-function-one-test, for example).
>
> * The return-type-check are all restyled into `std::same_as<...> auto`.
>
> * There are still some places I use `auto meow = wolf | std::views::chunk`, I'll adjust it tomorrow.
>
> * `nodiscard` check are all collected in `libcxx/test/libcxx/ranges/range.adaptors/range.chunk/nodiscard.verify.cpp`.
>
> * `noexcept` are also checked.
>
> * There are only 5 places in P2442R1 that explicitly mentioned `noexcept`: `cpo::operator()`, `chunk_view</*excatly_input_range*/>::end() -> std::default_sentinel_t`, `chunk_range</*exactly_input_range*/>::outer_iterator::value_type::begin/end()`, `iter_move` and `iter_swap`.
>
> * Removed `thank you` message from the top comment. Maybe this seems official enough?
>
>
> The CI seems to be all successful on both GCC and Clang, but failed on clang-cl.
>
> It will take me some time to debug the clang-cl CI failure (as I only have Linux and MacOS computers on my hand, and every time waiting for the online CI to produce a clang-cl error log, it needs more than 2 hours).
>
Maybe this is the issue:
https://github.com/llvm/llvm-project/blob/2f3d4c8dff4ba237b168d0e2cf861cb67d589fd7/libcxx/test/libcxx/ranges/range.adaptors/range.move.wrap/no_unique_address.pass.cpp#L11
https://github.com/llvm/llvm-project/pull/171234
More information about the llvm-commits
mailing list