Expand description
#2223 follow-up: what the editor needs to know about a project’s path dependencies.
The compile folds a dependency’s units in under canonical names
(bynk_check::packages::apply_graph), but completion, hover and the
unit-name rungs of go-to-definition read source text, where a consumer
writes money.currency and the dependency declares plain currency. A
DependencyView bridges the two: it resolves a written <alias>.<unit>
to the dependency and the unit it declares, says whether the unit is
exported, and tells which files belong to a dependency, so the editor
offers exactly what the compiler accepts.
Structs§
- Dependency
Target - A written dependency reference, resolved.
- Dependency
View - The project’s dependency graph, as the editor reads it.
Functions§
- hover_
note - The line hover appends for a dependency unit.
- unit_
sources_ for - The project-relative source paths of the unit a
uses/consumestarget names, from an analysed round’sunit_sources— what go-to-definition opens. A dependency unit is keyed by its canonical name, somoney.currencyis looked up throughviewwhen it isn’t a key itself.