diff --git a/examples/caching_dependency_provider.rs b/examples/caching_dependency_provider.rs index 84ea6daf..67270433 100644 --- a/examples/caching_dependency_provider.rs +++ b/examples/caching_dependency_provider.rs @@ -66,7 +66,7 @@ impl> DependencyProvider for CachingDependenc ranges: &DP::VS, stats: &PackageResolutionStatistics, ) -> Self::Priority { - self.remote_dependencies.prioritize(package, ranges, statis) + self.remote_dependencies.prioritize(package, ranges, stats) } type Err = DP::Err; diff --git a/src/lib.rs b/src/lib.rs index 266cd4d5..bce5654e 100644 --- a/src/lib.rs +++ b/src/lib.rs @@ -87,7 +87,7 @@ //! } //! //! type Priority = usize; -//! fn prioritize(&self, package: &String, range: &SemVS, statis: &PackageResolutionStatistics) -> Self::Priority { +//! fn prioritize(&self, package: &String, range: &SemVS, stats: &PackageResolutionStatistics) -> Self::Priority { //! unimplemented!() //! } //! diff --git a/src/provider.rs b/src/provider.rs index c07d343c..0dfad1a3 100644 --- a/src/provider.rs +++ b/src/provider.rs @@ -102,7 +102,7 @@ impl DependencyProvider for OfflineDependencyProvide &self, package: &P, range: &VS, - statis: &PackageResolutionStatistics, + stats: &PackageResolutionStatistics, ) -> Self::Priority { let version_count = self .dependencies @@ -112,7 +112,7 @@ impl DependencyProvider for OfflineDependencyProvide if version_count == 0 { return (u32::MAX, Reverse(0)); } - (statis.conflict_count(), Reverse(version_count as u32)) + (stats.conflict_count(), Reverse(version_count as u32)) } #[inline] diff --git a/src/solver.rs b/src/solver.rs index 88126b9e..3e0e102a 100644 --- a/src/solver.rs +++ b/src/solver.rs @@ -97,8 +97,8 @@ pub fn resolve( let Some(highest_priority_pkg) = state.partial_solution.pick_highest_priority_pkg(|p, r| { - let statis = PackageResolutionStatistics::new(p, &state.conflict_count); - dependency_provider.prioritize(&state.package_store[p], r, &statis) + let stats = PackageResolutionStatistics::new(p, &state.conflict_count); + dependency_provider.prioritize(&state.package_store[p], r, &stats) }) else { return Ok(state @@ -299,7 +299,7 @@ pub trait DependencyProvider { &self, package: &Self::P, range: &Self::VS, - statis: &PackageResolutionStatistics, + stats: &PackageResolutionStatistics, ) -> Self::Priority; /// The type returned from `prioritize`. The resolver does not care what type this is /// as long as it can pick a largest one and clone it. diff --git a/tests/proptest.rs b/tests/proptest.rs index c8357d1e..89e88cef 100644 --- a/tests/proptest.rs +++ b/tests/proptest.rs @@ -53,9 +53,9 @@ impl DependencyProvider for OldestVersionsDependency &self, package: &P, range: &VS, - statis: &PackageResolutionStatistics, + stats: &PackageResolutionStatistics, ) -> Self::Priority { - self.0.prioritize(package, range, statis) + self.0.prioritize(package, range, stats) } type Err = Infallible; @@ -113,9 +113,9 @@ impl DependencyProvider for TimeoutDependencyProvider Self::Priority { - self.dp.prioritize(package, range, statis) + self.dp.prioritize(package, range, stats) } type Err = DP::Err;