-
Notifications
You must be signed in to change notification settings - Fork 70
Explicitly document sort stability #158
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
Explicitly document sort stability #158
Conversation
As not all users of this library might be aware of the affact that Array.prototype.sort() can be stable or unstable depending on the actual JavaScript runtime being used (and potentially the length of the array), let's explicitly document this to avoid people from getting tripped up.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Looks good. We'll need to remember to remove these after we do #155.
I think this is unnecessary now given this? : |
Thanks for the link! I think we should document sort’s stability either way (whether it’s stable or not). #155 is likely going to be in the next release anyway though. |
Does #155 still need to be implemented? Or will merging this suffice due to the changes made to sort stability since this was made? |
With #195 it's unclear to me whether this is still relevant. Should this be closed? |
If the new |
This should now be closed as the stability of sort no longer depends on your JS runtime. However, we should still document the stability of our sort, whether it is stable or not. I’m not sure if the new sort algorithm is stable - we should verify this, and if it is, we should document this and add tests for stability (so that we don’t accidentally lose stability later). |
I opened #196 to track the sort stability stuff. |
As not all users of this library might be aware of the affact that
Array.prototype.sort() can be stable or unstable depending on the actual
JavaScript runtime being used (and potentially the length of the array),
let's explicitly document this to avoid people from getting tripped up.