# std: add sort method to ArrayHashMap and MultiArrayList · gitcafe/zig

[View on GitCafe](https://git.cafe/gitcafe/zig/commit/6e49ba77f3001fe04d4b2177a5c37d28bd422758)

Repository: [gitcafe/zig](https://git.cafe/gitcafe/zig)

Visibility: public

Requested revision: 6e49ba77f3001fe04d4b2177a5c37d28bd422758

Requested commit: 6e49ba77f3001fe04d4b2177a5c37d28bd422758

Commit: 6e49ba77f3001fe04d4b2177a5c37d28bd422758

Tree: cfd55e3566fbf651e339529ff03693c75484907b

Author: Andrew Kelley

Committer: Andrew Kelley

## Message

```
std: add sort method to ArrayHashMap and MultiArrayList

This also adds `std.sort.sortContext` and
`std.sort.insertionSortContext` which are more advanced methods that
allow overriding the `swap` method. The former calls the latter for now
because reworking the main sort implementation is a big task that can be
done later without any changes to the API.

```

## Parents

- [f736cde397a6abb1399827ed5988c43001706580](https://git.cafe/gitcafe/zig/commit/f736cde397a6abb1399827ed5988c43001706580?format=markdown)

[Source at this commit](https://git.cafe/gitcafe/zig/tree/6e49ba77f3001fe04d4b2177a5c37d28bd422758?format=markdown)
