16 lines
383 B
Rust
16 lines
383 B
Rust
// progress, on stderr and only when it was asked for
|
|
macro_rules! note {
|
|
($ctx:expr, $($arg:tt)*) => {
|
|
if !$ctx.quiet {
|
|
eprintln!($($arg)*)
|
|
}
|
|
};
|
|
}
|
|
|
|
// not progress: it speaks about the result, so --quiet keeps it
|
|
macro_rules! warning {
|
|
($($arg:tt)*) => { eprintln!("warning: {}", format_args!($($arg)*)) };
|
|
}
|
|
|
|
pub(crate) use {note, warning};
|