Struct iced_x86::ConstantOffsets[][src]

pub struct ConstantOffsets { /* fields omitted */ }

Contains the offsets of the displacement and immediate. Call Decoder::get_constant_offsets() or Encoder::get_constant_offsets() to get the offsets of the constants after the instruction has been decoded/encoded.

Implementations

impl ConstantOffsets[src]

#[must_use]pub fn displacement_offset(&self) -> usize[src]

The offset of the displacement, if any

#[must_use]pub fn displacement_size(&self) -> usize[src]

Size in bytes of the displacement, or 0 if there’s no displacement

#[must_use]pub fn immediate_offset(&self) -> usize[src]

The offset of the first immediate, if any.

This field can be invalid even if the operand has an immediate if it’s an immediate that isn’t part of the instruction stream, eg. SHL AL,1.

#[must_use]pub fn immediate_size(&self) -> usize[src]

Size in bytes of the first immediate, or 0 if there’s no immediate

#[must_use]pub fn immediate_offset2(&self) -> usize[src]

The offset of the second immediate, if any.

#[must_use]pub fn immediate_size2(&self) -> usize[src]

Size in bytes of the second immediate, or 0 if there’s no second immediate

#[must_use]pub fn has_displacement(&self) -> bool[src]

#[must_use]pub fn has_immediate(&self) -> bool[src]

true if immediate_offset() and immediate_size() are valid

#[must_use]pub fn has_immediate2(&self) -> bool[src]

true if immediate_offset2() and immediate_size2() are valid

Trait Implementations

impl Clone for ConstantOffsets[src]

impl Copy for ConstantOffsets[src]

impl Debug for ConstantOffsets[src]

impl Default for ConstantOffsets[src]

impl Eq for ConstantOffsets[src]

impl Hash for ConstantOffsets[src]

impl PartialEq<ConstantOffsets> for ConstantOffsets[src]

impl StructuralEq for ConstantOffsets[src]

impl StructuralPartialEq for ConstantOffsets[src]

Auto Trait Implementations

Blanket Implementations

impl<T> Any for T where
    T: 'static + ?Sized
[src]

impl<T> Borrow<T> for T where
    T: ?Sized
[src]

impl<T> BorrowMut<T> for T where
    T: ?Sized
[src]

impl<T> From<T> for T[src]

impl<T, U> Into<U> for T where
    U: From<T>, 
[src]

impl<T> ToOwned for T where
    T: Clone
[src]

type Owned = T

The resulting type after obtaining ownership.

impl<T, U> TryFrom<U> for T where
    U: Into<T>, 
[src]

type Error = Infallible

The type returned in the event of a conversion error.

impl<T, U> TryInto<U> for T where
    U: TryFrom<T>, 
[src]

type Error = <U as TryFrom<T>>::Error

The type returned in the event of a conversion error.