Packages

Elixir implementation of the Cldr Collation algorithm, providing language-aware string sorting and comparison. An opt-in NIF is provided for high performance collating.

Current section

Files

Jump to
ex_cldr_collation lib cased insensitive.ex
Raw

lib/cased/insensitive.ex

defmodule Cldr.Collation.Insensitive do
@moduledoc """
Compare two strings using the UCA
in a case-insensitive manner
"""
@insensitive 1
@dialyzer {:no_return, compare: 2}
def compare(a, b) do
Cldr.Collation.nif_compare(a, b, @insensitive)
end
end