devela::_dep::const_str

Macro equal

macro_rules! equal {
    ($lhs: expr, $rhs: expr) => { ... };
}
Available on crate feature dep_const_str only.
Expand description

Checks that two strings are equal.

ยงExamples

const A: &str = "hello";
const B: &str = "world";
const C: &str = "hello";
const EQ_AB: bool = const_str::equal!(A, B);
const EQ_AC: bool = const_str::equal!(A, C);
assert_eq!([EQ_AB, EQ_AC], [false, true]);