Enum rustc_middle::mir::AssertKind[][src]

pub enum AssertKind<O> {
    BoundsCheck {
        len: O,
        index: O,
    Overflow(BinOp, O, O),

Information about an assertion failure.



Fields of BoundsCheck

len: Oindex: O
Overflow(BinOp, O, O)


impl<O> AssertKind<O>[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.

fn fmt_assert_args<W: Write>(&self, f: &mut W) -> Result where
    O: Debug

Format the message arguments for the assert(cond, msg..) terminator in MIR printing.

Trait Implementations

impl<O: Clone> Clone 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>, 

impl<'tcx, O, __E: TyEncoder<'tcx>> Encodable<__E> for AssertKind<O> where
    O: Encodable<__E>, 

impl<O: Hash> Hash for AssertKind<O>[src]

impl<'__ctx, O> HashStable<StableHashingContext<'__ctx>> for AssertKind<O> where
    O: HashStable<StableHashingContext<'__ctx>>, 

impl<O: PartialEq> PartialEq<AssertKind<O>> for AssertKind<O>[src]

impl<O: PartialOrd> PartialOrd<AssertKind<O>> for AssertKind<O>[src]

impl<O> StructuralPartialEq for AssertKind<O>[src]

Auto Trait Implementations

impl<O> RefUnwindSafe for AssertKind<O> where
    O: RefUnwindSafe

impl<O> Send for AssertKind<O> where
    O: Send

impl<O> Sync for AssertKind<O> where
    O: Sync

impl<O> Unpin for AssertKind<O> where
    O: Unpin

impl<O> UnwindSafe for AssertKind<O> where
    O: UnwindSafe

Blanket Implementations

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

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

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

impl<'a, T> Captures<'a> for T where
    T: ?Sized

impl<T> From<T> for T[src]

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

impl<T> MaybeResult<T> for T[src]

type Error = !

impl<T> ToOwned for T where
    T: Clone

type Owned = T

The resulting type after obtaining ownership.

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

type Error = Infallible

The type returned in the event of a conversion error.

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

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

The type returned in the event of a conversion error.

impl<T> WithConstness for T[src]