fix: Don't assert paths being utf8 when filtering them in the watcher

This commit is contained in:
Lukas Wirth 2024-03-22 08:04:50 +01:00
parent fe28e470cd
commit ea447062c4
3 changed files with 14 additions and 8 deletions

View file

@ -406,7 +406,7 @@ impl CargoWorkspace {
pub fn target_by_root(&self, root: &AbsPath) -> Option<Target> {
self.packages()
.filter(|&pkg| self[pkg].is_member)
.find_map(|pkg| self[pkg].targets.iter().find(|&&it| &self[it].root == root))
.find_map(|pkg| self[pkg].targets.iter().find(|&&it| self[it].root == root))
.copied()
}