[−][src]Struct rustc_passes::stability::Annotator

pub(in stability) struct Annotator<'a, 'tcx> {
    tcx: TyCtxt<'tcx>,
    index: &'a mut Index<'tcx>,
    parent_stab: Option<&'tcx Stability>,
    parent_const_stab: Option<&'tcx ConstStability>,
    parent_depr: Option<DeprecationEntry>,
    in_trait_impl: bool,
}

Fields

tcx: TyCtxt<'tcx>index: &'a mut Index<'tcx>parent_stab: Option<&'tcx Stability>parent_const_stab: Option<&'tcx ConstStability>parent_depr: Option<DeprecationEntry>in_trait_impl: bool

Implementations

impl<'a, 'tcx> Annotator<'a, 'tcx>[src]

pub(in stability) fn annotate<F>(
    &mut self,
    hir_id: HirId,
    attrs: &[Attribute],
    item_sp: Span,
    kind: AnnotationKind,
    inherit_deprecation: InheritDeprecation,
    visit_children: F
) where
    F: FnOnce(&mut Self), 
[src]

pub(in stability) fn recurse_with_stability_attrs(
    &mut self,
    depr: Option<DeprecationEntry>,
    stab: Option<&'tcx Stability>,
    const_stab: Option<&'tcx ConstStability>,
    f: impl FnOnce(&mut Self)
)
[src]

pub(in stability) fn forbid_staged_api_attrs(
    &mut self,
    hir_id: HirId,
    attrs: &[Attribute],
    inherit_deprecation: InheritDeprecation
) -> bool
[src]

Trait Implementations

impl<'a, 'tcx> Visitor<'tcx> for Annotator<'a, 'tcx>[src]

type Map = Map<'tcx>

Because stability levels are scoped lexically, we want to walk nested items in the context of the outer item, so enable deep-walking.

Auto Trait Implementations

impl<'a, 'tcx> !RefUnwindSafe for Annotator<'a, 'tcx>

impl<'a, 'tcx> !Send for Annotator<'a, 'tcx>

impl<'a, 'tcx> !Sync for Annotator<'a, 'tcx>

impl<'a, 'tcx> Unpin for Annotator<'a, 'tcx> where
    'tcx: 'a, 

impl<'a, 'tcx> !UnwindSafe for Annotator<'a, 'tcx>

Blanket Implementations

impl<T> Any for T where
    T: 'static + ?Sized, 
[src]

impl<T> Borrow<T> for T where
    T: ?Sized, 
[src]

impl<T> BorrowMut<T> for T where
    T: ?Sized, 
[src]

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

impl<T, U> Into<U> for T where
    U: From<T>, 
[src]

impl<T, U> TryFrom<U> for T where
    U: Into<T>, 
[src]

type Error = Infallible

The type returned in the event of a conversion error.

impl<T, U> TryInto<U> for T where
    U: TryFrom<T>, 
[src]

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

The type returned in the event of a conversion error.