Skip to content
This repository has been archived by the owner on May 28, 2024. It is now read-only.

Clean up the quicksort API #11

Closed
SimonSapin opened this issue Feb 24, 2015 · 0 comments
Closed

Clean up the quicksort API #11

SimonSapin opened this issue Feb 24, 2015 · 0 comments
Labels

Comments

@SimonSapin
Copy link
Member

  • Change quicksort_by to take a closure (this should work now that they’re unboxed) instead of an fn
  • Add a quicksort function:
#[inline]
fn quicksort<T>(arr: &mut [T]) where T: Ord {
    quicksort_by(arr, |a, b| a.cmp(b))
}
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
Projects
None yet
Development

No branches or pull requests

1 participant