pub enum PanicState {
EndsWithPanic(Vec<PanicLocation>),
Otherwise,
}
Expand description
A state saved for each position in the back analysis. Used to determine if a Panic object is guaranteed to exist or be created, an where.
Variants§
EndsWithPanic(Vec<PanicLocation>)
The flow will end with a panic. The locations are all the possible places a Panic object can be created from this flow. The flow is guaranteed to end up in one of these places.
Otherwise
Trait Implementations§
Source§impl AuxCombine for PanicState
impl AuxCombine for PanicState
How to combine two panic states in a flow divergence.
Source§impl Clone for PanicState
impl Clone for PanicState
Source§fn clone(&self) -> PanicState
fn clone(&self) -> PanicState
Returns a copy of the value. Read more
1.0.0 · Source§fn clone_from(&mut self, source: &Self)
fn clone_from(&mut self, source: &Self)
Performs copy-assignment from
source
. Read moreSource§impl Default for PanicState
impl Default for PanicState
Source§fn default() -> PanicState
fn default() -> PanicState
Returns the “default value” for a type. Read more
Source§impl DemandReporter<Id<Variable>, PanicState> for DestructAdder<'_>
impl DemandReporter<Id<Variable>, PanicState> for DestructAdder<'_>
type IntroducePosition = (BlockId, usize)
type UsePosition = ()
fn drop_aux( &mut self, position: StatementLocation, var_id: VariableId, panic_state: PanicState, )
fn drop(&mut self, _position: Self::IntroducePosition, _var: Var)
fn dup( &mut self, _position: Self::UsePosition, _var: Var, _next_usage_position: Self::UsePosition, )
fn last_use(&mut self, _position: Self::UsePosition, _var: Var)
fn unused_mapped_var(&mut self, _var: Var)
Auto Trait Implementations§
impl Freeze for PanicState
impl RefUnwindSafe for PanicState
impl Send for PanicState
impl Sync for PanicState
impl Unpin for PanicState
impl UnwindSafe for PanicState
Blanket Implementations§
Source§impl<T> BorrowMut<T> for Twhere
T: ?Sized,
impl<T> BorrowMut<T> for Twhere
T: ?Sized,
Source§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> CloneToUninit for Twhere
T: Clone,
impl<T> CloneToUninit for Twhere
T: Clone,
Source§impl<T> Instrument for T
impl<T> Instrument for T
Source§fn instrument(self, span: Span) -> Instrumented<Self>
fn instrument(self, span: Span) -> Instrumented<Self>
Source§fn in_current_span(self) -> Instrumented<Self>
fn in_current_span(self) -> Instrumented<Self>
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