mirror of
https://github.com/RGBCube/uutils-coreutils
synced 2025-07-28 19:47:45 +00:00
coreopts: fix error when using msg_wrong_number_of_arguments
macro
This commit is contained in:
parent
23979542af
commit
163a3a2540
1 changed files with 9 additions and 3 deletions
|
@ -322,15 +322,21 @@ macro_rules! msg_arg_invalid_value { ($expects:expr, $received:expr) => (
|
|||
msg_invalid_input!(format!("expects its argument to be {}, but was provided {}", $expects, $received)) ); }
|
||||
|
||||
#[macro_export]
|
||||
macro_rules! msg_args_invalid_value { ($expects:expr, $received:expr) => (
|
||||
msg_invalid_input!(format!("expects its arguments to be {}, but was provided {}", $expects, $received)) ); }
|
||||
macro_rules! msg_args_invalid_value {
|
||||
($expects:expr, $received:expr) => (
|
||||
msg_invalid_input!(format!("expects its arguments to be {}, but was provided {}", $expects, $received))
|
||||
);
|
||||
($msg:expr) => (
|
||||
msg_invalid_input!($msg)
|
||||
);
|
||||
}
|
||||
|
||||
#[macro_export]
|
||||
macro_rules! msg_args_nonexistent_file { ($received:expr) => (
|
||||
msg_args_invalid_value!("paths to files", snippet_no_file_at_path!($received)));}
|
||||
|
||||
#[macro_export]
|
||||
macro_rules! msg_wrong_number_of_arguments { ($received:expr) => (
|
||||
macro_rules! msg_wrong_number_of_arguments { () => (
|
||||
msg_args_invalid_value!("wrong number of arguments") ); }
|
||||
|
||||
// -- message templates : invalid input : input combinations
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue