pub enum Constraint {
Passable(Index),
Haltable(Index),
BreakableTo {
breaks_from: Index,
breaks_to: Index,
},
}
Expand description
Flow analysis works by using a constraint solver: we try to solve for whether every node in the graph is “passable”, and in the process of doing so, we also solve “haltable” and “breaks from within some node or its children to some given parent loop node” constraints.
Variants§
Passable(Index)
A Passable
constraint carries the information of which node we are trying to check is
passable or not.
Haltable(Index)
A Haltable
constraint for checking whether or not a node is “haltable”.
BreakableTo
A BreakableTo
constraint for checking whether or not a loop can be “broken to” by a node
within its body.
Trait Implementations§
Source§impl Clone for Constraint
impl Clone for Constraint
Source§fn clone(&self) -> Constraint
fn clone(&self) -> Constraint
Returns a duplicate of the value. Read more
1.0.0 · Source§fn clone_from(&mut self, source: &Self)
fn clone_from(&mut self, source: &Self)
Performs copy-assignment from
source
. Read moreSource§impl Debug for Constraint
impl Debug for Constraint
Source§impl Hash for Constraint
impl Hash for Constraint
Source§impl Ord for Constraint
impl Ord for Constraint
Source§fn cmp(&self, other: &Constraint) -> Ordering
fn cmp(&self, other: &Constraint) -> Ordering
1.21.0 · Source§fn max(self, other: Self) -> Selfwhere
Self: Sized,
fn max(self, other: Self) -> Selfwhere
Self: Sized,
Compares and returns the maximum of two values. Read more
Source§impl PartialEq for Constraint
impl PartialEq for Constraint
Source§impl PartialOrd for Constraint
impl PartialOrd for Constraint
impl Copy for Constraint
impl Eq for Constraint
impl StructuralPartialEq for Constraint
Auto Trait Implementations§
impl Freeze for Constraint
impl RefUnwindSafe for Constraint
impl Send for Constraint
impl Sync for Constraint
impl Unpin for Constraint
impl UnwindSafe for Constraint
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
Mutably borrows from an owned value. Read more
Source§impl<T> CloneToUninit for Twhere
T: Clone,
impl<T> CloneToUninit for Twhere
T: Clone,
Source§impl<Q, K> Comparable<K> for Q
impl<Q, K> Comparable<K> for Q
Source§impl<Q, K> Equivalent<K> for Q
impl<Q, K> Equivalent<K> for Q
Source§impl<Q, K> Equivalent<K> for Q
impl<Q, K> Equivalent<K> for Q
Source§fn equivalent(&self, key: &K) -> bool
fn equivalent(&self, key: &K) -> bool
Compare self to
key
and return true
if they are equal.