Wrap the parameter sets in parenthesis.

This commit is contained in:
Tom Alexander
2023-10-06 16:19:43 -04:00
parent c7dbe596b3
commit 368c6a457e
3 changed files with 48 additions and 12 deletions

View File

@@ -1,6 +1,18 @@
macro_rules! compare_noop {
($($field:expr),+) => {
$(
EmacsField::Required(":foo"),
compare_identity,
impl_compare_noop
),+
};
}
pub(crate) use compare_noop;
/// Create iterators for ast nodes where it only has to iterate over children
macro_rules! compare_properties {
($emacs:expr, $rust:expr, $($emacs_field:expr, $rust_value_getter:expr, $compare_fn: ident),+) => {
($emacs:expr, $rust:expr, $(($emacs_field:expr, $rust_value_getter:expr, $compare_fn: expr)),+) => {
{
let mut this_status = DiffStatus::Good;
let mut message: Option<String> = None;
@@ -36,7 +48,7 @@ macro_rules! compare_properties {
},
EmacsField::Optional(_name) => {},
}
),+
)+
if !emacs_keys.is_empty() {
let unexpected_keys: Vec<&str> = emacs_keys.into_iter().collect();
@@ -66,7 +78,7 @@ macro_rules! compare_properties {
},
_ => {}
}
),+
)+
match this_status {
DiffStatus::Good => {