Struct rustc_typeck::middle::ty::ctxtUnstable
[-]
[+]
[src]
pub struct ctxt<'tcx> {
pub types: CommonTypes<'tcx>,
pub sess: Session,
pub def_map: RefCell<HashMap<u32, Def, DefaultState<FnvHasher>>>,
pub named_region_map: HashMap<u32, DefRegion, DefaultState<FnvHasher>>,
pub region_maps: RegionMaps,
pub node_types: RefCell<HashMap<u32, &'tcx TyS<'tcx>, DefaultState<FnvHasher>>>,
pub item_substs: RefCell<HashMap<u32, ItemSubsts<'tcx>, DefaultState<FnvHasher>>>,
pub impl_or_trait_items: RefCell<HashMap<DefId, ImplOrTraitItem<'tcx>, DefaultState<FnvHasher>>>,
pub trait_item_def_ids: RefCell<HashMap<DefId, Rc<Vec<ImplOrTraitItemId>>, DefaultState<FnvHasher>>>,
pub trait_items_cache: RefCell<HashMap<DefId, Rc<Vec<ImplOrTraitItem<'tcx>>>, DefaultState<FnvHasher>>>,
pub impl_trait_cache: RefCell<HashMap<DefId, Option<Rc<TraitRef<'tcx>>>, DefaultState<FnvHasher>>>,
pub trait_refs: RefCell<HashMap<u32, Rc<TraitRef<'tcx>>, DefaultState<FnvHasher>>>,
pub trait_defs: RefCell<HashMap<DefId, Rc<TraitDef<'tcx>>, DefaultState<FnvHasher>>>,
pub object_cast_map: RefCell<HashMap<u32, Binder<Rc<TraitRef<'tcx>>>, DefaultState<FnvHasher>>>,
pub map: Map<'tcx>,
pub intrinsic_defs: RefCell<HashMap<DefId, &'tcx TyS<'tcx>, DefaultState<FnvHasher>>>,
pub freevars: RefCell<HashMap<u32, Vec<Freevar>, DefaultState<FnvHasher>>>,
pub tcache: RefCell<HashMap<DefId, TypeScheme<'tcx>, DefaultState<FnvHasher>>>,
pub rcache: RefCell<HashMap<creader_cache_key, &'tcx TyS<'tcx>, DefaultState<FnvHasher>>>,
pub short_names_cache: RefCell<HashMap<&'tcx TyS<'tcx>, String, DefaultState<FnvHasher>>>,
pub tc_cache: RefCell<HashMap<&'tcx TyS<'tcx>, TypeContents, DefaultState<FnvHasher>>>,
pub ast_ty_to_ty_cache: RefCell<HashMap<u32, ast_ty_to_ty_cache_entry<'tcx>, DefaultState<FnvHasher>>>,
pub enum_var_cache: RefCell<HashMap<DefId, Rc<Vec<Rc<VariantInfo<'tcx>>>>, DefaultState<FnvHasher>>>,
pub ty_param_defs: RefCell<HashMap<u32, TypeParameterDef<'tcx>, DefaultState<FnvHasher>>>,
pub adjustments: RefCell<HashMap<u32, AutoAdjustment<'tcx>, DefaultState<FnvHasher>>>,
pub normalized_cache: RefCell<HashMap<&'tcx TyS<'tcx>, &'tcx TyS<'tcx>, DefaultState<FnvHasher>>>,
pub lang_items: LanguageItems,
pub provided_method_sources: RefCell<HashMap<DefId, DefId, DefaultState<FnvHasher>>>,
pub struct_fields: RefCell<HashMap<DefId, Rc<Vec<field_ty>>, DefaultState<FnvHasher>>>,
pub item_variance_map: RefCell<HashMap<DefId, Rc<ItemVariances>, DefaultState<FnvHasher>>>,
pub variance_computed: Cell<bool>,
pub destructor_for_type: RefCell<HashMap<DefId, DefId, DefaultState<FnvHasher>>>,
pub destructors: RefCell<HashSet<DefId, DefaultState<FnvHasher>>>,
pub trait_impls: RefCell<HashMap<DefId, Rc<RefCell<Vec<DefId>>>, DefaultState<FnvHasher>>>,
pub inherent_impls: RefCell<HashMap<DefId, Rc<Vec<DefId>>, DefaultState<FnvHasher>>>,
pub impl_items: RefCell<HashMap<DefId, Vec<ImplOrTraitItemId>, DefaultState<FnvHasher>>>,
pub used_unsafe: RefCell<HashSet<u32, DefaultState<FnvHasher>>>,
pub used_mut_nodes: RefCell<HashSet<u32, DefaultState<FnvHasher>>>,
pub populated_external_types: RefCell<HashSet<DefId, DefaultState<FnvHasher>>>,
pub populated_external_traits: RefCell<HashSet<DefId, DefaultState<FnvHasher>>>,
pub upvar_borrow_map: RefCell<HashMap<UpvarId, UpvarBorrow, DefaultState<FnvHasher>>>,
pub extern_const_statics: RefCell<HashMap<DefId, u32, DefaultState<FnvHasher>>>,
pub extern_const_variants: RefCell<HashMap<DefId, u32, DefaultState<FnvHasher>>>,
pub method_map: RefCell<HashMap<MethodCall, MethodCallee<'tcx>, DefaultState<FnvHasher>>>,
pub dependency_formats: RefCell<HashMap<CrateType, Vec<Option<LinkagePreference>>, DefaultState<FnvHasher>>>,
pub unboxed_closures: RefCell<HashMap<DefId, UnboxedClosure<'tcx>, DefaultState<FnvHasher>>>,
pub node_lint_levels: RefCell<HashMap<(u32, LintId), (Level, LintSource), DefaultState<FnvHasher>>>,
pub transmute_restrictions: RefCell<Vec<TransmuteRestriction<'tcx>>>,
pub stability: RefCell<Index>,
pub capture_modes: RefCell<HashMap<u32, CaptureClause, DefaultState<FnvHasher>>>,
pub associated_types: RefCell<HashMap<DefId, bool, DefaultState<FnvHasher>>>,
pub selection_cache: SelectionCache<'tcx>,
pub repr_hint_cache: RefCell<HashMap<DefId, Rc<Vec<ReprAttr>>, DefaultState<FnvHasher>>>,
pub type_impls_copy_cache: RefCell<HashMap<&'tcx TyS<'tcx>, bool, RandomState>>,
pub type_impls_sized_cache: RefCell<HashMap<&'tcx TyS<'tcx>, bool, RandomState>>,
pub object_safety_cache: RefCell<HashMap<DefId, bool, DefaultState<FnvHasher>>>,
// some fields omitted
}The data structure to keep track of all the information that typechecker generates so that so that it can be reused and doesn't have to be redone later on.