mirror of
https://gitee.com/openharmony/third_party_rust_bindgen
synced 2024-12-04 05:22:20 +00:00
0296f9e86c
remove `clap` dependency 🎉
update the book installation instructions
33 lines
1.0 KiB
Rust
33 lines
1.0 KiB
Rust
#![allow(unused)]
|
|
|
|
macro_rules! log {
|
|
(target: $target:expr, $lvl:expr, $($arg:tt)+) => {{
|
|
let _ = $target;
|
|
let _ = log!($lvl, $($arg)+);
|
|
}};
|
|
($lvl:expr, $($arg:tt)+) => {{
|
|
let _ = $lvl;
|
|
let _ = format_args!($($arg)+);
|
|
}};
|
|
}
|
|
macro_rules! error {
|
|
(target: $target:expr, $($arg:tt)+) => { log!(target: $target, "", $($arg)+) };
|
|
($($arg:tt)+) => { log!("", $($arg)+) };
|
|
}
|
|
macro_rules! warn {
|
|
(target: $target:expr, $($arg:tt)*) => { log!(target: $target, "", $($arg)*) };
|
|
($($arg:tt)*) => { log!("", $($arg)*) };
|
|
}
|
|
macro_rules! info {
|
|
(target: $target:expr, $($arg:tt)+) => { log!(target: $target, "", $($arg)+) };
|
|
($($arg:tt)+) => { log!("", $($arg)+) };
|
|
}
|
|
macro_rules! debug {
|
|
(target: $target:expr, $($arg:tt)+) => { log!(target: $target, "", $($arg)+) };
|
|
($($arg:tt)+) => { log!("", $($arg)+) };
|
|
}
|
|
macro_rules! trace {
|
|
(target: $target:expr, $($arg:tt)+) => { log!(target: $target, "", $($arg)+) };
|
|
($($arg:tt)+) => { log!("", $($arg)+) };
|
|
}
|