pub struct Presentation {
pub antigen_type: String,
pub file: PathBuf,
pub line: usize,
pub item_kind: String,
pub item_target: ItemTarget,
pub match_kind: MatchKind,
pub canonical_path: Option<String>,
pub inherited_from: Option<Vec<ProvenanceEntry>>,
pub structural_fingerprint: String,
pub requires_predicate: Option<String>,
pub proof: Option<String>,
}Expand description
A #[presents(antigen_type)] declaration or synthetic fingerprint match
discovered in source.
Fields§
§antigen_type: StringThe antigen type referenced (last path segment, e.g., PanickingInDrop).
file: PathBufSource file path.
line: usizeLine number.
item_kind: StringItem kind that was annotated (impl, fn, struct, etc.).
item_target: ItemTargetItem identity for structural matching against Immunity. W3.
match_kind: MatchKindHow this presentation was discovered: explicit marker vs fingerprint
match. W6a. Defaults to ExplicitMarker for backwards
compatibility with serialized reports from before W6a.
canonical_path: Option<String>Canonical declaration site of the antigen referenced by this
presentation (not the presentation’s own location). ADR-017.
None for intra-workspace antigens; Some("<crate>@<version>")
for cross-crate antigens (set by the --include-deps driver
after scanning the dependency crate root).
inherited_from: Option<Vec<ProvenanceEntry>>Provenance chain of ancestor antigens this presentation was inherited from. ADR-018 (propagation semantics).
None= direct presentation (explicit marker or fingerprint match).Some(chain)= synthesized via the propagation walk; the chain names every transitive ancestor antigen whose presentation propagated here (set-union across diamond paths). EmptyVecinsideSomeis forbidden — normalised toNoneat construction.
Audit emits a warn-level diagnostic for presentations with
inherited_from = Some(_) that lack a re-attested immunity or
tolerance on the descendant site (state 7 of the 7-state matrix).
structural_fingerprint: StringFNV-1a structural digest of the presented item at scan time.
Populated for FingerprintMatch presentations; empty string for
ExplicitMarker presentations and inherited presentations where the
ancestor was an explicit marker. Allows adopters to pass this value
directly to attest scaffold --fingerprint without needing an
#[immune] marker first (DX finding 6).
requires_predicate: Option<String>Substrate-witness predicate JSON folded onto the presents-site via
#[presents(X, requires = <predicate>)] (ADR-029 R5 — the substrate-tier
migration target for #[immune(requires=...)]). Some only when the
presents-site carries site-attached substrate evidence. The audit
evaluates this against .attest/ sidecars to grade the immune-state
verdict.
#[serde(default)] so pre-ADR-029 reports deserialize cleanly.
proof: Option<String>Phantom-type proof expression folded onto the presents-site via
#[presents(X, proof = <expr>)] (ADR-029 R5 — the phantom-tier migration
target for #[immune(witness = <phantom>)]), rendered as its token
string (e.g. NonPanickingProof :: < T > :: verified). The audit
recognizes the phantom shape structurally and grades FormalProof.
#[serde(default)] so pre-ADR-029 reports deserialize cleanly.
Trait Implementations§
Source§impl Clone for Presentation
impl Clone for Presentation
Source§fn clone(&self) -> Presentation
fn clone(&self) -> Presentation
1.0.0 (const: unstable) · Source§fn clone_from(&mut self, source: &Self)
fn clone_from(&mut self, source: &Self)
source. Read more