pub struct Comparison {
pub functions: Vec<FunctionRef>,
pub pairs: Vec<Pair>,
pub calls: Vec<(usize, usize)>,
}Expand description
The result of compare.
Fields§
§functions: Vec<FunctionRef>The named functions of both sides, side 0 first, in source order.
pairs: Vec<Pair>Every pair, in the order of their side-0 function.
calls: Vec<(usize, usize)>Calls within each side, (caller, callee) as indexes into
Self::functions, each once (see [call_graph]).
Implementations§
Source§impl Comparison
impl Comparison
Sourcepub fn ready(&self) -> Vec<bool>
pub fn ready(&self) -> Vec<bool>
For each function of Self::functions, whether it is ready to
port: it counts, it has no partner yet, and every function it calls
has one. Porting these first means no port waits for a helper. Two
unpaired functions that call each other wait for each other, so
neither is ready.
Sourcepub fn paired(&self) -> Vec<bool>
pub fn paired(&self) -> Vec<bool>
Whether the function at index of Self::functions has a partner.
Trait Implementations§
Source§impl Clone for Comparison
impl Clone for Comparison
Source§impl Debug for Comparison
impl Debug for Comparison
Auto Trait Implementations§
impl Freeze for Comparison
impl RefUnwindSafe for Comparison
impl Send for Comparison
impl Sync for Comparison
impl Unpin for Comparison
impl UnsafeUnpin for Comparison
impl UnwindSafe for Comparison
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
impl<ST, DT> CastableFrom<ST, Initialized, Initialized> for DT
impl<ST, DT> CastableFrom<ST, Uninit, Uninit> for DT
Source§impl<T> CloneToUninit for Twhere
T: Clone,
impl<T> CloneToUninit for Twhere
T: Clone,
impl<T> ErasedDestructor for Twhere
T: 'static,
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> ⓘ
Converts
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> ⓘ
Converts
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