pub struct PcodeOpRef<'a>(/* private fields */);Expand description
PcodeOpRef — ergonomic wrapper for p-code operations stored or borrowed.
PcodeOpRef encapsulates either a borrowed reference to a PcodeOperation or an
owned PcodeOperation (internally using Cow). This type is intended to be
the canonical p-code operation reference type used by the sleigh crate.
Methods from Deref<Target = PcodeOperation>§
pub fn branch_destination(&self) -> Option<PcodeBranchDestination>
pub fn opcode(&self) -> OpCode
pub fn terminates_block(&self) -> bool
pub fn has_fallthrough(&self) -> bool
pub fn inputs(&self) -> Vec<GeneralizedVarNode>
pub fn output(&self) -> Option<GeneralizedVarNode>
Trait Implementations§
Source§impl<'a> AsRef<PcodeOperation> for PcodeOpRef<'a>
impl<'a> AsRef<PcodeOperation> for PcodeOpRef<'a>
Source§fn as_ref(&self) -> &PcodeOperation
fn as_ref(&self) -> &PcodeOperation
Converts this type into a shared reference of the (usually inferred) input type.
Source§impl<'a> Clone for PcodeOpRef<'a>
impl<'a> Clone for PcodeOpRef<'a>
Source§fn clone(&self) -> PcodeOpRef<'a>
fn clone(&self) -> PcodeOpRef<'a>
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 moreSource§impl<'a> Debug for PcodeOpRef<'a>
impl<'a> Debug for PcodeOpRef<'a>
Source§impl<'a> Deref for PcodeOpRef<'a>
impl<'a> Deref for PcodeOpRef<'a>
Source§impl<'a> Display for PcodeOpRef<'a>
impl<'a> Display for PcodeOpRef<'a>
Source§impl<'a> From<&'a PcodeOperation> for PcodeOpRef<'a>
impl<'a> From<&'a PcodeOperation> for PcodeOpRef<'a>
Source§fn from(op: &'a PcodeOperation) -> Self
fn from(op: &'a PcodeOperation) -> Self
Converts to this type from the input type.
Source§impl<'a> From<PcodeOperation> for PcodeOpRef<'a>
impl<'a> From<PcodeOperation> for PcodeOpRef<'a>
Source§fn from(op: PcodeOperation) -> Self
fn from(op: PcodeOperation) -> Self
Converts to this type from the input type.
Source§impl<'a> JingleDisplay for PcodeOpRef<'a>
Implement the JingleDisplay trait for PcodeOpRef by delegating to the
inner PcodeOperation’s fmt_jingle implementation.
impl<'a> JingleDisplay for PcodeOpRef<'a>
Implement the JingleDisplay trait for PcodeOpRef by delegating to the
inner PcodeOperation’s fmt_jingle implementation.
fn fmt_jingle(&self, f: &mut Formatter<'_>, info: &SleighArchInfo) -> Result
fn display<T: AsRef<SleighArchInfo>>( &self, info: T, ) -> JingleDisplayWrapper<Self>
Auto Trait Implementations§
impl<'a> Freeze for PcodeOpRef<'a>
impl<'a> RefUnwindSafe for PcodeOpRef<'a>
impl<'a> Send for PcodeOpRef<'a>
impl<'a> Sync for PcodeOpRef<'a>
impl<'a> Unpin for PcodeOpRef<'a>
impl<'a> UnsafeUnpin for PcodeOpRef<'a>
impl<'a> UnwindSafe for PcodeOpRef<'a>
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