Skip to main content

VerifyRun

Struct VerifyRun 

Source
pub struct VerifyRun<'tcx> {
    tcx: TyCtxt<'tcx>,
    repeat_strategy: RepeatStrategy,
    mode: VerifyMode,
    skip_invariant: bool,
    crate_filter: Option<String>,
    module_filter: Option<String>,
    debug_contracts: bool,
}
Expand description

Analysis pass that runs verification and emits function-level summaries.

Fields§

§tcx: TyCtxt<'tcx>§repeat_strategy: RepeatStrategy§mode: VerifyMode§skip_invariant: bool§crate_filter: Option<String>§module_filter: Option<String>§debug_contracts: bool

Implementations§

Source§

impl<'tcx> VerifyRun<'tcx>

Source

pub fn new( tcx: TyCtxt<'tcx>, repeat_strategy: RepeatStrategy, mode: VerifyMode, skip_invariant: bool, crate_filter: Option<String>, module_filter: Option<String>, debug_contracts: bool, ) -> Self

Create the default verify pass for the current compiler type context.

Source

fn repeat_rounds_for_target( &self, target: &FunctionTarget<'tcx>, ) -> (usize, Vec<usize>)

Source

fn run_invless_sequences(&self, targets: &[FunctionTarget<'tcx>])

With --skip-invariant, generate verification sequences for each read method that chain through constructors and mutators.

Produces sequences like:

  • constructor → method
  • constructor → mutator → method

Each sequence propagates the constructor’s #[rapx::requires] through the mutator chain to serve as entry assumptions for the read method.

Source

fn build_virtual_target( &self, read_target: &FunctionTarget<'tcx>, read_def_id: DefId, con_id: DefId, mut_ids: &[DefId], ) -> FunctionTarget<'tcx>

Source

fn verify_and_emit_sequence( &self, read_def_id: DefId, con_target: &FunctionTarget<'tcx>, con_id: DefId, mut_ids: &[DefId], )

Source§

impl<'tcx> VerifyRun<'tcx>

Source

fn print_contracts_debug(&self, targets: &[FunctionTarget<'tcx>])

Source

fn has_printable_contracts(&self, target: &FunctionTarget<'tcx>) -> bool

Source

fn print_contract_lines( &self, prefix: &str, branch: &str, call: &str, meaning: &str, )

Source

fn print_target_contracts( &self, target: &FunctionTarget<'tcx>, branch: &str, cont: &str, ) -> bool

Source

fn resolve_arg_names_with_types( &self, def_id: DefId, ) -> (Vec<String>, Option<String>)

Trait Implementations§

Source§

impl<'tcx> Analysis for VerifyRun<'tcx>

Source§

fn run(&mut self)

Collect verify targets, run the staged driver, and emit a compact summary.

For each target, extracts paths with increasing postfix-repeat levels from 0 to the configured maximum, running verification at each level. Earlier rounds use fewer loop unrollings; later rounds incrementally add deeper paths.

Auto Trait Implementations§

§

impl<'tcx> !RefUnwindSafe for VerifyRun<'tcx>

§

impl<'tcx> !Send for VerifyRun<'tcx>

§

impl<'tcx> !Sync for VerifyRun<'tcx>

§

impl<'tcx> !UnwindSafe for VerifyRun<'tcx>

§

impl<'tcx> DynSend for VerifyRun<'tcx>

§

impl<'tcx> DynSync for VerifyRun<'tcx>

§

impl<'tcx> Freeze for VerifyRun<'tcx>

§

impl<'tcx> Unpin for VerifyRun<'tcx>

§

impl<'tcx> UnsafeUnpin for VerifyRun<'tcx>

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
§

impl<ST, DT> CastableFrom<ST, Initialized, Initialized> for DT
where ST: ?Sized, DT: ?Sized,

§

impl<ST, DT> CastableFrom<ST, Uninit, Uninit> for DT
where ST: ?Sized, DT: ?Sized,

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> IntoEither for T

Source§

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 more
Source§

fn into_either_with<F>(self, into_left: F) -> Either<Self, Self>
where F: FnOnce(&Self) -> bool,

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
§

impl<T> Read<Exclusive, BecauseExclusive> for T
where T: ?Sized,

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.
§

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

§

fn vzip(self) -> V