macro_rules! ensure {
($check:expr, $msg:literal $(,)?) => { ... };
($check:expr, $($arg:tt)+) => { ... };
}Expand description
Return early with an AssertionError if a condition is not satisfied.
This macro is equivalent to assert!, but returns a Problem instead
of panicking.