Skip to content

P2562R1: constexpr Stable Sorting #105360

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

Closed
ldionne opened this issue Aug 20, 2024 · 4 comments · Fixed by #132075
Closed

P2562R1: constexpr Stable Sorting #105360

ldionne opened this issue Aug 20, 2024 · 4 comments · Fixed by #132075
Labels
c++26 libc++ libc++ C++ Standard Library. Not GNU libstdc++. Not libc++abi. wg21 paper Issues representing the implementation of a WG21 paper

Comments

@ldionne
Copy link
Member

ldionne commented Aug 20, 2024

Link: https://wg21.link/P2562R1

@ldionne ldionne added c++26 libc++ libc++ C++ Standard Library. Not GNU libstdc++. Not libc++abi. wg21 paper Issues representing the implementation of a WG21 paper labels Aug 20, 2024
@PaulXiCao
Copy link
Contributor

This paper consists of multiple parts. I will work on them sequentially in separate mrs.

  • constexpr std::stable_sort: [libc++][C++26] P2562R1: constexpr Stable Sorting #110320
  • constexpr std::ranges::stable_sort
  • constexpr std::stable_partition
  • constexpr std::ranges::stable_partition
  • constexpr std::inplace_merge
  • constexpr std::ranges::inplace_merge
  • bump __cpp_lib_constexpr_algorithms

@ldionne
Copy link
Member Author

ldionne commented Dec 10, 2024

I tried using the new "sub issues" feature to create tracking issues for those.

ldionne added a commit that referenced this issue Jan 14, 2025
Implementing `constexpr std::stable_sort`. This is part of P2562R1,
tracked via issue #105360.

Closes #119394

Co-authored-by: A. Jiang <[email protected]>
Co-authored-by: Louis Dionne <[email protected]>
philnik777 pushed a commit that referenced this issue Feb 6, 2025
…nch (#125284)

`std::stable_sort` is `constexpr` since PR
#110320
But `radix_sort` branch is still non-`constexpr`.
This PR fixes it.

#119394
#105360
Icohedron pushed a commit to Icohedron/llvm-project that referenced this issue Feb 11, 2025
…nch (llvm#125284)

`std::stable_sort` is `constexpr` since PR
llvm#110320
But `radix_sort` branch is still non-`constexpr`.
This PR fixes it.

llvm#119394
llvm#105360
@ldionne ldionne moved this from Todo to Partial in libc++ Standards Conformance Feb 17, 2025
@frederick-vs-ja
Copy link
Contributor

I wonder whether we should switch back to use placement new one day (currently std::__construct_at is sometimes used for GCC compatibility).

@mordante
Copy link
Member

Personally I feel std::__construct_at is more readable than placement new. So I rather not switch back to placement new.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
c++26 libc++ libc++ C++ Standard Library. Not GNU libstdc++. Not libc++abi. wg21 paper Issues representing the implementation of a WG21 paper
Projects
Status: Done
Development

Successfully merging a pull request may close this issue.

4 participants