Struct rustc_middle::mir::coverage::ExpressionOperandId[][src]

pub struct ExpressionOperandId {
    private: u32,

An ExpressionOperandId value is assigned directly from either a CounterValueReference.as_u32() (which ascend from 1) or an ExpressionOperandId.as_u32() (which descend from u32::MAX). Id value 0 (zero) represents a virtual counter with a constant value of 0.


private: u32


impl ExpressionOperandId[src]

pub const MAX_AS_U32: u32[src]

pub const MAX: Self[src]

pub const fn from_usize(value: usize) -> Self[src]

pub const fn from_u32(value: u32) -> Self[src]

pub const unsafe fn from_u32_unchecked(value: u32) -> Self[src]

pub const fn index(self) -> usize[src]

Extracts the value of this index as an integer.

pub const fn as_u32(self) -> u32[src]

Extracts the value of this index as a u32.

pub const fn as_usize(self) -> usize[src]

Extracts the value of this index as a usize.

impl ExpressionOperandId[src]

pub const ZERO: Self[src]

An expression operand for a “zero counter”, as described in the following references:

This operand can be used to count two or more separate code regions with a single counter, if they run sequentially with no branches, by injecting the Counter in a BasicBlock for one of the code regions, and inserting CounterExpressions (“add ZERO to the counter”) in the coverage map for the other code regions.

Trait Implementations

impl Add<usize> for ExpressionOperandId[src]

type Output = Self

The resulting type after applying the + operator.

impl Clone for ExpressionOperandId[src]

impl Copy for ExpressionOperandId[src]

impl Debug for ExpressionOperandId[src]

impl<D: Decoder> Decodable<D> for ExpressionOperandId[src]

impl<E: Encoder> Encodable<E> for ExpressionOperandId[src]

impl Eq for ExpressionOperandId[src]

impl From<CounterValueReference> for ExpressionOperandId[src]

impl From<InjectedExpressionId> for ExpressionOperandId[src]

impl From<u32> for ExpressionOperandId[src]

impl From<usize> for ExpressionOperandId[src]

impl Hash for ExpressionOperandId[src]

impl<'__ctx> HashStable<StableHashingContext<'__ctx>> for ExpressionOperandId[src]

impl Idx for ExpressionOperandId[src]

impl<'tcx> Lift<'tcx> for ExpressionOperandId[src]

type Lifted = Self

impl Ord for ExpressionOperandId[src]

impl PartialEq<ExpressionOperandId> for ExpressionOperandId[src]

impl PartialOrd<ExpressionOperandId> for ExpressionOperandId[src]

impl Step for ExpressionOperandId[src]

impl StructuralEq for ExpressionOperandId[src]

impl StructuralPartialEq for ExpressionOperandId[src]

impl<'tcx> TypeFoldable<'tcx> for ExpressionOperandId[src]

Auto Trait Implementations

impl RefUnwindSafe for ExpressionOperandId

impl Send for ExpressionOperandId

impl Sync for ExpressionOperandId

impl Unpin for ExpressionOperandId

impl UnwindSafe for ExpressionOperandId

Blanket Implementations

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

impl<'tcx, T> ArenaAllocatable<'tcx, ()> for T where
    T: Copy

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<'tcx, T> Subst<'tcx> for T where
    T: TypeFoldable<'tcx>, 

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]