From faa3fe7a9266002b20577da7ed3134733942f8ad Mon Sep 17 00:00:00 2001 From: konstin Date: Mon, 15 Apr 2024 17:55:54 +0200 Subject: [PATCH] Pacify clippy --- src/internal/incompatibility.rs | 1 + src/internal/partial_solution.rs | 4 ++++ src/solver.rs | 1 + 3 files changed, 6 insertions(+) diff --git a/src/internal/incompatibility.rs b/src/internal/incompatibility.rs index 979dde6f..e2a60121 100644 --- a/src/internal/incompatibility.rs +++ b/src/internal/incompatibility.rs @@ -114,6 +114,7 @@ impl Incompatibilit } /// Create an incompatibility for a reason outside pubgrub. + #[allow(dead_code)] // Used by uv pub fn custom_term(package: P, term: Term, metadata: M) -> Self { let set = match &term { Term::Positive(r) => r.clone(), diff --git a/src/internal/partial_solution.rs b/src/internal/partial_solution.rs index b69c2815..3e359413 100644 --- a/src/internal/partial_solution.rs +++ b/src/internal/partial_solution.rs @@ -47,6 +47,7 @@ pub struct PartialSolution { /// 3. `[changed_this_decision_level..]` Containes all packages that **have** had there assignments changed since /// the last time `prioritize` has bean called. The inverse is not necessarily true, some packages in the range /// did not have a change. Within this range there is no sorting. + #[allow(clippy::type_complexity)] package_assignments: FnvIndexMap>, /// `prioritized_potential_packages` is primarily a HashMap from a package with no desition and a positive assignment /// to its `Priority`. But, it also maintains a max heap of packages by `Priority` order. @@ -396,6 +397,7 @@ impl PartialSolution { } /// Figure out if the satisfier and previous satisfier are of different decision levels. + #[allow(clippy::type_complexity)] pub fn satisfier_search<'i>( &self, incompat: &'i Incompatibility, @@ -434,6 +436,7 @@ impl PartialSolution { /// Question: This is possible since we added a "global_index" to every dated_derivation. /// It would be nice if we could get rid of it, but I don't know if then it will be possible /// to return a coherent previous_satisfier_level. + #[allow(clippy::type_complexity)] fn find_satisfier<'i>( incompat: &'i Incompatibility, package_assignments: &FnvIndexMap>, @@ -449,6 +452,7 @@ impl PartialSolution { /// Earliest assignment in the partial solution before satisfier /// such that incompatibility is satisfied by the partial solution up to /// and including that assignment plus satisfier. + #[allow(clippy::type_complexity)] fn find_previous_satisfier<'i>( incompat: &Incompatibility, satisfier_package: &'i DP::P, diff --git a/src/solver.rs b/src/solver.rs index 82febc3f..1c2461c2 100644 --- a/src/solver.rs +++ b/src/solver.rs @@ -265,6 +265,7 @@ pub trait DependencyProvider { /// Retrieves the package dependencies. /// Return [Dependencies::Unknown] if its dependencies are unknown. + #[allow(clippy::type_complexity)] fn get_dependencies( &self, package: &Self::P,