Crate const_cmp[][src]

For comparing strings and slices at compile-time.

Modules

nonzero
other
polymorphism
primitive
range
slice

Functions for comparing slices

Macros

coerce_to_cmp

Coerces reference to a type that has a cosnt_eq method.

const_cmp
const_cmp_for

Compares two slices for ordering, evaluating to a cmp::Ordering

const_eq
const_eq_for

Compares two generic standard library types for equality.

impl_cmp
try_equal

Evaluates to $ord if it is Ordering::Equal, otherwise returns it from the enclosing function.

Functions

cmp_option_str

Compares two Option<&'a str>, returning the ordering of left relative to right.

cmp_str

A const equivalent of str::cmp.

eq_option_str

Compares two Option<&'a str> for equality.

eq_str

A const equivalent of &str equality comparison.