pub struct RegisterStateRef<'a>(/* private fields */);Expand description
A reference to the register state saved when an exception happened.
Implementations§
Source§impl RegisterStateRef<'_>
impl RegisterStateRef<'_>
Sourcepub unsafe fn get_mut(&mut self) -> &mut RegisterState
pub unsafe fn get_mut(&mut self) -> &mut RegisterState
Returns a mutable reference to the register state.
§Safety
Any changes made to the saved register state made via this reference must not cause undefined behaviour when returning from the exception.
Exactly what this means depends on the exception and the context in which it happened, but for example changing the ELR to point to an invalid or unexpected location, or changing some general-purpose register value which the code doesn’t expect to change could cause undefined behaviour.
Trait Implementations§
Source§impl AsRef<RegisterState> for RegisterStateRef<'_>
impl AsRef<RegisterState> for RegisterStateRef<'_>
Source§fn as_ref(&self) -> &RegisterState
fn as_ref(&self) -> &RegisterState
Converts this type into a shared reference of the (usually inferred) input type.
Source§impl Borrow<RegisterState> for RegisterStateRef<'_>
impl Borrow<RegisterState> for RegisterStateRef<'_>
Source§fn borrow(&self) -> &RegisterState
fn borrow(&self) -> &RegisterState
Immutably borrows from an owned value. Read more
Source§impl<'a> Debug for RegisterStateRef<'a>
impl<'a> Debug for RegisterStateRef<'a>
Source§impl Deref for RegisterStateRef<'_>
impl Deref for RegisterStateRef<'_>
Source§impl<'a> PartialEq for RegisterStateRef<'a>
impl<'a> PartialEq for RegisterStateRef<'a>
impl<'a> Eq for RegisterStateRef<'a>
impl<'a> StructuralPartialEq for RegisterStateRef<'a>
Auto Trait Implementations§
impl<'a> Freeze for RegisterStateRef<'a>
impl<'a> RefUnwindSafe for RegisterStateRef<'a>
impl<'a> Send for RegisterStateRef<'a>
impl<'a> Sync for RegisterStateRef<'a>
impl<'a> Unpin for RegisterStateRef<'a>
impl<'a> !UnwindSafe for RegisterStateRef<'a>
Blanket Implementations§
§impl<T> BorrowMut<T> for Twhere
T: ?Sized,
impl<T> BorrowMut<T> for Twhere
T: ?Sized,
§fn borrow_mut(&mut self) -> &mut T
fn borrow_mut(&mut self) -> &mut T
Mutably borrows from an owned value. Read more