[−][src]Struct gluon_base::types::Alias
An alias is wrapper around Type::Alias
, allowing it to be cheaply converted to a type and
dereferenced to AliasRef
Methods
impl<Id, T> Alias<Id, T> where
T: From<Type<Id, T>>,
[src]
T: From<Type<Id, T>>,
pub fn new(name: Id, args: Vec<Generic<Id>>, typ: T) -> Alias<Id, T>
[src]
pub fn group(group: Vec<AliasData<Id, T>>) -> Vec<Alias<Id, T>>
[src]
impl<Id, T> Alias<Id, T>
[src]
impl<Id, T> Alias<Id, T> where
T: TypeExt<Id = Id> + Clone,
Id: Clone + PartialEq,
[src]
T: TypeExt<Id = Id> + Clone,
Id: Clone + PartialEq,
pub fn typ(
&self,
interner: &mut impl TypeContext<Id, T>
) -> Cow<T>
[src]
&self,
interner: &mut impl TypeContext<Id, T>
) -> Cow<T>
Returns the actual type of the alias
pub fn unpack_canonical_alias<'b>(
&'b self,
canonical_alias_type: &'b T,
un_alias: impl FnMut(&'b AliasRef<Id, T>) -> Cow<'b, T>
) -> (Cow<'b, [Generic<Id>]>, &'b AliasRef<Id, T>, Cow<'b, T>)
[src]
&'b self,
canonical_alias_type: &'b T,
un_alias: impl FnMut(&'b AliasRef<Id, T>) -> Cow<'b, T>
) -> (Cow<'b, [Generic<Id>]>, &'b AliasRef<Id, T>, Cow<'b, T>)
Methods from Deref<Target = AliasRef<Id, T>>
pub fn try_get_alias_mut(&mut self) -> Option<&mut AliasData<Id, T>>
[src]
pub fn typ(
&self,
interner: &mut impl TypeContext<Id, T>
) -> Cow<T>
[src]
&self,
interner: &mut impl TypeContext<Id, T>
) -> Cow<T>
Trait Implementations
impl<Id: Eq, T: Eq> Eq for Alias<Id, T>
[src]
impl<Id: Clone, T: Clone> Clone for Alias<Id, T>
[src]
fn clone(&self) -> Alias<Id, T>
[src]
fn clone_from(&mut self, source: &Self)
1.0.0[src]
Performs copy-assignment from source
. Read more
impl<Id: PartialEq, T: PartialEq> PartialEq<Alias<Id, T>> for Alias<Id, T>
[src]
impl<Id, T> AsRef<T> for Alias<Id, T>
[src]
impl<Id, T> From<AliasData<Id, T>> for Alias<Id, T> where
T: From<Type<Id, T>>,
[src]
T: From<Type<Id, T>>,
impl<Id, T> From<AliasRef<Id, T>> for Alias<Id, T> where
T: From<Type<Id, T>>,
[src]
T: From<Type<Id, T>>,
impl<Id, T> DerefMut for Alias<Id, T> where
T: DerefMut<Target = Type<Id, T>>,
[src]
T: DerefMut<Target = Type<Id, T>>,
impl<Id, T> Deref for Alias<Id, T> where
T: Deref<Target = Type<Id, T>>,
[src]
T: Deref<Target = Type<Id, T>>,
type Target = AliasRef<Id, T>
The resulting type after dereferencing.
fn deref(&self) -> &Self::Target
[src]
impl<Id: Hash, T: Hash> Hash for Alias<Id, T>
[src]
fn hash<__HIdT: Hasher>(&self, state: &mut __HIdT)
[src]
fn hash_slice<H>(data: &[Self], state: &mut H) where
H: Hasher,
1.3.0[src]
H: Hasher,
Feeds a slice of this type into the given [Hasher
]. Read more
impl<Id: Debug, T: Debug> Debug for Alias<Id, T>
[src]
Auto Trait Implementations
impl<Id, T> Send for Alias<Id, T> where
Id: Send,
T: Send,
Id: Send,
T: Send,
impl<Id, T> Sync for Alias<Id, T> where
Id: Sync,
T: Sync,
Id: Sync,
T: Sync,
Blanket Implementations
impl<T, U> Into for T where
U: From<T>,
[src]
U: From<T>,
impl<T> ToOwned for T where
T: Clone,
[src]
T: Clone,
impl<T> From for T
[src]
impl<T, U> TryFrom for T where
U: Into<T>,
[src]
U: Into<T>,
type Error = !
🔬 This is a nightly-only experimental API. (
try_from
)The type returned in the event of a conversion error.
fn try_from(value: U) -> Result<T, <T as TryFrom<U>>::Error>
[src]
impl<T> Borrow for T where
T: ?Sized,
[src]
T: ?Sized,
impl<T, U> TryInto for T where
U: TryFrom<T>,
[src]
U: TryFrom<T>,
type Error = <U as TryFrom<T>>::Error
🔬 This is a nightly-only experimental API. (
try_from
)The type returned in the event of a conversion error.
fn try_into(self) -> Result<U, <U as TryFrom<T>>::Error>
[src]
impl<T> Any for T where
T: 'static + ?Sized,
[src]
T: 'static + ?Sized,
impl<T> BorrowMut for T where
T: ?Sized,
[src]
T: ?Sized,