Enum rustc_infer::infer::region_constraints::GenericKind
source · pub enum GenericKind<'tcx> {
Param(ParamTy),
Alias(AliasTy<'tcx>),
}
Variants§
Implementations§
Trait Implementations§
source§impl<'tcx> Clone for GenericKind<'tcx>
impl<'tcx> Clone for GenericKind<'tcx>
source§fn clone(&self) -> GenericKind<'tcx>
fn clone(&self) -> GenericKind<'tcx>
Returns a copy of the value. Read more
1.0.0 · source§fn clone_from(&mut self, source: &Self)
fn clone_from(&mut self, source: &Self)
Performs copy-assignment from
source
. Read moresource§impl<'tcx> Debug for GenericKind<'tcx>
impl<'tcx> Debug for GenericKind<'tcx>
source§impl<'tcx> Display for GenericKind<'tcx>
impl<'tcx> Display for GenericKind<'tcx>
source§impl<'tcx> Hash for GenericKind<'tcx>
impl<'tcx> Hash for GenericKind<'tcx>
source§impl<'tcx> PartialEq<GenericKind<'tcx>> for GenericKind<'tcx>
impl<'tcx> PartialEq<GenericKind<'tcx>> for GenericKind<'tcx>
source§fn eq(&self, other: &GenericKind<'tcx>) -> bool
fn eq(&self, other: &GenericKind<'tcx>) -> bool
This method tests for
self
and other
values to be equal, and is used
by ==
.source§impl<'tcx> TypeFoldable<TyCtxt<'tcx>> for GenericKind<'tcx>
impl<'tcx> TypeFoldable<TyCtxt<'tcx>> for GenericKind<'tcx>
source§fn try_fold_with<__F: FallibleTypeFolder<TyCtxt<'tcx>>>(
self,
__folder: &mut __F
) -> Result<Self, __F::Error>
fn try_fold_with<__F: FallibleTypeFolder<TyCtxt<'tcx>>>( self, __folder: &mut __F ) -> Result<Self, __F::Error>
source§fn fold_with<F>(self, folder: &mut F) -> Selfwhere
F: TypeFolder<I>,
fn fold_with<F>(self, folder: &mut F) -> Selfwhere F: TypeFolder<I>,
A convenient alternative to
try_fold_with
for use with infallible
folders. Do not override this method, to ensure coherence with
try_fold_with
.source§impl<'tcx> TypeVisitable<TyCtxt<'tcx>> for GenericKind<'tcx>
impl<'tcx> TypeVisitable<TyCtxt<'tcx>> for GenericKind<'tcx>
source§fn visit_with<__V: TypeVisitor<TyCtxt<'tcx>>>(
&self,
__visitor: &mut __V
) -> ControlFlow<__V::BreakTy>
fn visit_with<__V: TypeVisitor<TyCtxt<'tcx>>>( &self, __visitor: &mut __V ) -> ControlFlow<__V::BreakTy>
impl<'tcx> Copy for GenericKind<'tcx>
impl<'tcx> Eq for GenericKind<'tcx>
impl<'tcx> StructuralEq for GenericKind<'tcx>
impl<'tcx> StructuralPartialEq for GenericKind<'tcx>
Auto Trait Implementations§
impl<'tcx> !RefUnwindSafe for GenericKind<'tcx>
impl<'tcx> Send for GenericKind<'tcx>
impl<'tcx> Sync for GenericKind<'tcx>
impl<'tcx> Unpin for GenericKind<'tcx>
impl<'tcx> !UnwindSafe for GenericKind<'tcx>
Blanket Implementations§
source§impl<T> BorrowMut<T> for Twhere
T: ?Sized,
impl<T> BorrowMut<T> for Twhere T: ?Sized,
source§fn borrow_mut(&mut self) -> &mut T
fn borrow_mut(&mut self) -> &mut T
Mutably borrows from an owned value. Read more
Layout§
Note: Most layout information is completely unstable and may even differ between compilations. The only exception is types with certain repr(...)
attributes. Please see the Rust Reference's “Type Layout” chapter for details on type layout guarantees.
Size: 16 bytes
Size for each variant:
Param
: 12 bytesAlias
: 16 bytes