Trace

Struct Trace 

Source
pub struct Trace<T: Disassemble + Clone>(/* private fields */);
Expand description

A wrapper which writes to stdout

Trait Implementations§

Source§

impl<Insn, S: BruteforceSearch<Insn> + Clone + Disassemble> BruteforceSearch<Insn> for Trace<S>

Source§

fn analyze_this(&self) -> Result<(), StaticAnalysis<Insn>>

Optionally return a StaticAnalysis if a code sequence is found to be problematic or in some way suboptimal.
Source§

fn inner(&mut self) -> &mut dyn BruteforceSearch<Insn>

Since client code can arbitrarily chain these passes together, return the next node in the “linked list”.
Source§

fn step(&mut self)

Step through the search space. Apply any static analysis results.
Source§

fn analyze(&mut self) -> Result<(), StaticAnalysis<Insn>>

Returns either this pass’s StaticAnalysis<Insn> or the inner’s
Source§

fn apply(&mut self, static_analysis: &StaticAnalysis<Insn>)

Applies a StaticAnalysis, which means fixing whatever problem the StaticAnalysis represents.
Source§

fn fixup(&mut self)

Applies all StaticAnalysis instances.
Source§

impl<InputParameters, ReturnType, T: Callable<InputParameters, ReturnType> + Clone + Disassemble> Callable<InputParameters, ReturnType> for Trace<T>

Source§

fn call(&self, parameters: InputParameters) -> RunResult<ReturnType>

Calls the given callable object
Source§

impl<T: Clone + Disassemble + Clone> Clone for Trace<T>

Source§

fn clone(&self) -> Trace<T>

Returns a duplicate of the value. Read more
1.0.0 · Source§

fn clone_from(&mut self, source: &Self)

Performs copy-assignment from source. Read more
Source§

impl<T: Debug + Disassemble + Clone> Debug for Trace<T>

Source§

fn fmt(&self, f: &mut Formatter<'_>) -> Result

Formats the value using the given formatter. Read more
Source§

impl<T: Disassemble + Clone> Disassemble for Trace<T>

Source§

fn dasm(&self)

Disassemble to stdout
Source§

impl<T: Step + Clone + Disassemble> Step for Trace<T>

Source§

fn next(&mut self) -> IterationResult

Advances the value to the next state. Returns Ok(()) if the step was successful. Returns Err(StepError::End) if the end has been reached.
Source§

fn first() -> Self

Returns the first value

Auto Trait Implementations§

§

impl<T> Freeze for Trace<T>
where T: Freeze,

§

impl<T> RefUnwindSafe for Trace<T>
where T: RefUnwindSafe,

§

impl<T> Send for Trace<T>
where T: Send,

§

impl<T> Sync for Trace<T>
where T: Sync,

§

impl<T> Unpin for Trace<T>
where T: Unpin,

§

impl<T> UnwindSafe for Trace<T>
where T: UnwindSafe,

Blanket Implementations§

Source§

impl<T> Any for T
where T: 'static + ?Sized,

Source§

fn type_id(&self) -> TypeId

Gets the TypeId of self. Read more
Source§

impl<T> Borrow<T> for T
where T: ?Sized,

Source§

fn borrow(&self) -> &T

Immutably borrows from an owned value. Read more
Source§

impl<T> BorrowMut<T> for T
where T: ?Sized,

Source§

fn borrow_mut(&mut self) -> &mut T

Mutably borrows from an owned value. Read more
Source§

impl<T> CloneToUninit for T
where T: Clone,

Source§

unsafe fn clone_to_uninit(&self, dest: *mut u8)

🔬This is a nightly-only experimental API. (clone_to_uninit)
Performs copy-assignment from self to dest. Read more
Source§

impl<T> From<T> for T

Source§

fn from(t: T) -> T

Returns the argument unchanged.

Source§

impl<T, U> Into<U> for T
where U: From<T>,

Source§

fn into(self) -> U

Calls U::from(self).

That is, this conversion is whatever the implementation of From<T> for U chooses to do.

Source§

impl<T> Same for T

Source§

type Output = T

Should always be Self
Source§

impl<Insn, T, InputParameters, ReturnValue, TargetFunction> ToBruteForce<Insn, InputParameters, ReturnValue, TargetFunction> for T
where T: Callable<InputParameters, ReturnValue> + BruteforceSearch<Insn> + Clone, ReturnValue: Clone + Vals, TargetFunction: Callable<InputParameters, ReturnValue>, InputParameters: Vals,

Source§

fn to_bruteforce( self, target_function: TargetFunction, ) -> BruteForce<Insn, InputParameters, ReturnValue, TargetFunction, T>

Return a BruteForce
Source§

impl<T> ToOwned for T
where T: Clone,

Source§

type Owned = T

The resulting type after obtaining ownership.
Source§

fn to_owned(&self) -> T

Creates owned data from borrowed data, usually by cloning. Read more
Source§

fn clone_into(&self, target: &mut T)

Uses borrowed data to replace owned data, usually by cloning. Read more
Source§

impl<T> ToTrace for T

Source§

fn trace(self) -> Trace<Self>
where Self: Sized + Clone + Disassemble,

Wraps an object up in a Trace, so that each mutation is printed to stdout.
Source§

impl<T, U> TryFrom<U> for T
where U: Into<T>,

Source§

type Error = Infallible

The type returned in the event of a conversion error.
Source§

fn try_from(value: U) -> Result<T, <T as TryFrom<U>>::Error>

Performs the conversion.
Source§

impl<T, U> TryInto<U> for T
where U: TryFrom<T>,

Source§

type Error = <U as TryFrom<T>>::Error

The type returned in the event of a conversion error.
Source§

fn try_into(self) -> Result<U, <U as TryFrom<T>>::Error>

Performs the conversion.
Source§

impl<V, T> VZip<V> for T
where V: MultiLane<T>,

Source§

fn vzip(self) -> V