Skip to main content

reachable_avoiding

Function reachable_avoiding 

Source
pub fn reachable_avoiding(
    graph: &[NQuin],
    source: u64,
    target: u64,
    avoid: u64,
) -> bool
Expand description

Zero-heap reachability over causal edges (subject → object): is target reachable from source WITHOUT ever passing through avoid? Bounded BFS over fixed stack buffers (no allocation). Pass avoid == u64::MAX to avoid nothing. (The heap variant find_causal_paths enumerates all paths for analysis; this answers the yes/no reachability the but-for test needs, allocation-free.)