in guppy/src/graph/cargo/build.rs [310:335]
fn new_v1_intermediate<'g>(
&self,
query: FeatureQuery<'g>,
avoid_dev_deps: bool,
) -> CargoIntermediateSet<'g> {
// Perform a "complete" feature query. This will provide more packages than will be
// included in the final build, but for each package it will have the correct feature set.
let complete_set = query.resolve_with_fn(|query, link| {
if self.is_omitted(link.to().package_ix()) {
// Pretend that the omitted set doesn't exist.
false
} else if !avoid_dev_deps
&& query
.starts_from(link.from().feature_id())
.expect("valid ID")
{
// Follow everything for initials.
true
} else {
// Follow normal and build edges for everything else.
!link.dev_only()
}
});
CargoIntermediateSet::Unified(complete_set)
}