Struct klinker::Instr[][src]

pub struct Instr { /* fields omitted */ }

A struct representing an instruction in the context of a KSM file. The operands to this instruction should be u32’s that represent an index into an ArgumentSection

Implementations

impl Instr[src]

pub fn new(opcode: u8, operands: Vec<u32>) -> Instr[src]

pub fn write(
    &self,
    addr_bytes: u32,
    writer: &mut KSMFileWriter
) -> Result<(), Box<dyn Error>>
[src]

pub fn num_operands(&self) -> u32[src]

pub fn from_rel(
    rel_instr: &RelInstruction,
    argument_section: &ArgumentSection
) -> Result<Instr, Box<dyn Error>>
[src]

Trait Implementations

impl Clone for Instr[src]

impl Debug for Instr[src]

Auto Trait Implementations

impl RefUnwindSafe for Instr

impl Send for Instr

impl Sync for Instr

impl Unpin for Instr

impl UnwindSafe for Instr

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.