[−][src]Function mt_dom::apply_patches::apply_patches
pub fn apply_patches<'a, NS, TAG, ATT, VAL, EVENT, MSG>(
root_node: &mut Node<NS, TAG, ATT, VAL, EVENT, MSG>,
patches: &[Patch<'a, NS, TAG, ATT, VAL, EVENT, MSG>]
) where
NS: Clone + Debug,
TAG: Clone + Debug,
ATT: Clone + Debug + PartialEq,
VAL: Clone + Debug,
had to find the node each time, since rust does not allow multiple mutable borrows ISSUE: once a destructive patch such as RemoveChildren, InsertNode, ReplaceNode is applied the Nodeidx is not synch with the root_node anymore.
To minimize this issue, destructive patches is applied last. It doesn't elimiate the problem completely, and it will arise when there are multiple destructive patch.