#[macro_export] macro_rules! danger_trace { // trace!(target: "my_target", key1 = 42, key2 = true; "a {} event", "log") // trace!(target: "my_target", "a {} event", "log") (target: $target:expr, $($arg:tt)+) => { if std::env::var("E3PF_SUPER_DANGEROUS_VERY_VERBOSE_DEBUGGING_LOGGING") == Ok("enabled".to_string()) && cfg!(debug_assertions) { log::trace!(target: $target, $($arg)+) } }; // trace!("a {} event", "log") ($($arg:tt)+) => { if std::env::var("E3PF_SUPER_DANGEROUS_VERY_VERBOSE_DEBUGGING_LOGGING") == Ok("enabled".to_string()) && cfg!(debug_assertions) { log::trace!($($arg)+) } } }