[−][src]Struct dynasmrt::Modifier
Allows modification of already committed assembly code. Contains an internal cursor
into the emitted assembly, initialized to the start, that can be moved around either with the
goto function, or just by assembling new code into this Modifier.
Methods
impl<'a, R: Relocation> Modifier<'a, R>[src]
pub fn goto(&mut self, offset: AssemblyOffset)[src]
Move the modifier cursor to the selected location.
pub fn check(&self, offset: AssemblyOffset) -> Result<(), DynasmError>[src]
Check that the modifier cursor has not moved past the specified location.
pub fn check_exact(&self, offset: AssemblyOffset) -> Result<(), DynasmError>[src]
Check that the modifier cursor is exactly at the specified location.
Trait Implementations
impl<'a, R: Relocation> DynasmApi for Modifier<'a, R>[src]
fn offset(&self) -> AssemblyOffset[src]
fn push(&mut self, value: u8)[src]
fn align(&mut self, alignment: usize, with: u8)[src]
fn push_i8(&mut self, value: i8)[src]
fn push_i16(&mut self, value: i16)[src]
fn push_i32(&mut self, value: i32)[src]
fn push_i64(&mut self, value: i64)[src]
fn push_u16(&mut self, value: u16)[src]
fn push_u32(&mut self, value: u32)[src]
fn push_u64(&mut self, value: u64)[src]
fn runtime_error(&self, msg: &'static str) -> ![src]
impl<'a, R: Relocation> DynasmLabelApi for Modifier<'a, R>[src]
type Relocation = R
The relocation info type this assembler uses.
fn local_label(&mut self, name: &'static str)[src]
fn global_label(&mut self, name: &'static str)[src]
fn dynamic_label(&mut self, id: DynamicLabel)[src]
fn global_relocation(&mut self, name: &'static str, offset: isize, kind: R)[src]
fn dynamic_relocation(&mut self, id: DynamicLabel, offset: isize, kind: R)[src]
fn forward_relocation(&mut self, name: &'static str, offset: isize, kind: R)[src]
fn backward_relocation(&mut self, name: &'static str, offset: isize, kind: R)[src]
fn bare_relocation(&mut self, target: usize, kind: R)[src]
fn forward_reloc(
&mut self,
name: &'static str,
offset: isize,
kind: <Self::Relocation as Relocation>::Encoding
)[src]
&mut self,
name: &'static str,
offset: isize,
kind: <Self::Relocation as Relocation>::Encoding
)
fn backward_reloc(
&mut self,
name: &'static str,
offset: isize,
kind: <Self::Relocation as Relocation>::Encoding
)[src]
&mut self,
name: &'static str,
offset: isize,
kind: <Self::Relocation as Relocation>::Encoding
)
fn global_reloc(
&mut self,
name: &'static str,
offset: isize,
kind: <Self::Relocation as Relocation>::Encoding
)[src]
&mut self,
name: &'static str,
offset: isize,
kind: <Self::Relocation as Relocation>::Encoding
)
fn dynamic_reloc(
&mut self,
id: DynamicLabel,
offset: isize,
kind: <Self::Relocation as Relocation>::Encoding
)[src]
&mut self,
id: DynamicLabel,
offset: isize,
kind: <Self::Relocation as Relocation>::Encoding
)
fn bare_reloc(
&mut self,
target: usize,
kind: <Self::Relocation as Relocation>::Encoding
)[src]
&mut self,
target: usize,
kind: <Self::Relocation as Relocation>::Encoding
)
impl<'a, R: Relocation> Extend<u8> for Modifier<'a, R>[src]
fn extend<T>(&mut self, iter: T) where
T: IntoIterator<Item = u8>, [src]
T: IntoIterator<Item = u8>,
impl<'a, 'b, R: Relocation> Extend<&'b u8> for Modifier<'a, R>[src]
fn extend<T>(&mut self, iter: T) where
T: IntoIterator<Item = &'b u8>, [src]
T: IntoIterator<Item = &'b u8>,
impl<'a, R: Debug + Relocation> Debug for Modifier<'a, R>[src]
Auto Trait Implementations
impl<'a, R> Send for Modifier<'a, R> where
R: Send,
R: Send,
impl<'a, R> Sync for Modifier<'a, R> where
R: Sync,
R: Sync,
impl<'a, R> Unpin for Modifier<'a, R> where
R: Unpin,
R: Unpin,
impl<'a, R> RefUnwindSafe for Modifier<'a, R> where
R: RefUnwindSafe,
R: RefUnwindSafe,
impl<'a, R> !UnwindSafe for Modifier<'a, R>
Blanket Implementations
impl<T> From<T> for T[src]
impl<T, U> Into<U> for T where
U: From<T>, [src]
U: From<T>,
impl<T, U> TryFrom<U> for T where
U: Into<T>, [src]
U: Into<T>,
type Error = Infallible
The type returned in the event of a conversion error.
fn try_from(value: U) -> Result<T, <T as TryFrom<U>>::Error>[src]
impl<T, U> TryInto<U> for T where
U: TryFrom<T>, [src]
U: TryFrom<T>,
type Error = <U as TryFrom<T>>::Error
The type returned in the event of a conversion error.
fn try_into(self) -> Result<U, <U as TryFrom<T>>::Error>[src]
impl<T> BorrowMut<T> for T where
T: ?Sized, [src]
T: ?Sized,
fn borrow_mut(&mut self) -> &mut T[src]
impl<T> Borrow<T> for T where
T: ?Sized, [src]
T: ?Sized,
impl<T> Any for T where
T: 'static + ?Sized, [src]
T: 'static + ?Sized,