Expand description
Reference resolution via FlattenedScopeCache.
Pre-computes the visible scope per file by BFS-ing the import graph once, then resolves references with O(1) lookups instead of per-reference graph traversals.
Structs§
- Flattened
Scope Cache - Pre-computed visible scope for each file.
- Resolution
Context - Bundles the data needed for scope resolution across files.
- Resolved
Reference - One resolved use of a name, with the site that produced it.
Functions§
- build_
symbol_ index - Build a symbol index from extracted files and a path-to-FileId mapping.
- reference_
edges - Fold resolved use sites into one edge per
(source, target)pair. - resolve_
all_ references - Resolve all references across extracted files.
- resolve_
references_ detailed - Resolve every reference and keep its use site.