Expand description
codebase salsa query — aggregates every file’s StubSlice into a
finalized mir_codebase::Codebase via codebase_from_parts.
When any file’s file_definitions output changes, salsa marks this query
dirty and re-runs it. Re-running calls file_definitions for each file in
the workspace; unchanged files return their memoized slice instantly, so
the work per edit is O(N * merge_cost) (plus one finalize()).
Phase C step 2: query exists and has correctness tests; Backend still uses
the imperative remove/collect/finalize path. Step 3 migrates Backend.
Structs§
- Codebase
Arc - Opaque handle to a finalized Codebase.
Arc::ptr_eqfor theUpdatecontract — every re-run produces a newArc, matchingParsedArc’s pattern.
Functions§
- codebase
- Build a finalized Codebase from the bundled PHP stubs (string/array/etc.
builtins) plus every user file’s
StubSlice. Depends onWorkspace.filesand transitively on every file’sfile_definitionsquery. Stubs are treated as constant — they don’t participate in salsa invalidation.