Function contract_check_ensures

const fn contract_check_ensures<C: Fn(&Ret) -> bool + Copy, Ret>(cond: Option<C>, ret: Ret) -> Ret

Check if the post-condition cond has been met.

By default, if contract_checks is enabled, this will panic with no unwind if the condition returns false.

If cond is None, then no postcondition checking is performed.

Note that this function is a no-op during constant evaluation.