Enum rustc_middle::mir::AssertKind [−][src]
pub enum AssertKind<O> {
BoundsCheck {
len: O,
index: O,
},
Overflow(BinOp, O, O),
OverflowNeg(O),
DivisionByZero(O),
RemainderByZero(O),
ResumedAfterReturn(GeneratorKind),
ResumedAfterPanic(GeneratorKind),
}Expand description
Information about an assertion failure.
Variants
Overflow(BinOp, O, O)ResumedAfterReturn(GeneratorKind)ResumedAfterPanic(GeneratorKind)Implementations
impl<O> AssertKind<O>[src]
impl<O> AssertKind<O>[src]pub fn description(&self) -> &'static str[src]
pub fn description(&self) -> &'static str[src]Getting a description does not require O to be printable, and does not
require allocation.
The caller is expected to handle BoundsCheck separately.
Trait Implementations
impl<O: Clone> Clone for AssertKind<O>[src]
impl<O: Clone> Clone for AssertKind<O>[src]fn clone(&self) -> AssertKind<O>[src]
fn clone(&self) -> AssertKind<O>[src]Returns a copy of the value. Read more
fn clone_from(&mut self, source: &Self)1.0.0[src]
fn clone_from(&mut self, source: &Self)1.0.0[src]Performs copy-assignment from source. Read more
impl<O: Debug> Debug for AssertKind<O>[src]
impl<O: Debug> Debug for AssertKind<O>[src]impl<'tcx, O, __D: TyDecoder<'tcx>> Decodable<__D> for AssertKind<O> where
O: Decodable<__D>, [src]
impl<'tcx, O, __D: TyDecoder<'tcx>> Decodable<__D> for AssertKind<O> where
O: Decodable<__D>, [src]impl<'tcx, O, __E: TyEncoder<'tcx>> Encodable<__E> for AssertKind<O> where
O: Encodable<__E>, [src]
impl<'tcx, O, __E: TyEncoder<'tcx>> Encodable<__E> for AssertKind<O> where
O: Encodable<__E>, [src]impl<O: Hash> Hash for AssertKind<O>[src]
impl<O: Hash> Hash for AssertKind<O>[src]impl<'__ctx, O> HashStable<StableHashingContext<'__ctx>> for AssertKind<O> where
O: HashStable<StableHashingContext<'__ctx>>, [src]
impl<'__ctx, O> HashStable<StableHashingContext<'__ctx>> for AssertKind<O> where
O: HashStable<StableHashingContext<'__ctx>>, [src]fn hash_stable(
&self,
__hcx: &mut StableHashingContext<'__ctx>,
__hasher: &mut StableHasher
)[src]
&self,
__hcx: &mut StableHashingContext<'__ctx>,
__hasher: &mut StableHasher
)
impl<O: PartialEq> PartialEq<AssertKind<O>> for AssertKind<O>[src]
impl<O: PartialEq> PartialEq<AssertKind<O>> for AssertKind<O>[src]fn eq(&self, other: &AssertKind<O>) -> bool[src]
fn eq(&self, other: &AssertKind<O>) -> bool[src]This method tests for self and other values to be equal, and is used
by ==. Read more
fn ne(&self, other: &AssertKind<O>) -> bool[src]
fn ne(&self, other: &AssertKind<O>) -> bool[src]This method tests for !=.
impl<O: PartialOrd> PartialOrd<AssertKind<O>> for AssertKind<O>[src]
impl<O: PartialOrd> PartialOrd<AssertKind<O>> for AssertKind<O>[src]fn partial_cmp(&self, other: &AssertKind<O>) -> Option<Ordering>[src]
fn partial_cmp(&self, other: &AssertKind<O>) -> Option<Ordering>[src]This method returns an ordering between self and other values if one exists. Read more
#[must_use]fn lt(&self, other: &Rhs) -> bool1.0.0[src]
#[must_use]fn lt(&self, other: &Rhs) -> bool1.0.0[src]This method tests less than (for self and other) and is used by the < operator. Read more
#[must_use]fn le(&self, other: &Rhs) -> bool1.0.0[src]
#[must_use]fn le(&self, other: &Rhs) -> bool1.0.0[src]This method tests less than or equal to (for self and other) and is used by the <=
operator. Read more
impl<O> StructuralPartialEq for AssertKind<O>[src]
Auto Trait Implementations
impl<O> RefUnwindSafe for AssertKind<O> where
O: RefUnwindSafe,
O: RefUnwindSafe,
impl<O> Send for AssertKind<O> where
O: Send,
O: Send,
impl<O> Sync for AssertKind<O> where
O: Sync,
O: Sync,
impl<O> Unpin for AssertKind<O> where
O: Unpin,
O: Unpin,
impl<O> UnwindSafe for AssertKind<O> where
O: UnwindSafe,
O: UnwindSafe,
Blanket Implementations
impl<T> BorrowMut<T> for T where
T: ?Sized, [src]
impl<T> BorrowMut<T> for T where
T: ?Sized, [src]pub fn borrow_mut(&mut self) -> &mut T[src]
pub fn borrow_mut(&mut self) -> &mut T[src]Mutably borrows from an owned value. Read more
impl<T> MaybeResult<T> for T[src]
impl<T> MaybeResult<T> for T[src]impl<T> ToOwned for T where
T: Clone, [src]
impl<T> ToOwned for T where
T: Clone, [src]type Owned = T
type Owned = TThe resulting type after obtaining ownership.
pub fn to_owned(&self) -> T[src]
pub fn to_owned(&self) -> T[src]Creates owned data from borrowed data, usually by cloning. Read more
pub fn clone_into(&self, target: &mut T)[src]
pub fn clone_into(&self, target: &mut T)[src]🔬 This is a nightly-only experimental API. (toowned_clone_into)
recently added
Uses borrowed data to replace owned data, usually by cloning. Read more
impl<T> WithConstness for T[src]
impl<T> WithConstness for T[src]fn with_constness(self, constness: Constness) -> ConstnessAnd<Self>[src]
fn with_const(self) -> ConstnessAnd<Self>[src]
fn without_const(self) -> ConstnessAnd<Self>[src]
impl<'a, T> Captures<'a> for T where
T: ?Sized, [src]
T: ?Sized,