pub enum TerminatorTarget {
Direct,
Register {
reg: String,
},
Memory {
base: Option<String>,
index: Option<String>,
disp: i64,
},
Implicit,
}Expand description
How the terminating control transfer picks its target.
Split out from Terminator rather than folded into
it so that no existing variant, name or serialized string changes: v0.3’s
terminator field still reads "ret", "jmp", "call", and the
register/memory distinction the query layer wants arrives beside it.
Variants§
Direct
The target is an immediate encoded in the instruction
(jmp 0x400340, call 0x401120).
Register
Indirect through a register (jmp rax, blr x16, bctr).
Memory
Indirect through memory (jmp qword ptr [rax + 8]).
Fields
Implicit
The target is not an operand: it comes off the stack (ret) or out of
a link register (bx lr, jr $ra, blr), or there is no terminator.
Implementations§
Trait Implementations§
Source§impl Clone for TerminatorTarget
impl Clone for TerminatorTarget
Source§impl Debug for TerminatorTarget
impl Debug for TerminatorTarget
impl Eq for TerminatorTarget
Source§impl PartialEq for TerminatorTarget
impl PartialEq for TerminatorTarget
Source§impl Serialize for TerminatorTarget
impl Serialize for TerminatorTarget
impl StructuralPartialEq for TerminatorTarget
Auto Trait Implementations§
impl Freeze for TerminatorTarget
impl RefUnwindSafe for TerminatorTarget
impl Send for TerminatorTarget
impl Sync for TerminatorTarget
impl Unpin for TerminatorTarget
impl UnsafeUnpin for TerminatorTarget
impl UnwindSafe for TerminatorTarget
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
Source§impl<T> CloneToUninit for Twhere
T: Clone,
impl<T> CloneToUninit for Twhere
T: Clone,
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