pub enum TypeOwnerId {
FunctionId(FunctionId),
StaticId(StaticId),
ConstId(ConstId),
InTypeConstId(InTypeConstId),
AdtId(AdtId),
TraitId(TraitId),
TraitAliasId(TraitAliasId),
TypeAliasId(TypeAliasId),
ImplId(ImplId),
EnumVariantId(EnumVariantId),
}
Expand description
Something that holds types, required for the current const arg lowering implementation as they need to be able to query where they are defined.
Variants§
FunctionId(FunctionId)
StaticId(StaticId)
ConstId(ConstId)
InTypeConstId(InTypeConstId)
AdtId(AdtId)
TraitId(TraitId)
TraitAliasId(TraitAliasId)
TypeAliasId(TypeAliasId)
ImplId(ImplId)
EnumVariantId(EnumVariantId)
Trait Implementations§
source§impl Clone for TypeOwnerId
impl Clone for TypeOwnerId
source§fn clone(&self) -> TypeOwnerId
fn clone(&self) -> TypeOwnerId
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 TypeOwnerId
impl Debug for TypeOwnerId
source§impl From<AdtId> for TypeOwnerId
impl From<AdtId> for TypeOwnerId
source§fn from(it: AdtId) -> TypeOwnerId
fn from(it: AdtId) -> TypeOwnerId
Converts to this type from the input type.
source§impl From<ConstId> for TypeOwnerId
impl From<ConstId> for TypeOwnerId
source§fn from(it: ConstId) -> TypeOwnerId
fn from(it: ConstId) -> TypeOwnerId
Converts to this type from the input type.
source§impl From<DefWithBodyId> for TypeOwnerId
impl From<DefWithBodyId> for TypeOwnerId
source§fn from(value: DefWithBodyId) -> Self
fn from(value: DefWithBodyId) -> Self
Converts to this type from the input type.
source§impl From<EnumVariantId> for TypeOwnerId
impl From<EnumVariantId> for TypeOwnerId
source§fn from(it: EnumVariantId) -> TypeOwnerId
fn from(it: EnumVariantId) -> TypeOwnerId
Converts to this type from the input type.
source§impl From<FunctionId> for TypeOwnerId
impl From<FunctionId> for TypeOwnerId
source§fn from(it: FunctionId) -> TypeOwnerId
fn from(it: FunctionId) -> TypeOwnerId
Converts to this type from the input type.
source§impl From<GenericDefId> for TypeOwnerId
impl From<GenericDefId> for TypeOwnerId
source§fn from(value: GenericDefId) -> Self
fn from(value: GenericDefId) -> Self
Converts to this type from the input type.
source§impl From<ImplId> for TypeOwnerId
impl From<ImplId> for TypeOwnerId
source§fn from(it: ImplId) -> TypeOwnerId
fn from(it: ImplId) -> TypeOwnerId
Converts to this type from the input type.
source§impl From<InTypeConstId> for TypeOwnerId
impl From<InTypeConstId> for TypeOwnerId
source§fn from(it: InTypeConstId) -> TypeOwnerId
fn from(it: InTypeConstId) -> TypeOwnerId
Converts to this type from the input type.
source§impl From<StaticId> for TypeOwnerId
impl From<StaticId> for TypeOwnerId
source§fn from(it: StaticId) -> TypeOwnerId
fn from(it: StaticId) -> TypeOwnerId
Converts to this type from the input type.
source§impl From<TraitAliasId> for TypeOwnerId
impl From<TraitAliasId> for TypeOwnerId
source§fn from(it: TraitAliasId) -> TypeOwnerId
fn from(it: TraitAliasId) -> TypeOwnerId
Converts to this type from the input type.
source§impl From<TraitId> for TypeOwnerId
impl From<TraitId> for TypeOwnerId
source§fn from(it: TraitId) -> TypeOwnerId
fn from(it: TraitId) -> TypeOwnerId
Converts to this type from the input type.
source§impl From<TypeAliasId> for TypeOwnerId
impl From<TypeAliasId> for TypeOwnerId
source§fn from(it: TypeAliasId) -> TypeOwnerId
fn from(it: TypeAliasId) -> TypeOwnerId
Converts to this type from the input type.
source§impl HasModule for TypeOwnerId
impl HasModule for TypeOwnerId
source§fn module(&self, db: &dyn DefDatabase) -> ModuleId
fn module(&self, db: &dyn DefDatabase) -> ModuleId
Returns the enclosing module this thing is defined within.
source§fn krate(&self, db: &dyn DefDatabase) -> CrateId
fn krate(&self, db: &dyn DefDatabase) -> CrateId
Returns the crate this thing is defined within.
source§impl HasResolver for TypeOwnerId
impl HasResolver for TypeOwnerId
source§fn resolver(self, db: &dyn DefDatabase) -> Resolver
fn resolver(self, db: &dyn DefDatabase) -> Resolver
Builds a resolver for type references inside this def.
source§impl Hash for TypeOwnerId
impl Hash for TypeOwnerId
source§impl PartialEq for TypeOwnerId
impl PartialEq for TypeOwnerId
impl Copy for TypeOwnerId
impl Eq for TypeOwnerId
impl StructuralPartialEq for TypeOwnerId
Auto Trait Implementations§
impl Freeze for TypeOwnerId
impl RefUnwindSafe for TypeOwnerId
impl Send for TypeOwnerId
impl Sync for TypeOwnerId
impl Unpin for TypeOwnerId
impl UnwindSafe for TypeOwnerId
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
)§impl<Q, K> Equivalent<K> for Q
impl<Q, K> Equivalent<K> for Q
§fn equivalent(&self, key: &K) -> bool
fn equivalent(&self, key: &K) -> bool
Checks if this value is equivalent to the given key. Read more
§impl<Q, K> Equivalent<K> for Q
impl<Q, K> Equivalent<K> for Q
§fn equivalent(&self, key: &K) -> bool
fn equivalent(&self, key: &K) -> bool
Compare self to
key
and return true
if they are equal.§impl<T> Instrument for T
impl<T> Instrument for T
§fn instrument(self, span: Span) -> Instrumented<Self>
fn instrument(self, span: Span) -> Instrumented<Self>
§fn in_current_span(self) -> Instrumented<Self>
fn in_current_span(self) -> Instrumented<Self>
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