2020-12-23 00:34:46 +00:00
|
|
|
#![allow(unused)]
|
|
|
|
|
2016-11-15 22:27:13 +00:00
|
|
|
macro_rules! log {
|
2021-10-26 09:34:51 +00:00
|
|
|
(target: $target:expr, $lvl:expr, $($arg:tt)+) => {{
|
2016-11-15 22:27:13 +00:00
|
|
|
let _ = $target;
|
|
|
|
let _ = log!($lvl, $($arg)+);
|
2021-10-26 09:34:51 +00:00
|
|
|
}};
|
|
|
|
($lvl:expr, $($arg:tt)+) => {{
|
2016-11-15 22:27:13 +00:00
|
|
|
let _ = $lvl;
|
|
|
|
let _ = format_args!($($arg)+);
|
2021-10-26 09:34:51 +00:00
|
|
|
}};
|
2016-11-15 22:27:13 +00:00
|
|
|
}
|
|
|
|
macro_rules! error {
|
2021-10-26 09:34:51 +00:00
|
|
|
(target: $target:expr, $($arg:tt)+) => { log!(target: $target, "", $($arg)+) };
|
|
|
|
($($arg:tt)+) => { log!("", $($arg)+) };
|
2016-11-15 22:27:13 +00:00
|
|
|
}
|
|
|
|
macro_rules! warn {
|
2021-10-26 09:34:51 +00:00
|
|
|
(target: $target:expr, $($arg:tt)*) => { log!(target: $target, "", $($arg)*) };
|
|
|
|
($($arg:tt)*) => { log!("", $($arg)*) };
|
2016-11-15 22:27:13 +00:00
|
|
|
}
|
|
|
|
macro_rules! info {
|
2021-10-26 09:34:51 +00:00
|
|
|
(target: $target:expr, $($arg:tt)+) => { log!(target: $target, "", $($arg)+) };
|
|
|
|
($($arg:tt)+) => { log!("", $($arg)+) };
|
2016-11-15 22:27:13 +00:00
|
|
|
}
|
|
|
|
macro_rules! debug {
|
2021-10-26 09:34:51 +00:00
|
|
|
(target: $target:expr, $($arg:tt)+) => { log!(target: $target, "", $($arg)+) };
|
|
|
|
($($arg:tt)+) => { log!("", $($arg)+) };
|
2016-11-15 22:27:13 +00:00
|
|
|
}
|
|
|
|
macro_rules! trace {
|
2021-10-26 09:34:51 +00:00
|
|
|
(target: $target:expr, $($arg:tt)+) => { log!(target: $target, "", $($arg)+) };
|
|
|
|
($($arg:tt)+) => { log!("", $($arg)+) };
|
2016-11-15 22:27:13 +00:00
|
|
|
}
|