B:BD[
2.425] → [
2.425:458]
println!("{:?}", conflicts);
if conflicts.is_empty() {
return;
}
println!("");
println!("Conflicts");
for c in &conflicts {
let conflict_type = conflict_type(c);
let path = conflict_path(c);
println!(" {} {}", conflict_type, path);
}
}
use libpijul::Conflict;
fn conflict_type(conflict: &Conflict) -> &'static str {
match conflict {
Conflict::Name { .. } => "name",
Conflict::Order { .. } => "order",
_ => unimplemented!()
}
}
fn conflict_path(conflict: &Conflict) -> &str {
match conflict {
Conflict::Name { path, .. } => path,
Conflict::Order { path, .. } => path,
_ => unimplemented!()
}