Macro frame_support::ensure[][src]

macro_rules! ensure {
    ( $x:expr, $y:expr $(,)? ) => { ... };
}

Evaluate $x:expr and if not true return Err($y:expr).

Used as ensure!(expression_to_ensure, expression_to_return_on_false).