Skip to main content

Module deps

Module deps 

Source
Expand description

G10 — local dependency linking: resolve Largo.toml [dependencies] into the loader’s admitted dependency roots, and describe the assembled linked closure.

This is the CLI-side seam that turns a manifest’s path/git declarations into the DepRoots the module loader threads through EVERY tier’s assembly (assemble_closure), so a bare Import <Dep>. links a package living OUTSIDE the project root. Registry linking is intentionally unsupported here — the local closure reaches only the filesystem, so a fully-local project builds with no crates.io access (proved by BuildManifest::registry).

Structs§

BuildManifest
A machine-readable account of a linked build: the local package identity, feature selection, every resolved dependency, the transitive closure (each linked .lg file tagged with its source dependency), and the registry state.
ClosureFile
One file in the assembled closure, tagged with the dependency it came from.
ManifestDep
A resolved dependency as it appears in the build manifest.
PackageIdentity
The local package’s identity in the build manifest.
RegistryState
Whether — and how — a registry was consulted assembling the closure.

Functions§

build_manifest
Assemble the linked closure for entry and describe it as a BuildManifest.
resolve_dep_roots
Resolve the manifest’s linkable dependencies against project_root into the loader’s DepRoots. A resolution failure (a floating git rev, a missing path, an unlinkable form) surfaces as a clean CliError, so every command that links deps reports the same message.