Skip to main content

diff_sets

Function diff_sets 

Source
pub fn diff_sets(old: &[Package], new: &[Package]) -> DiffReport
Expand description

Compares two sets of resolved packages, matching by package name, and interface numbers within each unit ([walk::Matching]). A package present only on the new side is a Category::DeclAdded; matched packages are walked pairwise. A package present only on the old side is a Category::DeclRemoved when its whole unit is gone from the new side, and is walked declaration by declaration when the unit is still there, so that an interface whose number moved to another package of the unit is Category::InterfaceRenamed and one the unit retired is Category::InterfaceRetired.

diff_sets_in with no context: a type from a package outside new, such as ridl.std, which no snapshot carries, does not resolve, and a type the diff cannot resolve is reported as breaking.