pub enum DecodeNode {
Branch {
range: BitRange,
arms: BTreeMap<u64, DecodeNode>,
default: Box<DecodeNode>,
},
Leaf {
instruction_index: usize,
},
PriorityLeaves {
candidates: Vec<usize>,
},
Fail,
}Expand description
A node in the dispatch/decision tree.
Variants§
Branch
Branch on a range of bits, with arms for each value
Leaf
Leaf: matched this instruction
PriorityLeaves
Multiple candidates to try in priority order (most specific to least specific) Used when patterns overlap and can’t be distinguished by bit splits alone
Fail
No instruction matches
Trait Implementations§
Source§impl Clone for DecodeNode
impl Clone for DecodeNode
Source§fn clone(&self) -> DecodeNode
fn clone(&self) -> DecodeNode
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 moreAuto Trait Implementations§
impl Freeze for DecodeNode
impl RefUnwindSafe for DecodeNode
impl Send for DecodeNode
impl Sync for DecodeNode
impl Unpin for DecodeNode
impl UnsafeUnpin for DecodeNode
impl UnwindSafe for DecodeNode
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