Skip to content

Commit

Permalink
tests: Remove needless allocations
Browse files Browse the repository at this point in the history
  • Loading branch information
taiki-e committed Apr 17, 2024
1 parent 1a1fad8 commit 26e4547
Showing 1 changed file with 2 additions and 2 deletions.
4 changes: 2 additions & 2 deletions src/features.rs
Original file line number Diff line number Diff line change
Expand Up @@ -333,13 +333,13 @@ mod tests {

macro_rules! map {
($(($key:expr, $value:expr)),* $(,)?) => {
BTreeMap::from_iter(vec![$(($key.into(), $value)),*])
BTreeMap::from_iter([$(($key.into(), $value)),*])
};
}

macro_rules! set {
($($expr:expr),* $(,)?) => {
BTreeSet::from_iter(vec![$($expr),*])
BTreeSet::from_iter([$($expr),*])
};
}

Expand Down

0 comments on commit 26e4547

Please sign in to comment.