[−][src]Struct dynasmrt::components::RelocRegistry
A registry of relocations and the respective labels they point towards.
Implementations
impl<R: Relocation> RelocRegistry<R>[src]
pub fn new() -> RelocRegistry<R>[src]
Create a new, empty relocation registry.
pub fn add_global(&mut self, name: &'static str, patchloc: PatchLoc<R>)[src]
Add a new patch targetting the global label name.
pub fn add_dynamic(&mut self, id: DynamicLabel, patchloc: PatchLoc<R>)[src]
Add a new patch targetting the dynamic label id.
pub fn add_local(&mut self, name: &'static str, patchloc: PatchLoc<R>)[src]
Add a new patch targetting the next local label name.
As any relocation targetting a previous local label can be immediately resolved these should not be recorded.
pub fn take_locals_named<'a>(
&'a mut self,
name: &'static str
) -> impl Iterator<Item = PatchLoc<R>> + 'a[src]
&'a mut self,
name: &'static str
) -> impl Iterator<Item = PatchLoc<R>> + 'a
Return an iterator through all defined relocations targetting local label name.
These relocations are removed from the registry.
pub fn take_globals<'a>(
&'a mut self
) -> impl Iterator<Item = (PatchLoc<R>, &'static str)> + 'a[src]
&'a mut self
) -> impl Iterator<Item = (PatchLoc<R>, &'static str)> + 'a
Return an iterator through all defined relocations targeting global labels and the labels they target. These relocations are removed from the registry.
pub fn take_dynamics<'a>(
&'a mut self
) -> impl Iterator<Item = (PatchLoc<R>, DynamicLabel)> + 'a[src]
&'a mut self
) -> impl Iterator<Item = (PatchLoc<R>, DynamicLabel)> + 'a
Return an iterator through all defined relocations targeting dynamic labels and the labels they target. These relocations are removed from the registry.
pub fn take_locals<'a>(
&'a mut self
) -> impl Iterator<Item = (PatchLoc<R>, &'static str)> + 'a[src]
&'a mut self
) -> impl Iterator<Item = (PatchLoc<R>, &'static str)> + 'a
Return an iterator through all defined relocations targeting local labels and the labels they target. These relocations are removed from the registry.
Trait Implementations
impl<R: Debug + Relocation> Debug for RelocRegistry<R>[src]
impl<R: Default + Relocation> Default for RelocRegistry<R>[src]
fn default() -> RelocRegistry<R>[src]
Auto Trait Implementations
impl<R> RefUnwindSafe for RelocRegistry<R> where
R: RefUnwindSafe,
R: RefUnwindSafe,
impl<R> Send for RelocRegistry<R> where
R: Send,
R: Send,
impl<R> Sync for RelocRegistry<R> where
R: Sync,
R: Sync,
impl<R> Unpin for RelocRegistry<R> where
R: Unpin,
R: Unpin,
impl<R> UnwindSafe for RelocRegistry<R> where
R: UnwindSafe,
R: UnwindSafe,
Blanket Implementations
impl<T> Any for T where
T: 'static + ?Sized, [src]
T: 'static + ?Sized,
impl<T> Borrow<T> for T where
T: ?Sized, [src]
T: ?Sized,
impl<T> BorrowMut<T> for T where
T: ?Sized, [src]
T: ?Sized,
fn borrow_mut(&mut self) -> &mut T[src]
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>,