[−][src]Struct rustc_mir_build::build::scope::Scopes

pub struct Scopes<'tcx> {
    scopes: Vec<Scope>,
    breakable_scopes: Vec<BreakableScope<'tcx>>,
    unwind_drops: DropTree,
    generator_drops: DropTree,
}

Fields

scopes: Vec<Scope>breakable_scopes: Vec<BreakableScope<'tcx>>

The current set of breakable scopes. See module comment for more details.

unwind_drops: DropTree

Drops that need to be done on unwind paths. See the comment on DropTree for more details.

generator_drops: DropTree

Drops that need to be done on paths to the GeneratorDrop terminator.

Implementations

impl<'tcx> Scopes<'tcx>[src]

pub(crate) fn new() -> Self[src]

pub(in build::scope) fn push_scope(
    &mut self,
    region_scope: (Scope, SourceInfo),
    vis_scope: SourceScope
)
[src]

pub(in build::scope) fn pop_scope(
    &mut self,
    region_scope: (Scope, SourceInfo)
) -> Scope
[src]

pub(in build::scope) fn scope_index(
    &self,
    region_scope: Scope,
    span: Span
) -> usize
[src]

pub(in build::scope) fn topmost(
    &self
) -> Scope
[src]

Returns the topmost active scope, which is known to be alive until the next scope expression.

Trait Implementations

impl<'tcx> Debug for Scopes<'tcx>[src]

Auto Trait Implementations

impl<'tcx> !RefUnwindSafe for Scopes<'tcx>

impl<'tcx> !Send for Scopes<'tcx>

impl<'tcx> !Sync for Scopes<'tcx>

impl<'tcx> Unpin for Scopes<'tcx>

impl<'tcx> !UnwindSafe for Scopes<'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<'a, T> Captures<'a> 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.