[−][src]Struct rustc_metadata::cstore::CrateMetadata
🔬 This is a nightly-only experimental API. (rustc_private
)
this crate is being loaded from the sysroot, an unstable location; did you mean to load this crate from crates.io via Cargo.toml
instead?
Fields
name: Symbol
🔬 This is a nightly-only experimental API. (rustc_private
)
this crate is being loaded from the sysroot, an unstable location; did you mean to load this crate from crates.io via Cargo.toml
instead?
Original name of the crate.
imported_name: Symbol
🔬 This is a nightly-only experimental API. (rustc_private
)
this crate is being loaded from the sysroot, an unstable location; did you mean to load this crate from crates.io via Cargo.toml
instead?
Name of the crate as imported. I.e. if imported with
extern crate foo as bar;
this will be bar
.
extern_crate: Lock<Option<ExternCrate>>
🔬 This is a nightly-only experimental API. (rustc_private
)
this crate is being loaded from the sysroot, an unstable location; did you mean to load this crate from crates.io via Cargo.toml
instead?
Information about the extern crate that caused this crate to
be loaded. If this is None
, then the crate was injected
(e.g., by the allocator)
blob: MetadataBlob
🔬 This is a nightly-only experimental API. (rustc_private
)
this crate is being loaded from the sysroot, an unstable location; did you mean to load this crate from crates.io via Cargo.toml
instead?
cnum_map: CrateNumMap
🔬 This is a nightly-only experimental API. (rustc_private
)
this crate is being loaded from the sysroot, an unstable location; did you mean to load this crate from crates.io via Cargo.toml
instead?
cnum: CrateNum
🔬 This is a nightly-only experimental API. (rustc_private
)
this crate is being loaded from the sysroot, an unstable location; did you mean to load this crate from crates.io via Cargo.toml
instead?
dependencies: Lock<Vec<CrateNum>>
🔬 This is a nightly-only experimental API. (rustc_private
)
this crate is being loaded from the sysroot, an unstable location; did you mean to load this crate from crates.io via Cargo.toml
instead?
source_map_import_info: RwLock<Vec<ImportedSourceFile>>
🔬 This is a nightly-only experimental API. (rustc_private
)
this crate is being loaded from the sysroot, an unstable location; did you mean to load this crate from crates.io via Cargo.toml
instead?
alloc_decoding_state: AllocDecodingState
🔬 This is a nightly-only experimental API. (rustc_private
)
this crate is being loaded from the sysroot, an unstable location; did you mean to load this crate from crates.io via Cargo.toml
instead?
Used for decoding interpret::AllocIds in a cached & thread-safe manner.
root: CrateRoot
🔬 This is a nightly-only experimental API. (rustc_private
)
this crate is being loaded from the sysroot, an unstable location; did you mean to load this crate from crates.io via Cargo.toml
instead?
def_path_table: Lrc<DefPathTable>
🔬 This is a nightly-only experimental API. (rustc_private
)
this crate is being loaded from the sysroot, an unstable location; did you mean to load this crate from crates.io via Cargo.toml
instead?
For each public item in this crate, we encode a key. When the
crate is loaded, we read all the keys and put them in this
hashmap, which gives the reverse mapping. This allows us to
quickly retrace a DefPath
, which is needed for incremental
compilation support.
trait_impls: FxHashMap<(u32, DefIndex), LazySeq<DefIndex>>
🔬 This is a nightly-only experimental API. (rustc_private
)
this crate is being loaded from the sysroot, an unstable location; did you mean to load this crate from crates.io via Cargo.toml
instead?
dep_kind: Lock<DepKind>
🔬 This is a nightly-only experimental API. (rustc_private
)
this crate is being loaded from the sysroot, an unstable location; did you mean to load this crate from crates.io via Cargo.toml
instead?
source: CrateSource
🔬 This is a nightly-only experimental API. (rustc_private
)
this crate is being loaded from the sysroot, an unstable location; did you mean to load this crate from crates.io via Cargo.toml
instead?
proc_macros: Option<Vec<(Name, Lrc<SyntaxExtension>)>>
🔬 This is a nightly-only experimental API. (rustc_private
)
this crate is being loaded from the sysroot, an unstable location; did you mean to load this crate from crates.io via Cargo.toml
instead?
Methods
impl<'a, 'tcx> CrateMetadata
[src]
impl<'a, 'tcx> CrateMetadata
fn is_proc_macro(&self, id: DefIndex) -> bool
[src]
fn is_proc_macro(&self, id: DefIndex) -> bool
🔬 This is a nightly-only experimental API. (rustc_private
)
this crate is being loaded from the sysroot, an unstable location; did you mean to load this crate from crates.io via Cargo.toml
instead?
fn maybe_entry(&self, item_id: DefIndex) -> Option<Lazy<Entry<'tcx>>>
[src]
fn maybe_entry(&self, item_id: DefIndex) -> Option<Lazy<Entry<'tcx>>>
🔬 This is a nightly-only experimental API. (rustc_private
)
this crate is being loaded from the sysroot, an unstable location; did you mean to load this crate from crates.io via Cargo.toml
instead?
fn entry(&self, item_id: DefIndex) -> Entry<'tcx>
[src]
fn entry(&self, item_id: DefIndex) -> Entry<'tcx>
🔬 This is a nightly-only experimental API. (rustc_private
)
this crate is being loaded from the sysroot, an unstable location; did you mean to load this crate from crates.io via Cargo.toml
instead?
fn local_def_id(&self, index: DefIndex) -> DefId
[src]
fn local_def_id(&self, index: DefIndex) -> DefId
🔬 This is a nightly-only experimental API. (rustc_private
)
this crate is being loaded from the sysroot, an unstable location; did you mean to load this crate from crates.io via Cargo.toml
instead?
pub fn item_name(&self, item_index: DefIndex) -> InternedString
[src]
pub fn item_name(&self, item_index: DefIndex) -> InternedString
🔬 This is a nightly-only experimental API. (rustc_private
)
this crate is being loaded from the sysroot, an unstable location; did you mean to load this crate from crates.io via Cargo.toml
instead?
pub fn get_def(&self, index: DefIndex) -> Option<Def>
[src]
pub fn get_def(&self, index: DefIndex) -> Option<Def>
🔬 This is a nightly-only experimental API. (rustc_private
)
this crate is being loaded from the sysroot, an unstable location; did you mean to load this crate from crates.io via Cargo.toml
instead?
pub fn get_span(&self, index: DefIndex, sess: &Session) -> Span
[src]
pub fn get_span(&self, index: DefIndex, sess: &Session) -> Span
🔬 This is a nightly-only experimental API. (rustc_private
)
this crate is being loaded from the sysroot, an unstable location; did you mean to load this crate from crates.io via Cargo.toml
instead?
pub fn get_trait_def(&self, item_id: DefIndex, sess: &Session) -> TraitDef
[src]
pub fn get_trait_def(&self, item_id: DefIndex, sess: &Session) -> TraitDef
🔬 This is a nightly-only experimental API. (rustc_private
)
this crate is being loaded from the sysroot, an unstable location; did you mean to load this crate from crates.io via Cargo.toml
instead?
fn get_variant(
&self,
tcx: TyCtxt<'a, 'tcx, 'tcx>,
item: &Entry,
index: DefIndex,
adt_kind: AdtKind
) -> VariantDef
[src]
fn get_variant(
&self,
tcx: TyCtxt<'a, 'tcx, 'tcx>,
item: &Entry,
index: DefIndex,
adt_kind: AdtKind
) -> VariantDef
🔬 This is a nightly-only experimental API. (rustc_private
)
this crate is being loaded from the sysroot, an unstable location; did you mean to load this crate from crates.io via Cargo.toml
instead?
pub fn get_adt_def(
&self,
item_id: DefIndex,
tcx: TyCtxt<'a, 'tcx, 'tcx>
) -> &'tcx AdtDef
[src]
pub fn get_adt_def(
&self,
item_id: DefIndex,
tcx: TyCtxt<'a, 'tcx, 'tcx>
) -> &'tcx AdtDef
🔬 This is a nightly-only experimental API. (rustc_private
)
this crate is being loaded from the sysroot, an unstable location; did you mean to load this crate from crates.io via Cargo.toml
instead?
pub fn get_predicates(
&self,
item_id: DefIndex,
tcx: TyCtxt<'a, 'tcx, 'tcx>
) -> GenericPredicates<'tcx>
[src]
pub fn get_predicates(
&self,
item_id: DefIndex,
tcx: TyCtxt<'a, 'tcx, 'tcx>
) -> GenericPredicates<'tcx>
🔬 This is a nightly-only experimental API. (rustc_private
)
this crate is being loaded from the sysroot, an unstable location; did you mean to load this crate from crates.io via Cargo.toml
instead?
pub fn get_predicates_defined_on(
&self,
item_id: DefIndex,
tcx: TyCtxt<'a, 'tcx, 'tcx>
) -> GenericPredicates<'tcx>
[src]
pub fn get_predicates_defined_on(
&self,
item_id: DefIndex,
tcx: TyCtxt<'a, 'tcx, 'tcx>
) -> GenericPredicates<'tcx>
🔬 This is a nightly-only experimental API. (rustc_private
)
this crate is being loaded from the sysroot, an unstable location; did you mean to load this crate from crates.io via Cargo.toml
instead?
pub fn get_super_predicates(
&self,
item_id: DefIndex,
tcx: TyCtxt<'a, 'tcx, 'tcx>
) -> GenericPredicates<'tcx>
[src]
pub fn get_super_predicates(
&self,
item_id: DefIndex,
tcx: TyCtxt<'a, 'tcx, 'tcx>
) -> GenericPredicates<'tcx>
🔬 This is a nightly-only experimental API. (rustc_private
)
this crate is being loaded from the sysroot, an unstable location; did you mean to load this crate from crates.io via Cargo.toml
instead?
pub fn get_generics(&self, item_id: DefIndex, sess: &Session) -> Generics
[src]
pub fn get_generics(&self, item_id: DefIndex, sess: &Session) -> Generics
🔬 This is a nightly-only experimental API. (rustc_private
)
this crate is being loaded from the sysroot, an unstable location; did you mean to load this crate from crates.io via Cargo.toml
instead?
pub fn get_type(&self, id: DefIndex, tcx: TyCtxt<'a, 'tcx, 'tcx>) -> Ty<'tcx>
[src]
pub fn get_type(&self, id: DefIndex, tcx: TyCtxt<'a, 'tcx, 'tcx>) -> Ty<'tcx>
🔬 This is a nightly-only experimental API. (rustc_private
)
this crate is being loaded from the sysroot, an unstable location; did you mean to load this crate from crates.io via Cargo.toml
instead?
pub fn get_stability(&self, id: DefIndex) -> Option<Stability>
[src]
pub fn get_stability(&self, id: DefIndex) -> Option<Stability>
🔬 This is a nightly-only experimental API. (rustc_private
)
this crate is being loaded from the sysroot, an unstable location; did you mean to load this crate from crates.io via Cargo.toml
instead?
pub fn get_deprecation(&self, id: DefIndex) -> Option<Deprecation>
[src]
pub fn get_deprecation(&self, id: DefIndex) -> Option<Deprecation>
🔬 This is a nightly-only experimental API. (rustc_private
)
this crate is being loaded from the sysroot, an unstable location; did you mean to load this crate from crates.io via Cargo.toml
instead?
pub fn get_visibility(&self, id: DefIndex) -> Visibility
[src]
pub fn get_visibility(&self, id: DefIndex) -> Visibility
🔬 This is a nightly-only experimental API. (rustc_private
)
this crate is being loaded from the sysroot, an unstable location; did you mean to load this crate from crates.io via Cargo.toml
instead?
fn get_impl_data(&self, id: DefIndex) -> ImplData<'tcx>
[src]
fn get_impl_data(&self, id: DefIndex) -> ImplData<'tcx>
🔬 This is a nightly-only experimental API. (rustc_private
)
this crate is being loaded from the sysroot, an unstable location; did you mean to load this crate from crates.io via Cargo.toml
instead?
pub fn get_parent_impl(&self, id: DefIndex) -> Option<DefId>
[src]
pub fn get_parent_impl(&self, id: DefIndex) -> Option<DefId>
🔬 This is a nightly-only experimental API. (rustc_private
)
this crate is being loaded from the sysroot, an unstable location; did you mean to load this crate from crates.io via Cargo.toml
instead?
pub fn get_impl_polarity(&self, id: DefIndex) -> ImplPolarity
[src]
pub fn get_impl_polarity(&self, id: DefIndex) -> ImplPolarity
🔬 This is a nightly-only experimental API. (rustc_private
)
this crate is being loaded from the sysroot, an unstable location; did you mean to load this crate from crates.io via Cargo.toml
instead?
pub fn get_impl_defaultness(&self, id: DefIndex) -> Defaultness
[src]
pub fn get_impl_defaultness(&self, id: DefIndex) -> Defaultness
🔬 This is a nightly-only experimental API. (rustc_private
)
this crate is being loaded from the sysroot, an unstable location; did you mean to load this crate from crates.io via Cargo.toml
instead?
pub fn get_coerce_unsized_info(&self, id: DefIndex) -> Option<CoerceUnsizedInfo>
[src]
pub fn get_coerce_unsized_info(&self, id: DefIndex) -> Option<CoerceUnsizedInfo>
🔬 This is a nightly-only experimental API. (rustc_private
)
this crate is being loaded from the sysroot, an unstable location; did you mean to load this crate from crates.io via Cargo.toml
instead?
pub fn get_impl_trait(
&self,
id: DefIndex,
tcx: TyCtxt<'a, 'tcx, 'tcx>
) -> Option<TraitRef<'tcx>>
[src]
pub fn get_impl_trait(
&self,
id: DefIndex,
tcx: TyCtxt<'a, 'tcx, 'tcx>
) -> Option<TraitRef<'tcx>>
🔬 This is a nightly-only experimental API. (rustc_private
)
this crate is being loaded from the sysroot, an unstable location; did you mean to load this crate from crates.io via Cargo.toml
instead?
pub fn get_lib_features(&self) -> Vec<(Name, Option<Name>)>
[src]
pub fn get_lib_features(&self) -> Vec<(Name, Option<Name>)>
🔬 This is a nightly-only experimental API. (rustc_private
)
this crate is being loaded from the sysroot, an unstable location; did you mean to load this crate from crates.io via Cargo.toml
instead?
Iterates over all the stability attributes in the given crate.
pub fn get_lang_items(&self) -> Vec<(DefId, usize)>
[src]
pub fn get_lang_items(&self) -> Vec<(DefId, usize)>
🔬 This is a nightly-only experimental API. (rustc_private
)
this crate is being loaded from the sysroot, an unstable location; did you mean to load this crate from crates.io via Cargo.toml
instead?
Iterates over the language items in the given crate.
pub fn each_child_of_item<F>(&self, id: DefIndex, callback: F, sess: &Session) where
F: FnMut(Export),
[src]
pub fn each_child_of_item<F>(&self, id: DefIndex, callback: F, sess: &Session) where
F: FnMut(Export),
🔬 This is a nightly-only experimental API. (rustc_private
)
this crate is being loaded from the sysroot, an unstable location; did you mean to load this crate from crates.io via Cargo.toml
instead?
Iterates over each child of the given item.
pub fn const_is_rvalue_promotable_to_static(&self, id: DefIndex) -> bool
[src]
pub fn const_is_rvalue_promotable_to_static(&self, id: DefIndex) -> bool
🔬 This is a nightly-only experimental API. (rustc_private
)
this crate is being loaded from the sysroot, an unstable location; did you mean to load this crate from crates.io via Cargo.toml
instead?
pub fn is_item_mir_available(&self, id: DefIndex) -> bool
[src]
pub fn is_item_mir_available(&self, id: DefIndex) -> bool
🔬 This is a nightly-only experimental API. (rustc_private
)
this crate is being loaded from the sysroot, an unstable location; did you mean to load this crate from crates.io via Cargo.toml
instead?
pub fn maybe_get_optimized_mir(
&self,
tcx: TyCtxt<'a, 'tcx, 'tcx>,
id: DefIndex
) -> Option<Mir<'tcx>>
[src]
pub fn maybe_get_optimized_mir(
&self,
tcx: TyCtxt<'a, 'tcx, 'tcx>,
id: DefIndex
) -> Option<Mir<'tcx>>
🔬 This is a nightly-only experimental API. (rustc_private
)
this crate is being loaded from the sysroot, an unstable location; did you mean to load this crate from crates.io via Cargo.toml
instead?
pub fn mir_const_qualif(&self, id: DefIndex) -> u8
[src]
pub fn mir_const_qualif(&self, id: DefIndex) -> u8
🔬 This is a nightly-only experimental API. (rustc_private
)
this crate is being loaded from the sysroot, an unstable location; did you mean to load this crate from crates.io via Cargo.toml
instead?
pub fn get_associated_item(&self, id: DefIndex) -> AssociatedItem
[src]
pub fn get_associated_item(&self, id: DefIndex) -> AssociatedItem
🔬 This is a nightly-only experimental API. (rustc_private
)
this crate is being loaded from the sysroot, an unstable location; did you mean to load this crate from crates.io via Cargo.toml
instead?
pub fn get_item_variances(&self, id: DefIndex) -> Vec<Variance>
[src]
pub fn get_item_variances(&self, id: DefIndex) -> Vec<Variance>
🔬 This is a nightly-only experimental API. (rustc_private
)
this crate is being loaded from the sysroot, an unstable location; did you mean to load this crate from crates.io via Cargo.toml
instead?
pub fn get_ctor_kind(&self, node_id: DefIndex) -> CtorKind
[src]
pub fn get_ctor_kind(&self, node_id: DefIndex) -> CtorKind
🔬 This is a nightly-only experimental API. (rustc_private
)
this crate is being loaded from the sysroot, an unstable location; did you mean to load this crate from crates.io via Cargo.toml
instead?
pub fn get_struct_ctor_def_id(&self, node_id: DefIndex) -> Option<DefId>
[src]
pub fn get_struct_ctor_def_id(&self, node_id: DefIndex) -> Option<DefId>
🔬 This is a nightly-only experimental API. (rustc_private
)
this crate is being loaded from the sysroot, an unstable location; did you mean to load this crate from crates.io via Cargo.toml
instead?
pub fn get_item_attrs(
&self,
node_id: DefIndex,
sess: &Session
) -> Lrc<[Attribute]>
[src]
pub fn get_item_attrs(
&self,
node_id: DefIndex,
sess: &Session
) -> Lrc<[Attribute]>
🔬 This is a nightly-only experimental API. (rustc_private
)
this crate is being loaded from the sysroot, an unstable location; did you mean to load this crate from crates.io via Cargo.toml
instead?
pub fn get_struct_field_names(&self, id: DefIndex) -> Vec<Name>
[src]
pub fn get_struct_field_names(&self, id: DefIndex) -> Vec<Name>
🔬 This is a nightly-only experimental API. (rustc_private
)
this crate is being loaded from the sysroot, an unstable location; did you mean to load this crate from crates.io via Cargo.toml
instead?
fn get_attributes(&self, item: &Entry<'tcx>, sess: &Session) -> Vec<Attribute>
[src]
fn get_attributes(&self, item: &Entry<'tcx>, sess: &Session) -> Vec<Attribute>
🔬 This is a nightly-only experimental API. (rustc_private
)
this crate is being loaded from the sysroot, an unstable location; did you mean to load this crate from crates.io via Cargo.toml
instead?
fn reverse_translate_def_id(&self, did: DefId) -> Option<DefId>
[src]
fn reverse_translate_def_id(&self, did: DefId) -> Option<DefId>
🔬 This is a nightly-only experimental API. (rustc_private
)
this crate is being loaded from the sysroot, an unstable location; did you mean to load this crate from crates.io via Cargo.toml
instead?
pub fn get_inherent_implementations_for_type(&self, id: DefIndex) -> Vec<DefId>
[src]
pub fn get_inherent_implementations_for_type(&self, id: DefIndex) -> Vec<DefId>
🔬 This is a nightly-only experimental API. (rustc_private
)
this crate is being loaded from the sysroot, an unstable location; did you mean to load this crate from crates.io via Cargo.toml
instead?
pub fn get_implementations_for_trait(
&self,
filter: Option<DefId>,
result: &mut Vec<DefId>
)
[src]
pub fn get_implementations_for_trait(
&self,
filter: Option<DefId>,
result: &mut Vec<DefId>
)
🔬 This is a nightly-only experimental API. (rustc_private
)
this crate is being loaded from the sysroot, an unstable location; did you mean to load this crate from crates.io via Cargo.toml
instead?
pub fn get_trait_of_item(&self, id: DefIndex) -> Option<DefId>
[src]
pub fn get_trait_of_item(&self, id: DefIndex) -> Option<DefId>
🔬 This is a nightly-only experimental API. (rustc_private
)
this crate is being loaded from the sysroot, an unstable location; did you mean to load this crate from crates.io via Cargo.toml
instead?
pub fn get_native_libraries(&self, sess: &Session) -> Vec<NativeLibrary>
[src]
pub fn get_native_libraries(&self, sess: &Session) -> Vec<NativeLibrary>
🔬 This is a nightly-only experimental API. (rustc_private
)
this crate is being loaded from the sysroot, an unstable location; did you mean to load this crate from crates.io via Cargo.toml
instead?
pub fn get_foreign_modules(&self, sess: &Session) -> Vec<ForeignModule>
[src]
pub fn get_foreign_modules(&self, sess: &Session) -> Vec<ForeignModule>
🔬 This is a nightly-only experimental API. (rustc_private
)
this crate is being loaded from the sysroot, an unstable location; did you mean to load this crate from crates.io via Cargo.toml
instead?
pub fn get_dylib_dependency_formats(&self) -> Vec<(CrateNum, LinkagePreference)>
[src]
pub fn get_dylib_dependency_formats(&self) -> Vec<(CrateNum, LinkagePreference)>
🔬 This is a nightly-only experimental API. (rustc_private
)
this crate is being loaded from the sysroot, an unstable location; did you mean to load this crate from crates.io via Cargo.toml
instead?
pub fn get_missing_lang_items(&self) -> Vec<LangItem>
[src]
pub fn get_missing_lang_items(&self) -> Vec<LangItem>
🔬 This is a nightly-only experimental API. (rustc_private
)
this crate is being loaded from the sysroot, an unstable location; did you mean to load this crate from crates.io via Cargo.toml
instead?
pub fn get_fn_arg_names(&self, id: DefIndex) -> Vec<Name>
[src]
pub fn get_fn_arg_names(&self, id: DefIndex) -> Vec<Name>
🔬 This is a nightly-only experimental API. (rustc_private
)
this crate is being loaded from the sysroot, an unstable location; did you mean to load this crate from crates.io via Cargo.toml
instead?
pub fn exported_symbols(
&self,
tcx: TyCtxt<'a, 'tcx, 'tcx>
) -> Vec<(ExportedSymbol<'tcx>, SymbolExportLevel)>
[src]
pub fn exported_symbols(
&self,
tcx: TyCtxt<'a, 'tcx, 'tcx>
) -> Vec<(ExportedSymbol<'tcx>, SymbolExportLevel)>
🔬 This is a nightly-only experimental API. (rustc_private
)
this crate is being loaded from the sysroot, an unstable location; did you mean to load this crate from crates.io via Cargo.toml
instead?
pub fn get_rendered_const(&self, id: DefIndex) -> String
[src]
pub fn get_rendered_const(&self, id: DefIndex) -> String
🔬 This is a nightly-only experimental API. (rustc_private
)
this crate is being loaded from the sysroot, an unstable location; did you mean to load this crate from crates.io via Cargo.toml
instead?
pub fn get_macro(&self, id: DefIndex) -> MacroDef
[src]
pub fn get_macro(&self, id: DefIndex) -> MacroDef
🔬 This is a nightly-only experimental API. (rustc_private
)
this crate is being loaded from the sysroot, an unstable location; did you mean to load this crate from crates.io via Cargo.toml
instead?
pub fn is_const_fn(&self, id: DefIndex) -> bool
[src]
pub fn is_const_fn(&self, id: DefIndex) -> bool
🔬 This is a nightly-only experimental API. (rustc_private
)
this crate is being loaded from the sysroot, an unstable location; did you mean to load this crate from crates.io via Cargo.toml
instead?
pub fn is_foreign_item(&self, id: DefIndex) -> bool
[src]
pub fn is_foreign_item(&self, id: DefIndex) -> bool
🔬 This is a nightly-only experimental API. (rustc_private
)
this crate is being loaded from the sysroot, an unstable location; did you mean to load this crate from crates.io via Cargo.toml
instead?
pub fn fn_sig(
&self,
id: DefIndex,
tcx: TyCtxt<'a, 'tcx, 'tcx>
) -> PolyFnSig<'tcx>
[src]
pub fn fn_sig(
&self,
id: DefIndex,
tcx: TyCtxt<'a, 'tcx, 'tcx>
) -> PolyFnSig<'tcx>
🔬 This is a nightly-only experimental API. (rustc_private
)
this crate is being loaded from the sysroot, an unstable location; did you mean to load this crate from crates.io via Cargo.toml
instead?
pub fn def_key(&self, index: DefIndex) -> DefKey
[src]
pub fn def_key(&self, index: DefIndex) -> DefKey
🔬 This is a nightly-only experimental API. (rustc_private
)
this crate is being loaded from the sysroot, an unstable location; did you mean to load this crate from crates.io via Cargo.toml
instead?
pub fn def_path(&self, id: DefIndex) -> DefPath
[src]
pub fn def_path(&self, id: DefIndex) -> DefPath
🔬 This is a nightly-only experimental API. (rustc_private
)
this crate is being loaded from the sysroot, an unstable location; did you mean to load this crate from crates.io via Cargo.toml
instead?
pub fn def_path_hash(&self, index: DefIndex) -> DefPathHash
[src]
pub fn def_path_hash(&self, index: DefIndex) -> DefPathHash
🔬 This is a nightly-only experimental API. (rustc_private
)
this crate is being loaded from the sysroot, an unstable location; did you mean to load this crate from crates.io via Cargo.toml
instead?
pub fn imported_source_files(
&'a self,
local_source_map: &SourceMap
) -> ReadGuard<'a, Vec<ImportedSourceFile>>
[src]
pub fn imported_source_files(
&'a self,
local_source_map: &SourceMap
) -> ReadGuard<'a, Vec<ImportedSourceFile>>
🔬 This is a nightly-only experimental API. (rustc_private
)
this crate is being loaded from the sysroot, an unstable location; did you mean to load this crate from crates.io via Cargo.toml
instead?
Imports the source_map from an external crate into the source_map of the crate currently being compiled (the "local crate").
The import algorithm works analogous to how AST items are inlined from an
external crate's metadata:
For every SourceFile in the external source_map an 'inline' copy is created in the
local source_map. The correspondence relation between external and local
SourceFiles is recorded in the ImportedSourceFile
objects returned from this
function. When an item from an external crate is later inlined into this
crate, this correspondence information is used to translate the span
information of the inlined item so that it refers the correct positions in
the local source_map (see <decoder::DecodeContext as SpecializedDecoder<Span>>
).
The import algorithm in the function below will reuse SourceFiles already existing in the local source_map. For example, even if the SourceFile of some source file of libstd gets imported many times, there will only ever be one SourceFile object for the corresponding file in the local source_map.
Note that imported SourceFiles do not actually contain the source code of the file they represent, just information about length, line breaks, and multibyte characters. This information is enough to generate valid debuginfo for items inlined from other crates.
Proc macro crates don't currently export spans, so this function does not have to work for them.
Trait Implementations
impl<'a, 'tcx> Metadata<'a, 'tcx> for &'a CrateMetadata
[src]
impl<'a, 'tcx> Metadata<'a, 'tcx> for &'a CrateMetadata
fn raw_bytes(self) -> &'a [u8]
[src]
fn raw_bytes(self) -> &'a [u8]
🔬 This is a nightly-only experimental API. (rustc_private
)
this crate is being loaded from the sysroot, an unstable location; did you mean to load this crate from crates.io via Cargo.toml
instead?
fn cdata(self) -> Option<&'a CrateMetadata>
[src]
fn cdata(self) -> Option<&'a CrateMetadata>
🔬 This is a nightly-only experimental API. (rustc_private
)
this crate is being loaded from the sysroot, an unstable location; did you mean to load this crate from crates.io via Cargo.toml
instead?
fn sess(self) -> Option<&'a Session>
[src]
fn sess(self) -> Option<&'a Session>
🔬 This is a nightly-only experimental API. (rustc_private
)
this crate is being loaded from the sysroot, an unstable location; did you mean to load this crate from crates.io via Cargo.toml
instead?
fn tcx(self) -> Option<TyCtxt<'a, 'tcx, 'tcx>>
[src]
fn tcx(self) -> Option<TyCtxt<'a, 'tcx, 'tcx>>
🔬 This is a nightly-only experimental API. (rustc_private
)
this crate is being loaded from the sysroot, an unstable location; did you mean to load this crate from crates.io via Cargo.toml
instead?
fn decoder(self, pos: usize) -> DecodeContext<'a, 'tcx>
[src]
fn decoder(self, pos: usize) -> DecodeContext<'a, 'tcx>
🔬 This is a nightly-only experimental API. (rustc_private
)
this crate is being loaded from the sysroot, an unstable location; did you mean to load this crate from crates.io via Cargo.toml
instead?
Auto Trait Implementations
impl !Send for CrateMetadata
impl !Send for CrateMetadata
impl !Sync for CrateMetadata
impl !Sync for CrateMetadata
Blanket Implementations
impl<T> From for T
[src]
impl<T> From for T
impl<T, U> Into for T where
U: From<T>,
[src]
impl<T, U> Into for T where
U: From<T>,
impl<T, U> TryFrom for T where
T: From<U>,
[src]
impl<T, U> TryFrom for T where
T: From<U>,
type Error = !
try_from
)The type returned in the event of a conversion error.
fn try_from(value: U) -> Result<T, <T as TryFrom<U>>::Error>
[src]
fn try_from(value: U) -> Result<T, <T as TryFrom<U>>::Error>
try_from
)Performs the conversion.
impl<T> Borrow for T where
T: ?Sized,
[src]
impl<T> Borrow for T where
T: ?Sized,
ⓘImportant traits for &'a mut Rfn borrow(&self) -> &T
[src]
fn borrow(&self) -> &T
Immutably borrows from an owned value. Read more
impl<T, U> TryInto for T where
U: TryFrom<T>,
[src]
impl<T, U> TryInto for T where
U: TryFrom<T>,
type Error = <U as TryFrom<T>>::Error
try_from
)The type returned in the event of a conversion error.
fn try_into(self) -> Result<U, <U as TryFrom<T>>::Error>
[src]
fn try_into(self) -> Result<U, <U as TryFrom<T>>::Error>
try_from
)Performs the conversion.
impl<T> BorrowMut for T where
T: ?Sized,
[src]
impl<T> BorrowMut for T where
T: ?Sized,
ⓘImportant traits for &'a mut Rfn borrow_mut(&mut self) -> &mut T
[src]
fn borrow_mut(&mut self) -> &mut T
Mutably borrows from an owned value. Read more
impl<T> Any for T where
T: 'static + ?Sized,
[src]
impl<T> Any for T where
T: 'static + ?Sized,
fn get_type_id(&self) -> TypeId
[src]
fn get_type_id(&self) -> TypeId
🔬 This is a nightly-only experimental API. (get_type_id
)
this method will likely be replaced by an associated static
Gets the TypeId
of self
. Read more
impl<E> SpecializationError for E
[src]
impl<E> SpecializationError for E
fn not_found<S, T>(trait_name: &'static str, method_name: &'static str) -> E where
T: ?Sized,
[src]
fn not_found<S, T>(trait_name: &'static str, method_name: &'static str) -> E where
T: ?Sized,
🔬 This is a nightly-only experimental API. (rustc_private
)
this crate is being loaded from the sysroot, an unstable location; did you mean to load this crate from crates.io via Cargo.toml
instead?
Create an error for a missing method specialization. Defaults to panicking with type, trait & method names. S
is the encoder/decoder state type, T
is the type being encoded/decoded, and the arguments are the names of the trait and method that should've been overridden. Read more
impl<T> Erased for T
[src]
impl<T> Erased for T
impl<T> Send for T where
T: ?Sized,
[src]
impl<T> Send for T where
T: ?Sized,
impl<T> Sync for T where
T: ?Sized,
[src]
impl<T> Sync for T where
T: ?Sized,
impl<T> Erased for T
impl<T> Erased for T
impl<T> MaybeResult for T
[src]
impl<T> MaybeResult for T
fn from_ok(x: T) -> T
[src]
fn from_ok(x: T) -> T
🔬 This is a nightly-only experimental API. (rustc_private
)
this crate is being loaded from the sysroot, an unstable location; did you mean to load this crate from crates.io via Cargo.toml
instead?
fn map_same<F>(self, f: F) -> T where
F: FnOnce(T) -> T,
[src]
fn map_same<F>(self, f: F) -> T where
F: FnOnce(T) -> T,
🔬 This is a nightly-only experimental API. (rustc_private
)
this crate is being loaded from the sysroot, an unstable location; did you mean to load this crate from crates.io via Cargo.toml
instead?
impl<'a, T> Captures for T where
T: ?Sized,
[src]
impl<'a, T> Captures for T where
T: ?Sized,