This is an example of documentation generated by ZigDoc, an alternative to Zig's built-in Auto Doc feature. See also examples in other modes/formats. The project being documented here (as the example) is the Zig standard library. Public Function
Sorts a slice in-place using an unstable algorithm (does not preserve relative order of equal elements). Time complexity: O(n) best case, O(n log n) worst case and average case. Generally faster than stable sort but order of equal elements is undefined.
Uses pattern-defeating quicksort (PDQ) algorithm which performs well on many data patterns. For stable sorting that preserves equal element order, use sort.
Sorts a slice in-place using an unstable algorithm (does not preserve relative order of equal elements). Time complexity: O(n) best case, O(n log n) worst case and average case. Generally faster than stable sort but order of equal elements is undefined.
Uses pattern-defeating quicksort (PDQ) algorithm which performs well on many data patterns. For stable sorting that preserves equal element order, use
sort.