pub enum ComponentCoreTypeId {
Sub(CoreTypeId),
Module(ComponentCoreModuleTypeId),
}
Expand description
An identifier for a core type or a core module’s type.
Variants§
Implementations§
source§impl ComponentCoreTypeId
impl ComponentCoreTypeId
sourcepub fn unwrap_sub(self) -> CoreTypeId
pub fn unwrap_sub(self) -> CoreTypeId
Unwrap a CoreTypeId
or panic.
sourcepub fn unwrap_module(self) -> ComponentCoreModuleTypeId
pub fn unwrap_module(self) -> ComponentCoreModuleTypeId
Unwrap a ComponentCoreModuleTypeId
or panic.
source§impl ComponentCoreTypeId
impl ComponentCoreTypeId
sourcepub fn peel_alias(&self, types: &Types) -> Option<ComponentCoreTypeId>
pub fn peel_alias(&self, types: &Types) -> Option<ComponentCoreTypeId>
Peel off one layer of aliasing from this type and return the aliased
inner type, or None
if this type is not aliasing anything.
Trait Implementations§
source§impl Clone for ComponentCoreTypeId
impl Clone for ComponentCoreTypeId
source§fn clone(&self) -> ComponentCoreTypeId
fn clone(&self) -> ComponentCoreTypeId
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 Debug for ComponentCoreTypeId
impl Debug for ComponentCoreTypeId
source§impl From<ComponentCoreModuleTypeId> for ComponentCoreTypeId
impl From<ComponentCoreModuleTypeId> for ComponentCoreTypeId
source§fn from(x: ComponentCoreModuleTypeId) -> ComponentCoreTypeId
fn from(x: ComponentCoreModuleTypeId) -> ComponentCoreTypeId
Converts to this type from the input type.
source§impl From<ComponentCoreTypeId> for AnyTypeId
impl From<ComponentCoreTypeId> for AnyTypeId
source§fn from(x: ComponentCoreTypeId) -> AnyTypeId
fn from(x: ComponentCoreTypeId) -> AnyTypeId
Converts to this type from the input type.
source§impl From<CoreTypeId> for ComponentCoreTypeId
impl From<CoreTypeId> for ComponentCoreTypeId
source§fn from(x: CoreTypeId) -> ComponentCoreTypeId
fn from(x: CoreTypeId) -> ComponentCoreTypeId
Converts to this type from the input type.
source§impl Hash for ComponentCoreTypeId
impl Hash for ComponentCoreTypeId
source§impl Ord for ComponentCoreTypeId
impl Ord for ComponentCoreTypeId
source§fn cmp(&self, other: &ComponentCoreTypeId) -> Ordering
fn cmp(&self, other: &ComponentCoreTypeId) -> Ordering
1.21.0 · source§fn max(self, other: Self) -> Selfwhere
Self: Sized,
fn max(self, other: Self) -> Selfwhere
Self: Sized,
Compares and returns the maximum of two values. Read more
source§impl PartialEq for ComponentCoreTypeId
impl PartialEq for ComponentCoreTypeId
source§impl PartialOrd for ComponentCoreTypeId
impl PartialOrd for ComponentCoreTypeId
source§impl TryFrom<AnyTypeId> for ComponentCoreTypeId
impl TryFrom<AnyTypeId> for ComponentCoreTypeId
source§impl TryFrom<ComponentCoreTypeId> for ComponentCoreModuleTypeId
impl TryFrom<ComponentCoreTypeId> for ComponentCoreModuleTypeId
source§fn try_from(
x: ComponentCoreTypeId,
) -> Result<ComponentCoreModuleTypeId, <ComponentCoreModuleTypeId as TryFrom<ComponentCoreTypeId>>::Error>
fn try_from( x: ComponentCoreTypeId, ) -> Result<ComponentCoreModuleTypeId, <ComponentCoreModuleTypeId as TryFrom<ComponentCoreTypeId>>::Error>
Performs the conversion.
source§impl TryFrom<ComponentCoreTypeId> for CoreTypeId
impl TryFrom<ComponentCoreTypeId> for CoreTypeId
source§fn try_from(
x: ComponentCoreTypeId,
) -> Result<CoreTypeId, <CoreTypeId as TryFrom<ComponentCoreTypeId>>::Error>
fn try_from( x: ComponentCoreTypeId, ) -> Result<CoreTypeId, <CoreTypeId as TryFrom<ComponentCoreTypeId>>::Error>
Performs the conversion.
impl Copy for ComponentCoreTypeId
impl Eq for ComponentCoreTypeId
impl StructuralPartialEq for ComponentCoreTypeId
Auto Trait Implementations§
impl Freeze for ComponentCoreTypeId
impl RefUnwindSafe for ComponentCoreTypeId
impl Send for ComponentCoreTypeId
impl Sync for ComponentCoreTypeId
impl Unpin for ComponentCoreTypeId
impl UnwindSafe for ComponentCoreTypeId
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
source§impl<T> CloneToUninit for Twhere
T: Clone,
impl<T> CloneToUninit for Twhere
T: Clone,
source§unsafe fn clone_to_uninit(&self, dst: *mut T)
unsafe fn clone_to_uninit(&self, dst: *mut T)
🔬This is a nightly-only experimental API. (
clone_to_uninit
)source§impl<Q, K> Comparable<K> for Q
impl<Q, K> Comparable<K> for Q
source§impl<Q, K> Equivalent<K> for Q
impl<Q, K> Equivalent<K> for Q
source§impl<Q, K> Equivalent<K> for Q
impl<Q, K> Equivalent<K> for Q
source§fn equivalent(&self, key: &K) -> bool
fn equivalent(&self, key: &K) -> bool
Compare self to
key
and return true
if they are equal.source§impl<T> IntoEither for T
impl<T> IntoEither for T
source§fn into_either(self, into_left: bool) -> Either<Self, Self>
fn into_either(self, into_left: bool) -> Either<Self, Self>
Converts
self
into a Left
variant of Either<Self, Self>
if into_left
is true
.
Converts self
into a Right
variant of Either<Self, Self>
otherwise. Read moresource§fn into_either_with<F>(self, into_left: F) -> Either<Self, Self>
fn into_either_with<F>(self, into_left: F) -> Either<Self, Self>
Converts
self
into a Left
variant of Either<Self, Self>
if into_left(&self)
returns true
.
Converts self
into a Right
variant of Either<Self, Self>
otherwise. Read more