Type Definition rustc::ty::Ty [−][src]
type Ty<'tcx> = &'tcx TyS<'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?
Trait Implementations
impl<'tcx> ToTrace<'tcx> for Ty<'tcx>[src]
impl<'tcx> ToTrace<'tcx> for Ty<'tcx>fn to_trace(
cause: &ObligationCause<'tcx>,
a_is_expected: bool,
a: Self,
b: Self
) -> TypeTrace<'tcx>[src]
fn to_trace(
cause: &ObligationCause<'tcx>,
a_is_expected: bool,
a: Self,
b: Self
) -> TypeTrace<'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?
impl<'gcx, 'tcx> Normalizable<'gcx, 'tcx> for Ty<'tcx> where
'gcx: 'tcx, [src]
impl<'gcx, 'tcx> Normalizable<'gcx, 'tcx> for Ty<'tcx> where
'gcx: 'tcx, fn type_op_method(
tcx: TyCtxt<'_, 'gcx, 'tcx>,
canonicalized: Canonicalized<'gcx, ParamEnvAnd<'tcx, Normalize<Self>>>
) -> Fallible<CanonicalizedQueryResult<'gcx, Self>>[src]
fn type_op_method(
tcx: TyCtxt<'_, 'gcx, 'tcx>,
canonicalized: Canonicalized<'gcx, ParamEnvAnd<'tcx, Normalize<Self>>>
) -> Fallible<CanonicalizedQueryResult<'gcx, Self>>🔬 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 shrink_to_tcx_lifetime<'a>(
v: &'a CanonicalizedQueryResult<'gcx, Self>
) -> &'a Canonical<'tcx, QueryResult<'tcx, Self>>[src]
fn shrink_to_tcx_lifetime<'a>(
v: &'a CanonicalizedQueryResult<'gcx, Self>
) -> &'a Canonical<'tcx, QueryResult<'tcx, Self>>🔬 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?
Convert from the 'gcx (lifted) form of Self into the tcx form of Self. Read more
impl<'tcx> EncodableWithShorthand for Ty<'tcx>[src]
impl<'tcx> EncodableWithShorthand for Ty<'tcx>type Variant = TypeVariants<'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 variant(&self) -> &Self::Variant[src]
fn variant(&self) -> &Self::Variant🔬 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, 'tcx, C> TyLayoutMethods<'tcx, C> for Ty<'tcx> where
C: LayoutOf<Ty = Ty<'tcx>> + HasTyCtxt<'tcx>,
C::TyLayout: MaybeResult<TyLayout<'tcx>>, [src]
impl<'a, 'tcx, C> TyLayoutMethods<'tcx, C> for Ty<'tcx> where
C: LayoutOf<Ty = Ty<'tcx>> + HasTyCtxt<'tcx>,
C::TyLayout: MaybeResult<TyLayout<'tcx>>, fn for_variant(
this: TyLayout<'tcx>,
cx: C,
variant_index: usize
) -> TyLayout<'tcx>[src]
fn for_variant(
this: TyLayout<'tcx>,
cx: C,
variant_index: usize
) -> TyLayout<'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 field(this: TyLayout<'tcx>, cx: C, i: usize) -> C::TyLayout[src]
fn field(this: TyLayout<'tcx>, cx: C, i: usize) -> C::TyLayout🔬 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<'tcx> Key for Ty<'tcx>[src]
impl<'tcx> Key for Ty<'tcx>fn query_crate(&self) -> CrateNum[src]
fn query_crate(&self) -> 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?
Given an instance of this key, what crate is it referring to? This is used to find the provider. Read more
fn default_span(&self, _: TyCtxt) -> Span[src]
fn default_span(&self, _: TyCtxt) -> 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?
In the event that a cycle occurs, if no explicit span has been given for a query with key self, what span should we use? Read more
impl<'tcx> Value<'tcx> for Ty<'tcx>[src]
impl<'tcx> Value<'tcx> for Ty<'tcx>fn from_cycle_error<'a>(tcx: TyCtxt<'a, 'tcx, 'tcx>) -> Ty<'tcx>[src]
fn from_cycle_error<'a>(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?
impl<'a, 'tcx, 'x> SpecializedDecoder<Ty<'tcx>> for CacheDecoder<'a, 'tcx, 'x>[src]
impl<'a, 'tcx, 'x> SpecializedDecoder<Ty<'tcx>> for CacheDecoder<'a, 'tcx, 'x>fn specialized_decode(&mut self) -> Result<Ty<'tcx>, Self::Error>[src]
fn specialized_decode(&mut self) -> Result<Ty<'tcx>, Self::Error>🔬 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?
Decode a value in a manner specific to this decoder state.
impl<'enc, 'a, 'tcx, E> SpecializedEncoder<Ty<'tcx>> for CacheEncoder<'enc, 'a, 'tcx, E> where
E: 'enc + TyEncoder, [src]
impl<'enc, 'a, 'tcx, E> SpecializedEncoder<Ty<'tcx>> for CacheEncoder<'enc, 'a, 'tcx, E> where
E: 'enc + TyEncoder, fn specialized_encode(&mut self, ty: &Ty<'tcx>) -> Result<(), Self::Error>[src]
fn specialized_encode(&mut self, ty: &Ty<'tcx>) -> Result<(), Self::Error>🔬 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?
Encode the value in a manner specific to this encoder state.
impl<'tcx> Relate<'tcx> for Ty<'tcx>[src]
impl<'tcx> Relate<'tcx> for Ty<'tcx>fn relate<'a, 'gcx, R>(
relation: &mut R,
a: &Ty<'tcx>,
b: &Ty<'tcx>
) -> RelateResult<'tcx, Ty<'tcx>> where
R: TypeRelation<'a, 'gcx, 'tcx>,
'gcx: 'a + 'tcx,
'tcx: 'a, [src]
fn relate<'a, 'gcx, R>(
relation: &mut R,
a: &Ty<'tcx>,
b: &Ty<'tcx>
) -> RelateResult<'tcx, Ty<'tcx>> where
R: TypeRelation<'a, 'gcx, 'tcx>,
'gcx: 'a + 'tcx,
'tcx: 'a, 🔬 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<'tcx> From<Ty<'tcx>> for Kind<'tcx>[src]
impl<'tcx> From<Ty<'tcx>> for Kind<'tcx>impl<'a, 'tcx> Lift<'tcx> for Ty<'a>[src]
impl<'a, 'tcx> Lift<'tcx> for Ty<'a>type Lifted = 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?
fn lift_to_tcx<'b, 'gcx>(&self, tcx: TyCtxt<'b, 'gcx, 'tcx>) -> Option<Ty<'tcx>>[src]
fn lift_to_tcx<'b, 'gcx>(&self, tcx: TyCtxt<'b, 'gcx, 'tcx>) -> Option<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?
impl<'tcx> TypeFoldable<'tcx> for Ty<'tcx>[src]
impl<'tcx> TypeFoldable<'tcx> for Ty<'tcx>fn super_fold_with<'gcx: 'tcx, F: TypeFolder<'gcx, 'tcx>>(
&self,
folder: &mut F
) -> Self[src]
fn super_fold_with<'gcx: 'tcx, F: TypeFolder<'gcx, 'tcx>>(
&self,
folder: &mut F
) -> Self🔬 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 fold_with<'gcx: 'tcx, F: TypeFolder<'gcx, 'tcx>>(
&self,
folder: &mut F
) -> Self[src]
fn fold_with<'gcx: 'tcx, F: TypeFolder<'gcx, 'tcx>>(
&self,
folder: &mut F
) -> Self🔬 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 super_visit_with<V: TypeVisitor<'tcx>>(&self, visitor: &mut V) -> bool[src]
fn super_visit_with<V: TypeVisitor<'tcx>>(&self, visitor: &mut V) -> 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 visit_with<V: TypeVisitor<'tcx>>(&self, visitor: &mut V) -> bool[src]
fn visit_with<V: TypeVisitor<'tcx>>(&self, visitor: &mut V) -> 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 has_regions_bound_at_or_above(&self, binder: DebruijnIndex) -> bool[src]
fn has_regions_bound_at_or_above(&self, binder: DebruijnIndex) -> 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?
True if self has any late-bound regions that are either bound by binder or bound by some binder outside of binder. If binder is ty::INNERMOST, this indicates whether there are any late-bound regions that appear free. Read more
fn has_regions_bound_above(&self, binder: DebruijnIndex) -> bool[src]
fn has_regions_bound_above(&self, binder: DebruijnIndex) -> 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?
True if this self has any regions that escape binder (and hence are not bound by it). Read more
fn has_escaping_regions(&self) -> bool[src]
fn has_escaping_regions(&self) -> 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 has_type_flags(&self, flags: TypeFlags) -> bool[src]
fn has_type_flags(&self, flags: TypeFlags) -> 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 has_projections(&self) -> bool[src]
fn has_projections(&self) -> 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 references_error(&self) -> bool[src]
fn references_error(&self) -> 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 has_param_types(&self) -> bool[src]
fn has_param_types(&self) -> 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 has_self_ty(&self) -> bool[src]
fn has_self_ty(&self) -> 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 has_infer_types(&self) -> bool[src]
fn has_infer_types(&self) -> 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 needs_infer(&self) -> bool[src]
fn needs_infer(&self) -> 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 has_skol(&self) -> bool[src]
fn has_skol(&self) -> 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 needs_subst(&self) -> bool[src]
fn needs_subst(&self) -> 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 has_re_skol(&self) -> bool[src]
fn has_re_skol(&self) -> 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 has_closure_types(&self) -> bool[src]
fn has_closure_types(&self) -> 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 has_free_regions(&self) -> bool[src]
fn has_free_regions(&self) -> 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?
"Free" regions in this context means that it has any region that is not (a) erased or (b) late-bound. Read more
fn has_erasable_regions(&self) -> bool[src]
fn has_erasable_regions(&self) -> 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?
True if there any any un-erased free regions.
fn is_global(&self) -> bool[src]
fn is_global(&self) -> 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?
Indicates whether this value references only 'global' types/lifetimes that are the same regardless of what fn we are in. This is used for caching. Read more
fn has_late_bound_regions(&self) -> bool[src]
fn has_late_bound_regions(&self) -> 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?
True if there are any late-bound regions
fn visit_tys_shallow(
&self,
visit: impl FnMut(Ty<'tcx>) -> bool
) -> bool[src]
fn visit_tys_shallow(
&self,
visit: impl FnMut(Ty<'tcx>) -> bool
) -> 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?
A visitor that does not recurse into types, works like fn walk_shallow in Ty.
impl<'tcx> UseSpecializedEncodable for Ty<'tcx>[src]
impl<'tcx> UseSpecializedEncodable for Ty<'tcx>fn default_encode<E>(&self, &mut E) -> Result<(), <E as Encoder>::Error> where
E: Encoder, [src]
fn default_encode<E>(&self, &mut E) -> Result<(), <E as Encoder>::Error> where
E: Encoder, 🔬 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?
Defaults to returning an error (see SpecializationError).
impl<'tcx> UseSpecializedDecodable for Ty<'tcx>[src]
impl<'tcx> UseSpecializedDecodable for Ty<'tcx>fn default_decode<D>(&mut D) -> Result<Self, <D as Decoder>::Error> where
D: Decoder, [src]
fn default_decode<D>(&mut D) -> Result<Self, <D as Decoder>::Error> where
D: Decoder, 🔬 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?
Defaults to returning an error (see SpecializationError).