pub struct MergePair {
pub first: Option<NodeRef>,
pub second: Option<NodeRef>,
}Expand description
A pair of nodes from the two branches to be merged.
Either node may be None if only one branch has content at this position.
Fields§
§first: Option<NodeRef>The node from the first branch (left).
second: Option<NodeRef>The node from the second branch (right).
Implementations§
Source§impl MergePair
impl MergePair
Sourcepub fn first_node(&self) -> Option<&NodeRef>
pub fn first_node(&self) -> Option<&NodeRef>
Returns the first node.
Sourcepub fn second_node(&self) -> Option<&NodeRef>
pub fn second_node(&self) -> Option<&NodeRef>
Returns the second node.
Sourcepub fn single_node(&self) -> Option<&NodeRef>
pub fn single_node(&self) -> Option<&NodeRef>
Returns the single node if only one is present.
Trait Implementations§
Auto Trait Implementations§
impl Freeze for MergePair
impl !RefUnwindSafe for MergePair
impl !Send for MergePair
impl !Sync for MergePair
impl Unpin for MergePair
impl !UnwindSafe for MergePair
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