pub struct BreakpointEdit<'a> { /* private fields */ }Available on crate feature
debug only.Expand description
A breakpoint-editing session.
This enables updating breakpoint state (setting or unsetting individual breakpoints or the store-global single-step flag) in a batch. It is more efficient to batch these updates because “re-publishing” the newly patched code, with update breakpoint settings, typically requires a syscall to re-enable execute permissions.
Implementations§
Source§impl<'a> BreakpointEdit<'a>
impl<'a> BreakpointEdit<'a>
Sourcepub fn add_breakpoint(&mut self, module: &Module, pc: u32) -> Result<()>
Available on crate feature runtime only.
pub fn add_breakpoint(&mut self, module: &Module, pc: u32) -> Result<()>
runtime only.Add a breakpoint in the given module at the given PC in that module.
No effect if the breakpoint is already set.
Sourcepub fn remove_breakpoint(&mut self, module: &Module, pc: u32) -> Result<()>
Available on crate feature runtime only.
pub fn remove_breakpoint(&mut self, module: &Module, pc: u32) -> Result<()>
runtime only.Remove a breakpoint in the given module at the given PC in that module.
No effect if the breakpoint was not set.
Sourcepub fn single_step(&mut self, enabled: bool) -> Result<()>
Available on crate feature runtime only.
pub fn single_step(&mut self, enabled: bool) -> Result<()>
runtime only.Turn on or off single-step mode.
In single-step mode, a breakpoint event is emitted at every Wasm PC.
Trait Implementations§
Auto Trait Implementations§
impl<'a> Freeze for BreakpointEdit<'a>
impl<'a> !RefUnwindSafe for BreakpointEdit<'a>
impl<'a> Send for BreakpointEdit<'a>
impl<'a> Sync for BreakpointEdit<'a>
impl<'a> Unpin for BreakpointEdit<'a>
impl<'a> !UnwindSafe for BreakpointEdit<'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
Source§impl<T> IntoEither for T
impl<T> IntoEither for T
Source§fn into_either(self, into_left: bool) -> Either<Self, Self> ⓘ
fn into_either(self, into_left: bool) -> Either<Self, Self> ⓘ
Converts
self into a Left variant of Either<Self, Self>
if into_left is true.
Converts self into a Right variant of Either<Self, Self>
otherwise. Read moreSource§fn into_either_with<F>(self, into_left: F) -> Either<Self, Self> ⓘ
fn into_either_with<F>(self, into_left: F) -> Either<Self, Self> ⓘ
Converts
self into a Left variant of Either<Self, Self>
if into_left(&self) returns true.
Converts self into a Right variant of Either<Self, Self>
otherwise. Read more