pub type AliasConst<I> = Alias<I, AliasConstKind<I>>;Aliased Type§
pub struct AliasConst<I> {
pub kind: AliasConstKind<I>,
pub args: <I as Interner>::GenericArgs,
pub(crate) _use_alias_new_instead: (),
}Fields§
§kind: AliasConstKind<I>§args: <I as Interner>::GenericArgsThe parameters of the associated, opaque, or constant alias.
For a projection, these are the generic parameters for the trait and the GAT parameters, if there are any.
For an inherent projection, they consist of the self type and the GAT parameters, if there are any.
For RPIT the generic parameters are for the generics of the function, while for TAIT it is used for the generic parameters of the alias.
_use_alias_new_instead: ()This field exists to prevent the creation of Alias without using the relevant constructor.
Implementations§
Source§impl<I: Interner> AliasConst<I>
impl<I: Interner> AliasConst<I>
pub fn new( interner: I, kind: AliasConstKind<I>, args: I::GenericArgs, ) -> AliasConst<I>
pub fn type_of(self, interner: I) -> Unnormalized<I, I::Ty>
Trait Implementations§
Source§impl<I: Interner> IntoDiagArg for AliasConst<I>
impl<I: Interner> IntoDiagArg for AliasConst<I>
Source§fn into_diag_arg(self, path: &mut Option<PathBuf>) -> DiagArgValue
fn into_diag_arg(self, path: &mut Option<PathBuf>) -> DiagArgValue
Source§impl<I: Interner> Relate<I> for AliasConst<I>
impl<I: Interner> Relate<I> for AliasConst<I>
fn relate<R: TypeRelation<I>>( relation: &mut R, a: AliasConst<I>, b: AliasConst<I>, ) -> RelateResult<I, AliasConst<I>>
Layout§
Note: Encountered an error during type layout; the type failed to be normalized.