Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

feat: merge dependencies for better error messages #163

Merged
merged 8 commits into from
Dec 17, 2023
Prev Previous commit
Typo mergeed -> merged
  • Loading branch information
mpizenberg committed Dec 15, 2023
commit 5c4a6b92e736ebc044cc53fb5a407dfa68ca0b0f
4 changes: 2 additions & 2 deletions src/internal/core.rs
Original file line number Diff line number Diff line change
Expand Up @@ -246,12 +246,12 @@ impl<P: Package, VS: VersionSet, Priority: Ord + Clone> State<P, VS, Priority> {
.merged_dependencies
.entry((p1.clone(), p2.clone()))
.or_default();
if let Some((past, mergeed)) = deps_lookup.as_mut_slice().iter_mut().find_map(|past| {
if let Some((past, merged)) = deps_lookup.as_mut_slice().iter_mut().find_map(|past| {
self.incompatibility_store[id]
.merge_dependents(&self.incompatibility_store[*past])
.map(|m| (past, m))
}) {
let new = self.incompatibility_store.alloc(mergeed);
let new = self.incompatibility_store.alloc(merged);
for (pkg, _) in self.incompatibility_store[new].iter() {
self.incompatibilities
.entry(pkg.clone())
Expand Down