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

Add sort for NTuples, make it extensible by packages, and make DefaultStable and DefaultUnstable dispatchable #54494

Open
wants to merge 4 commits into
base: master
Choose a base branch
from

Conversation

LilithHafner
Copy link
Member

Fixes #54489

This is partially a reland of #46104, but without the controversial sort(x) = sort!(copymutable(x)) and with some extensibility improvements.

…ble and DefaultUnstable dispatchable, and add tests
@LilithHafner LilithHafner added domain:sorting Put things in order kind:re-land This relands a PR that was previously merged but was later reverted. labels May 16, 2024
@LilithHafner LilithHafner changed the title Add sort for NTuples, make it extensible by packages, make DefaultStable and DefaultUnstable dispatchable, and add tests Add sort for NTuples, make it extensible by packages, and make DefaultStable and DefaultUnstable dispatchable May 16, 2024
base/sort.jl Outdated Show resolved Hide resolved
base/sort.jl Outdated Show resolved Hide resolved
base/sort.jl Outdated Show resolved Hide resolved
Co-authored-by: Lars Göttgens <lars.goettgens@rwth-aachen.de>
base/sort.jl Outdated Show resolved Hide resolved
@KristofferC
Copy link
Sponsor Member

What does the "make it extensible by packages" part mean?

@LilithHafner
Copy link
Member Author

One can specialize on the alg keyword argument and on the eltype of the NTuple with this implementation.

With the last implementation one could only specialize on eltype of the NTuple.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
domain:sorting Put things in order kind:re-land This relands a PR that was previously merged but was later reverted.
Projects
None yet
Development

Successfully merging this pull request may close these issues.

Feature request: Non allocating sort for tuple
4 participants