[][src]Macro chek::ne

macro_rules! ne {
    ($left:expr, $right:expr $(,)?) => { ... };
    ($left:expr, $right:expr, $($msg_args:tt)+) => { ... };
}

Panics if the first expression is not strictly not_equal than the second. Requires that the values implement PartialEq and Debug.

Note: is also aliased as chek::not_equal!. A debug-only version is available as chek::debug_ne!.

Optionally may take an additional message to display on failure, which is formatted using standard format syntax.

Example

chek::ne!(4, 1);
chek::ne!(
    "bar",
    "foo",
);
chek::ne!(4, 5, "With a message");
chek::ne!(4, 2, "With a formatted message: {}", "oh no");