You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Hidden coupling (#17) and module depth (#18) read imports and exports through one adapter per language; only TypeScript/JavaScript has one. Rust's module system (mod declarations, mod.rs or name.rs files, use crate::…, pub use re-exports, Cargo workspaces) maps code to files unambiguously and fits module depth particularly well.
Goal
Rust repositories get Coupling.imports and Module.depth like TypeScript repositories do.
Acceptance criteria
A Rust adapter resolves mod declarations, use crate::, use super::, use self::, and use <workspace crate>:: (crate names from Cargo workspace members) to universe files; external crates are ignored.
It lists a crate's public surface for depth: pub items reachable from lib.rs, following pub use re-exports; pub(crate) and pub(super) are not public.
A fixture workspace with two crates, an imported pair, a hidden pair, and a pub use re-export proves both.
Activity