Function cargo::ops::resolve_with_previous

source ยท
pub fn resolve_with_previous<'gctx>(
    registry: &mut PackageRegistry<'gctx>,
    ws: &Workspace<'gctx>,
    cli_features: &CliFeatures,
    has_dev_units: HasDevUnits,
    previous: Option<&Resolve>,
    keep_previous: Option<&'_ dyn Fn(&PackageId) -> bool>,
    specs: &[PackageIdSpec],
    register_patches: bool,
) -> CargoResult<Resolve>
Expand description

Resolves all dependencies for a package using an optional previous instance of resolve to guide the resolution process.

This also takes an optional filter keep_previous, which informs the registry which package ID should be locked to the previous instance of resolve (often used in pairings with updates). See comments in register_previous_locks for scenarios that might override this.

The previous resolve normally comes from a lock file. This function does not read or write lock files from the filesystem.

specs may be empty, which indicates it should resolve all workspace members. In this case, opts.all_features must be true.

If register_patches is true, then entries from the [patch] table in the manifest will be added to the given PackageRegistry.