Struct rustc::ty::trait_def::TraitDef
[−]
[src]
pub struct TraitDef { pub def_id: DefId, pub unsafety: Unsafety, pub paren_sugar: bool, pub has_auto_impl: bool, pub def_path_hash: 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?
A trait's definition with type information.
Fields
def_id: 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?
unsafety: Unsafety
🔬 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?
paren_sugar: 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?
If true
, then this trait had the #[rustc_paren_sugar]
attribute, indicating that it should be used with Foo()
sugar. This is a temporary thing -- eventually any trait will
be usable with the sugar (or without it).
has_auto_impl: 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?
def_path_hash: 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?
The ICH of this trait's DefPath, cached here so it doesn't have to be recomputed all the time.
Methods
impl<'a, 'gcx, 'tcx> TraitDef
[src]
pub fn new(
def_id: DefId,
unsafety: Unsafety,
paren_sugar: bool,
has_auto_impl: bool,
def_path_hash: DefPathHash
) -> TraitDef
[src]
def_id: DefId,
unsafety: Unsafety,
paren_sugar: bool,
has_auto_impl: bool,
def_path_hash: DefPathHash
) -> 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?
ⓘImportant traits for Ancestorspub fn ancestors(
&self,
tcx: TyCtxt<'a, 'gcx, 'tcx>,
of_impl: DefId
) -> Ancestors
[src]
&self,
tcx: TyCtxt<'a, 'gcx, 'tcx>,
of_impl: DefId
) -> Ancestors
🔬 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?
Trait Implementations
impl<'gcx> HashStable<StableHashingContext<'gcx>> for TraitDef
[src]
fn hash_stable<W: StableHasherResult>(
&self,
hcx: &mut StableHashingContext<'gcx>,
hasher: &mut StableHasher<W>
)
[src]
&self,
hcx: &mut StableHashingContext<'gcx>,
hasher: &mut StableHasher<W>
)
🔬 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?