diff --git a/src/cook/tree.rs b/src/cook/tree.rs index b1a6a82b34..4832c2d0fc 100644 --- a/src/cook/tree.rs +++ b/src/cook/tree.rs @@ -16,6 +16,7 @@ pub enum WalkTreeEntry<'a> { Missing, } +#[allow(clippy::too_many_arguments)] // params are independent display options pub fn display_tree_entry( package_name: &PackageName, recipe_map: &HashMap<&PackageName, &CookRecipe>, @@ -39,6 +40,7 @@ pub fn display_tree_entry( ) } +#[allow(clippy::too_many_arguments)] // params are independent traversal options pub fn walk_tree_entry( package_name: &PackageName, recipe_map: &HashMap<&PackageName, &CookRecipe>, diff --git a/src/recipe.rs b/src/recipe.rs index 9bc2cf371b..3850d5e367 100644 --- a/src/recipe.rs +++ b/src/recipe.rs @@ -275,6 +275,7 @@ impl CookRecipe { Self::new(name, dir.to_path_buf(), recipe) } + #[allow(clippy::too_many_arguments)] // params are independent recursion flags fn new_recursive( names: &[PackageName], recurse_build_deps: bool, diff --git a/src/staged_pkg.rs b/src/staged_pkg.rs index db5943d431..00eac51fdb 100644 --- a/src/staged_pkg.rs +++ b/src/staged_pkg.rs @@ -97,9 +97,7 @@ pub fn new_recursive( return Ok(vec![]); } let (list, map) = new_recursive_nonstop(names, recursion); - if nonstop && !list.is_empty() { - Ok(list) - } else if !nonstop && map.len() == list.len() { + if (nonstop && !list.is_empty()) || (!nonstop && map.len() == list.len()) { Ok(list) } else { let (_, res) = map.into_iter().find(|(_, v)| v.is_err()).unwrap();