macro_rules! warnf_if {
($condition:expr, $($args:expr),* $(,)?) => { ... };
}Expand description
Emit a warn level log message using printf format string semantics if condition is true.
use log_if::warnf_if;
const LOG_FACTS: bool = true;
warnf_if!(
LOG_FACTS,
"Log Fact: Made from a log, an %d year old dugout canoe is the oldest discovered boat in %s.",
8000, "Africa");