Struct rustc_trans::middle::ty_fold::RegionFolderExperimental [-]  [+] [src]

pub struct RegionFolder<'a, 'tcx> {
    // some fields omitted
}

Folds over the substructure of a type, visiting its component types and all regions that occur free within it.

That is, ty::t can contain function or method types that bind regions at the call site (ReLateBound), and occurrences of regions (aka "lifetimes") that are bound within a type are not visited by this folder; only regions that occur free will be visited by fld_r.

(The distinction between "free" and "bound" is represented by keeping track of each FnSig in the lexical context of the current position of the fold.)

Methods

impl<'a, 'tcx> RegionFolder<'a, 'tcx>

fn new(tcx: &'a ctxt<'tcx>, fld_r: |Region, uint| -> Region) -> RegionFolder<'a, 'tcx>

Trait Implementations

impl<'a, 'tcx> TypeFolder<'tcx> for RegionFolder<'a, 'tcx>

fn tcx(&'a self) -> &'a ctxt<'tcx>

fn enter_region_binder(&mut self)

fn exit_region_binder(&mut self)

fn fold_region(&mut self, r: Region) -> Region

fn enter_region_binder(&mut self)

fn exit_region_binder(&mut self)

fn fold_ty(&mut self, t) -> t

fn fold_mt(&mut self, &mt) -> mt

fn fold_trait_ref(&mut self, &TraitRef) -> TraitRef

fn fold_sty(&mut self, &sty) -> sty

fn fold_substs(&mut self, &Substs) -> Substs

fn fold_fn_sig(&mut self, &FnSig) -> FnSig

fn fold_output(&mut self, &FnOutput) -> FnOutput

fn fold_bare_fn_ty(&mut self, &BareFnTy) -> BareFnTy

fn fold_closure_ty(&mut self, &ClosureTy) -> ClosureTy

fn fold_region(&mut self, Region) -> Region

fn fold_trait_store(&mut self, TraitStore) -> TraitStore

fn fold_existential_bounds(&mut self, ExistentialBounds) -> ExistentialBounds

fn fold_autoref(&mut self, &AutoRef) -> AutoRef

fn fold_item_substs(&mut self, ItemSubsts) -> ItemSubsts

fn fold_obligation(&mut self, &Obligation) -> Obligation