pub struct Reachability {
pub verdict: ReachVerdict,
pub config: String,
pub engine: String,
pub targets: Vec<String>,
pub witness: Option<String>,
}Expand description
A static-reachability verdict for a finding’s affected functions, scoped to the toolchain + feature/target config it was computed under (spec §7).
Fields§
§verdict: ReachVerdictThe reachability outcome for the finding’s affected functions.
config: StringThe config the verdict is scoped to (toolchain + features/target).
engine: StringThe engine that produced it, e.g. static-mir-rta@<ver>.
targets: Vec<String>The target triple(s) the verdict was computed for (spec §7 edge 3): a
function unreachable on one target may be reachable behind a cfg on
another, so a NotReachable names its targets. Additive; omitted when empty.
witness: Option<String>A content-addressed witness for a NotReachable verdict (spec §9.2): a
hash binding the verdict to the exact inputs that produced it (lockfile,
source, toolchain, features, sinks). fleetreach vex verify re-derives
against current source and fails if the verdict no longer holds. Additive;
None for Reachable/Unknown and when caching was impossible.
Implementations§
Source§impl Reachability
impl Reachability
Sourcepub fn tier_c_unknown(reason: impl Into<String>) -> Self
pub fn tier_c_unknown(reason: impl Into<String>) -> Self
The reachability verdict shared by every toolchain-free (Tier-C) feeder: a
package/version match with no call-graph analysis. It is always Unknown
(never NotReachable — Tier-C must not claim a soundness it did not compute),
with a fixed config/engine so the report renders the tier consistently
across all ecosystems. reason names the lower fidelity for the report.
Centralizing this here keeps the Tier-C contract in one place instead of
copy-pasted into each feeder’s scan.rs, where a divergence would be a
silent per-ecosystem inconsistency the compiler could not catch.
Sourcepub fn as_legacy_bool(&self) -> Option<bool>
pub fn as_legacy_bool(&self) -> Option<bool>
Map onto the legacy heuristic reachable: Option<bool> for back-compat
(spec §7): Reachable -> Some(true), NotReachable -> Some(false),
Unknown -> None.
Trait Implementations§
Source§impl Clone for Reachability
impl Clone for Reachability
Source§fn clone(&self) -> Reachability
fn clone(&self) -> Reachability
1.0.0 (const: unstable) · Source§fn clone_from(&mut self, source: &Self)
fn clone_from(&mut self, source: &Self)
source. Read moreSource§impl Debug for Reachability
impl Debug for Reachability
Source§impl<'de> Deserialize<'de> for Reachability
impl<'de> Deserialize<'de> for Reachability
Source§fn deserialize<__D>(__deserializer: __D) -> Result<Self, __D::Error>where
__D: Deserializer<'de>,
fn deserialize<__D>(__deserializer: __D) -> Result<Self, __D::Error>where
__D: Deserializer<'de>,
Source§impl PartialEq for Reachability
impl PartialEq for Reachability
Source§fn eq(&self, other: &Reachability) -> bool
fn eq(&self, other: &Reachability) -> bool
self and other values to be equal, and is used by ==.Source§impl Serialize for Reachability
impl Serialize for Reachability
impl StructuralPartialEq for Reachability
Auto Trait Implementations§
impl Freeze for Reachability
impl RefUnwindSafe for Reachability
impl Send for Reachability
impl Sync for Reachability
impl Unpin for Reachability
impl UnsafeUnpin for Reachability
impl UnwindSafe for Reachability
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,
impl<T> DeserializeOwned for Twhere
T: for<'de> Deserialize<'de>,
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