mz_transform::analysis::equivalences

Trait UnionFind

Source
trait UnionFind<T> {
    // Required methods
    fn find<'a>(&'a mut self, x: &T) -> Option<&'a T>;
    fn union(&mut self, x: &T, y: &T);
}

Required Methods§

Source

fn find<'a>(&'a mut self, x: &T) -> Option<&'a T>

Sets self[x] to the root from x, and returns a reference to the root.

Source

fn union(&mut self, x: &T, y: &T)

Ensures that x and y have the same root.

Implementations on Foreign Types§

Source§

impl<T: Clone + Ord> UnionFind<T> for BTreeMap<T, T>

Source§

fn find<'a>(&'a mut self, x: &T) -> Option<&'a T>

Source§

fn union(&mut self, x: &T, y: &T)

Implementors§