nif_sorter

CircleCI

NIF faster sort typed list of strings/integers/floats (with C++ std::sort)

Installation

Add to deps in mix.exs:

{:nif_sorter, "~> 0.2.2"}

Works on Elixir 1.7+

Usage

NifSorter.sort(["xir", "i", "el"])
# ["el", "i", "xir"]
NifSorter.sort([2, 3, 1])
# [1, 2, 3]
NifSorter.sort([2.31, 2.07, 1.2, -10.4])
# [-10.4, 1.2, 2.07, 2.31]

NifSorter.sort([1, 2.2])
# (ArgumentError) argument error

Restrictions

Performance

Commands