Skip to main content

UnevaluatedConst

Type Alias UnevaluatedConst 

Source
pub type UnevaluatedConst<I> = Alias<I, UnevaluatedConstKind<I>>;

Aliased Type§

pub struct UnevaluatedConst<I> {
    pub kind: UnevaluatedConstKind<I>,
    pub args: <I as Interner>::GenericArgs,
    pub(crate) _use_alias_new_instead: (),
}

Fields§

§kind: UnevaluatedConstKind<I>§args: <I as Interner>::GenericArgs

The 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> UnevaluatedConst<I>

Source

pub fn new( interner: I, kind: UnevaluatedConstKind<I>, args: I::GenericArgs, ) -> UnevaluatedConst<I>

Source

pub fn type_of(self, interner: I) -> Unnormalized<I, I::Ty>

Trait Implementations§

Source§

impl<I: Interner> IntoDiagArg for UnevaluatedConst<I>

Source§

fn into_diag_arg(self, path: &mut Option<PathBuf>) -> DiagArgValue

Convert Self into a DiagArgValue suitable for rendering in a diagnostic. Read more
Source§

impl<I: Interner> Relate<I> for UnevaluatedConst<I>

Layout§

Note: Encountered an error during type layout; the type failed to be normalized.