Skip to main content

EffectReplayState

Struct EffectReplayState 

Source
pub struct EffectReplayState { /* private fields */ }

Implementations§

Source§

impl EffectReplayState

Source

pub fn mode(&self) -> EffectReplayMode

Source

pub fn set_normal(&mut self)

Source

pub fn start_recording(&mut self)

Source

pub fn set_record_cap(&mut self, cap: Option<usize>)

Source

pub fn record_full(&self) -> bool

Source

pub fn start_replay(&mut self, effects: Vec<EffectRecord>, validate_args: bool)

Source

pub fn take_recorded_effects(&mut self) -> Vec<EffectRecord>

Source

pub fn recorded_effects(&self) -> &[EffectRecord]

Source

pub fn replay_progress(&self) -> (usize, usize)

Source

pub fn args_diff_count(&self) -> usize

Source

pub fn ensure_replay_consumed(&self) -> Result<(), ReplayFailure>

Source

pub fn reset_scope(&mut self)

Oracle v1: reset the structural-scope counters (next_group_id, group_stack, branch_stack, effect_count_stack) without touching recorded effects or replay state. Used by the verify- trace runner so each case starts at group id 1 — otherwise the counter accumulates across cases and user-visible indices like .trace.group(0) stop matching after the first case.

Source

pub fn enter_group(&mut self) -> u32

Enter an independent product group for recording. Returns the group id.

Source

pub fn exit_group(&mut self)

Exit the current independent product group.

Source

pub fn current_group_id(&self) -> Option<u32>

Oracle v1: id of the innermost !/?! group currently being evaluated, as assigned by enter_group (monotonic per run, starts at 1). None when outside any group — i.e. sequential code.

Source

pub fn current_branch_idx(&self) -> Option<u32>

Oracle v1: index of the current branch within the innermost group. None at the sequential level. Ordinal: first branch of a !/?! group is 0 (set by enter_group), bumped by set_branch.

Source

pub fn set_branch(&mut self, index: u32)

Set the current branch index within the current (innermost) product.

Source

pub fn record_effect( &mut self, effect_type: &str, args: Vec<JsonValue>, outcome: RecordedOutcome, caller_fn: &str, source_line: usize, )

Source

pub fn replay_effect( &mut self, effect_type: &str, got_args: Option<Vec<JsonValue>>, ) -> Result<RecordedOutcome, ReplayFailure>

Source

pub fn oracle_path_string(&self) -> String

Oracle v1: dewey-decimal path string for the current branch context. Empty string if we’re outside any group.

Source

pub fn oracle_branch_counter(&self) -> Option<u32>

Oracle v1: current per-branch effect-occurrence counter, or None if outside any group (caller should use a VM-level root counter).

Source

pub fn bump_oracle_branch_counter(&mut self)

Oracle v1: bump the current per-branch counter (no-op outside any group — caller tracks the root counter separately).

Source

pub fn is_inside_group(&self) -> bool

Oracle v1: is the runtime currently inside at least one !/?! group?

Trait Implementations§

Source§

impl Clone for EffectReplayState

Source§

fn clone(&self) -> EffectReplayState

Returns a duplicate of the value. Read more
1.0.0 (const: unstable) · Source§

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

Performs copy-assignment from source. Read more
Source§

impl Debug for EffectReplayState

Source§

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

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

impl Default for EffectReplayState

Source§

fn default() -> EffectReplayState

Returns the “default value” for a type. Read more

Auto Trait Implementations§

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> 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, 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