Trait PrimitiveExt

Source
pub trait PrimitiveExt {
    // Required methods
    fn to_ty<'db>(&self, interner: DbInterner<'db>) -> Ty<'db>;
    fn to_int_ty<'db>(&self, interner: DbInterner<'db>) -> Ty<'db>;
}

Required Methods§

Source

fn to_ty<'db>(&self, interner: DbInterner<'db>) -> Ty<'db>

Source

fn to_int_ty<'db>(&self, interner: DbInterner<'db>) -> Ty<'db>

Implementations on Foreign Types§

Source§

impl PrimitiveExt for Primitive

Source§

fn to_int_ty<'db>(&self, interner: DbInterner<'db>) -> Ty<'db>

Return an integer type matching this primitive. Useful in particular when dealing with enum discriminants.

Source§

fn to_ty<'db>(&self, interner: DbInterner<'db>) -> Ty<'db>

Implementors§