pub struct AuditKeySnapshot {
pub type_aware_identity: Option<SemanticAnalysisIdentity>,
pub type_aware_gap_signature: Vec<String>,
pub syntactic_dead_code: Option<FxHashSet<String>>,
pub dead_code: FxHashSet<String>,
pub health: FxHashSet<String>,
pub styling: FxHashSet<String>,
pub dupes: FxHashSet<String>,
pub boundary_edges: FxHashSet<String>,
pub cycles: FxHashSet<String>,
pub public_api: FxHashSet<String>,
pub branching: FxHashMap<String, FileBranching>,
}Expand description
Attribution keys of one audit side (the base commit, or the head run when the base pass is skipped).
Every key set is root-relative, so a base snapshot taken in a temporary worktree joins the head run by key.
Fields§
§type_aware_identity: Option<SemanticAnalysisIdentity>Semantic identity of a type-aware dead-code pass, None for a
syntactic pass.
type_aware_gap_signature: Vec<String>Sorted reasons and omissions of the semantic queries that did not complete. Two sides with different gaps cannot compare semantic keys.
syntactic_dead_code: Option<FxHashSet<String>>Dead-code keys captured before type-aware refinement. None when the
pass ran without type-aware analysis (then dead_code is already
syntactic). The degraded attribution path compares these.
dead_code: FxHashSet<String>Dead-code keys.
health: FxHashSet<String>Complexity keys.
styling: FxHashSet<String>Styling keys.
dupes: FxHashSet<String>Clone-group keys.
boundary_edges: FxHashSet<String>Cross-zone boundary edge keys (<from_zone>->-<to_zone>), one for each
zone pair.
cycles: FxHashSet<String>Canonical circular-dependency keys.
public_api: FxHashSet<String>Exports-aware public-export keys (<rel_path>::<name>). Empty unless
the surface computed them from the retained module graph.
branching: FxHashMap<String, FileBranching>Branching totals per root-relative path. Threshold-blind and suppression-blind, so a threshold override or an ignore comment cannot move the head-versus-base comparison.
Implementations§
Source§impl AuditKeySnapshot
impl AuditKeySnapshot
Sourcepub fn from_view(view: &AuditAnalysesView<'_>) -> Self
pub fn from_view(view: &AuditAnalysesView<'_>) -> Self
Take the attribution keys of one set of analyses.
Sourcepub fn remap_for_renames(&mut self, renames: &[RenamedFile], root: &Path)
pub fn remap_for_renames(&mut self, renames: &[RenamedFile], root: &Path)
Relocate the keys of renamed files onto their head paths.
Applies to every path-keyed family (dead code, complexity, styling, duplication, cycles, public API, branching). Boundary-edge keys are zone-pair keys without a path, and the type-aware identity has no path, so they stay as they are. The syntactic dead-code keys of the degraded type-aware path also stay as they are.
Sourcepub fn to_programmatic(&self) -> AuditProgrammaticKeySnapshot
pub fn to_programmatic(&self) -> AuditProgrammaticKeySnapshot
The public key snapshot of the programmatic audit output. Its health set also holds the styling keys.
Trait Implementations§
Source§impl Clone for AuditKeySnapshot
impl Clone for AuditKeySnapshot
Source§impl Debug for AuditKeySnapshot
impl Debug for AuditKeySnapshot
Auto Trait Implementations§
impl Freeze for AuditKeySnapshot
impl RefUnwindSafe for AuditKeySnapshot
impl Send for AuditKeySnapshot
impl Sync for AuditKeySnapshot
impl Unpin for AuditKeySnapshot
impl UnsafeUnpin for AuditKeySnapshot
impl UnwindSafe for AuditKeySnapshot
Blanket Implementations§
Source§impl<T> BorrowMut<T> for Twhere
T: ?Sized,
impl<T> BorrowMut<T> for Twhere
T: ?Sized,
Source§fn borrow_mut(&mut self) -> &mut T
fn borrow_mut(&mut self) -> &mut T
Source§impl<T> CloneToUninit for Twhere
T: Clone,
impl<T> CloneToUninit for Twhere
T: Clone,
Source§impl<T> Instrument for T
impl<T> Instrument for T
Source§fn instrument(self, span: Span) -> Instrumented<Self> ⓘ
fn instrument(self, span: Span) -> Instrumented<Self> ⓘ
Source§fn in_current_span(self) -> Instrumented<Self> ⓘ
fn in_current_span(self) -> Instrumented<Self> ⓘ
Source§impl<T> IntoEither for T
impl<T> IntoEither for T
Source§fn into_either(self, into_left: bool) -> Either<Self, Self> ⓘ
fn into_either(self, into_left: bool) -> Either<Self, Self> ⓘ
self into a Left variant of Either<Self, Self>
if into_left is true.
Converts self into a Right variant of Either<Self, Self>
otherwise. Read moreSource§fn into_either_with<F>(self, into_left: F) -> Either<Self, Self> ⓘ
fn into_either_with<F>(self, into_left: F) -> Either<Self, Self> ⓘ
self into a Left variant of Either<Self, Self>
if into_left(&self) returns true.
Converts self into a Right variant of Either<Self, Self>
otherwise. Read more