| id | 126 |
|---|---|
| title | Collapse the mirrored pass request and build the declaration manifest once |
| blocked-by |
Summary. Two related ownership cleanups graduated from the maintainability audit in
checker-semantic-boundaries-and-maintainability.md
(findings M4 then M1). Effort S + M; non-blocking maintenance, behaviour-neutral. Do M4 first so the
new manifest ownership does not acquire another field mirror.
- M4 —
ProjectLocalUserPassRequest(project_local/project_local_pass_port.rs) andProjectLocalUserPassPlan(checker/mod.rs) share fourteen of fifteen fields; the adapter destructures one and reconstructs the other without validation or conversion. Every new input is defined and forwarded twice. - M1 — On the ordinary non-empty project route
SourceDeclarationManifest::buildruns for the same program slice three times (binding, dependency preparation, checking;checker/mod.rsand the pass port), and inventory authentication is repeated, despite the one-manifest/inventory contract of ADR-0022. These are three executions of one canonical builder, not competing algorithms; no timing or diagnostic regression was demonstrated.
- M4 (S): make the request contain
programsplus the existing plan; keep ordinary/test wrappers and the cfg-gated fault field in its current test owner. Acceptance: identical ordinary behaviour, test fault activation and post-pass inspection; no new public compatibility layer. - M1 (M): retain binding manifests beside the AST-free
BoundProjectBinderin a request-local execution payload; consume them into inventories once with the canonical authentication batch; borrow for dependencies and lexical reservations, then move into checking. No cache, registry, Binder AST lifetime or second state machine. Acceptance: exact source/module pairing, fail-closed authentication, canonical fragment order, lexical event order and outcomes unchanged, plus a construction-count witness on the real ordinary route.
Gates: cargo test, cargo clippy --all-targets -- -D warnings, ordinary exact conformance and the
repeated/standalone parity run (route lifecycle is touched).
crates/typokat-check/src/check/checker/mod.rs,
crates/typokat-check/src/check/checker/project_local/{project_local_pass_port.rs,entry.rs}.