Skip to main content

Module join

Module join 

Source
Expand description

Path-free callgraph extraction and checkout-backed reference resolution.

The index store keeps immutable parse payloads. Binding a payload to its checkout path and resolving cross-file references uses the checkout’s ProjectFacts, not a separate manifest or artifact store.

Modules§

dispatch
Source-independent method linking for manifest views. Extraction records only syntactic receiver evidence; joining never reparses or opens checkout files.
record
The stored form of what one file’s resolution recorded: its binding and its dispatch type targets, with the surface queries and answers that decide whether the resolution can be reused.
single_walk
The call-graph extractor: one walk over each file’s syntax tree.
syntax_index
One walk over a file’s syntax tree, shared by every extraction pass.

Structs§

AstPreorderNode
Tree-sitter node position in canonical pre-order traversal order.
BlobImport
A parsed import retained in the blob so binding can resolve aliases without re-reading source text.
BlobRef
An unresolved reference extracted from one source blob.
BlobSymbol
A symbol captured by extraction. Its ordinal is the source AST node’s pre-order position, not a per-path or database-generated identifier.
CallerRefKey
The stable identity of one bound blob reference. The path breaks ties when identical content is bound at more than one manifest path.
ConfigBlob
Raw source is retained only for configuration files and ignore-list members. These blobs are parsed during joining because their interpretation depends on the manifest view they configure.
DerivedRow
A logical derived row. It is intentionally independent of SQLite rowids and other physical database details.
DispatchTypeTargetTrace
What resolving one Rust file’s receiver type names consulted: every resolver index answer it read, and every path whose presence it probed. While each recorded answer is unchanged and no probed path was added or removed, the file’s receiver type targets are unchanged too, because the file’s own parse blob is the only other input.
DispatchTypeTargets
One Rust file’s receiver type targets, keyed by the type name as written.
ParseBlob
Path-free parse output stored for a regular source file.
ViewBindingDependencies
Bound reference dependencies and resolver probes are generation-specific, unlike parse blobs. The owner must invalidate these whenever a probed path changes.
ViewBindingFacts
Memo answers and their provenance belong to one immutable manifest join. Replaying provenance on hits keeps missing candidates and facts attributable.

Enums§

BlobRefKind
The parse-level class of a reference. No target path is present in a blob.
CallgraphBlob
The immutable callgraph blob payload. A regular source blob has parse output only; a configuration blob is intentionally raw so its manifest-scoped resolver settings can be interpreted during assembly.
ManifestJoinError
An error raised while decoding parse payloads or resolving checkout references.
ResolutionStatus
The manifest-derived resolution state for one reference.
ViewSurfaceQuery
Consumer-specific export surface: record the answers the resolver actually used, rather than invalidating every caller when an unrelated export changes. Querying these answers against a new index is cheaper than walking references and is sound only while the caller’s immutable parse blob remains unchanged.

Constants§

SUPERSEDED_PUBLISH
The reason a view publication fence gives when it refuses a publication because the checkout’s view owner was superseded. A cancelled join (ManifestJoinError::Cancelled) reports the same text.
VIEW_CONFIG_MEMBERSHIP_DOMAIN
Recorded by today’s views for every config file a resolution found, and by every JavaScript workspace member list; set when any config file is added or removed.
VIEW_GO_MODULES_DOMAIN
The Go module map: every go.mod and the module path it declares. A reader records this one key instead of the map’s inputs, so its recorded inputs are the same whichever reader built the map, and an edit that changes the map (a go.mod added, removed or rewritten) re-checks every reader through the GoPackage answers they recorded.
VIEW_GO_PACKAGE_DOMAIN
Recorded by every Go package file listing. A listing reads the directory, not the files in it, so a file added to the package is no recorded dependency of the callers that listed it; the owner rechecks this domain whenever a .go file is added or removed.
VIEW_JS_WORKSPACES_DOMAIN
The prefix of the data layer’s JavaScript workspace package keys (js_package_key). The data layer keeps every other config probe as a path and a recorded answer, so it does not use VIEW_CONFIG_MEMBERSHIP_DOMAIN.
VIEW_RUST_CRATES_DOMAIN
The Rust workspace’s crate names and source folders, read from every Cargo.toml. Recorded like VIEW_GO_MODULES_DOMAIN: one key for the map, set by any Cargo.toml added, removed or rewritten, with the answers each reader used kept as Crate queries. Today’s views set this key; the data layer sets rust_crate_key for each crate name whose entry changed instead.

Functions§

bind_file
Binds one file’s parse against its checkout’s path facts. Returns the file’s resolver surface, and its binding: which paths each reference’s binding probed, and the paths and configuration fields binding consulted. With cache, reference dependencies come from that earlier binding of the same parse instead of being recorded again.
dispatch_type_targets_for
The project files the type names of one Rust, TypeScript or JavaScript file resolve to, for method-call resolution, with the surface queries and path probes they consulted.
extraction_error
Keep grammar availability typed across the index-store extraction boundary; it is neither a malformed source file nor a successful empty record.
finish_binding
Fills a binding’s summary fields once binding and resolution are done: every configuration field it consulted, whether any configuration read was opaque, and every path its answers depend on.
js_package_key
The key a reader records for looking up the package name among the members of the JavaScript workspace at root (checkout-relative, / separators), found or not. Finding it walks the workspace’s member folders and reads each member’s package.json name; recording those reads in every file with a bare import cost a monorepo about 1,300 recorded reads per file. The key replaces them: a package.json or pnpm-workspace.yaml added, removed or edited, or a symlink changed, sets the key of each name whose resolved member changed, so only the files that looked that name up are bound again.
language_id
resolve_file
Resolves every reference of one caller against index, adding one row per reference to rows. Records in binding the surface queries resolution asked with their answers, the paths it consulted beyond binding’s, and the configuration fields it read. Returns how many distinct bindings it resolved (references sharing a binding are resolved once).
rust_crate_key
The key a reader records for looking up the workspace crate name, found or not. A Cargo.toml edit that adds, removes, renames or moves a crate then reaches only the files that looked that name up, instead of every Rust file: adding a crate nothing imports rebinds nothing, and a file whose use named a crate that did not exist yet is rebound when it appears.
rust_module_key
The key of what Rust files at segments under src_prefix contain, for inline module lookups that consult those files. A Rust file added, removed or edited sets the key of its own module path.
rust_module_key_for_file
rust_module_key for the Rust file at path: the key its surface changes set.
rust_module_name_key
One module-name lookup in its declaring file, including an absent name.
view_resolution_config
Configuration files read by the manifest resolver’s workspace/package and tsconfig lookup (callgraph.rs), and Rust crate lookup (callgraph_store). Directory discovery uses a compact membership domain for these names. Their content changes invalidate only callers that consulted changed fields.