[−][src]Struct rustc_mir::transform::instrument_coverage::Instrumentor
Fields
tcx: TyCtxt<'tcx>mir_def_id: DefIdmir_body: &'a mut Body<'tcx>hir_body: &'tcx Body<'tcx>function_source_hash: Option<u64>num_counters: u32num_expressions: u32Implementations
impl<'a, 'tcx> Instrumentor<'a, 'tcx>[src]
fn new(
tcx: TyCtxt<'tcx>,
src: MirSource<'tcx>,
mir_body: &'a mut Body<'tcx>
) -> Self[src]
tcx: TyCtxt<'tcx>,
src: MirSource<'tcx>,
mir_body: &'a mut Body<'tcx>
) -> Self
fn next_counter(&mut self) -> CounterValueReference[src]
Counter IDs start from zero and go up.
fn next_expression(&mut self) -> InjectedExpressionIndex[src]
Expression IDs start from u32::MAX and go down because a CounterExpression can reference (add or subtract counts) of both Counter regions and CounterExpression regions. The counter expression operand IDs must be unique across both types.
fn function_source_hash(&mut self) -> u64[src]
fn inject_counters(&mut self)[src]
fn make_counter(&mut self) -> CoverageKind[src]
fn make_expression(
&mut self,
lhs: ExpressionOperandId,
op: Op,
rhs: ExpressionOperandId
) -> CoverageKind[src]
&mut self,
lhs: ExpressionOperandId,
op: Op,
rhs: ExpressionOperandId
) -> CoverageKind
fn inject_statement(
&mut self,
coverage_kind: CoverageKind,
span: Span,
block: BasicBlock
)[src]
&mut self,
coverage_kind: CoverageKind,
span: Span,
block: BasicBlock
)
Auto Trait Implementations
impl<'a, 'tcx> !RefUnwindSafe for Instrumentor<'a, 'tcx>
impl<'a, 'tcx> !Send for Instrumentor<'a, 'tcx>
impl<'a, 'tcx> !Sync for Instrumentor<'a, 'tcx>
impl<'a, 'tcx> Unpin for Instrumentor<'a, 'tcx> where
'tcx: 'a,
'tcx: 'a,
impl<'a, 'tcx> !UnwindSafe for Instrumentor<'a, 'tcx>
Blanket Implementations
impl<T> Any for T where
T: 'static + ?Sized, [src]
T: 'static + ?Sized,
impl<T> Borrow<T> for T where
T: ?Sized, [src]
T: ?Sized,
impl<T> BorrowMut<T> for T where
T: ?Sized, [src]
T: ?Sized,
fn borrow_mut(&mut self) -> &mut T[src]
impl<T> From<T> for T[src]
impl<T, U> Into<U> for T where
U: From<T>, [src]
U: From<T>,
impl<T, U> TryFrom<U> for T where
U: Into<T>, [src]
U: Into<T>,
type Error = Infallible
The type returned in the event of a conversion error.
fn try_from(value: U) -> Result<T, <T as TryFrom<U>>::Error>[src]
impl<T, U> TryInto<U> for T where
U: TryFrom<T>, [src]
U: TryFrom<T>,
type Error = <U as TryFrom<T>>::Error
The type returned in the event of a conversion error.