[][src]Macro tari_common::log_if_error_fmt

macro_rules! log_if_error_fmt {
    (level: $level:tt, target: $target:expr, $msg:expr, $expr:expr, $($args:tt)+) => { ... };
}

See log_if_error!.

This code runs with edition 2018
let opt = log_if_error_fmt!(level: debug, target: "docs", "Error sending reply - custom: {}", Result::<(), _>::Err(()), "this is logged");
assert_eq!(opt, None);