Enum moore_vhdl::score::TypeCtx
source · [−]pub enum TypeCtx<'ctx> {
Type(&'ctx Ty),
TypeOf(TypedNodeRef),
Inherit(NodeId),
}
Expand description
The type requirements imposed upon an expression by its context. This is needed for overload resolution, where the type of the overload to be picked is determined by the context in which the expression appears.
Variants
Type(&'ctx Ty)
The exact type the expression must have.
TypeOf(TypedNodeRef)
The node whose type the expression must match.
Inherit(NodeId)
The node whose type context the expression must inherit.
Trait Implementations
sourceimpl<'ctx, T> From<T> for TypeCtx<'ctx> where
TypedNodeRef: From<T>,
impl<'ctx, T> From<T> for TypeCtx<'ctx> where
TypedNodeRef: From<T>,
impl<'ctx> Copy for TypeCtx<'ctx>
impl<'ctx> Eq for TypeCtx<'ctx>
impl<'ctx> StructuralEq for TypeCtx<'ctx>
impl<'ctx> StructuralPartialEq for TypeCtx<'ctx>
Auto Trait Implementations
impl<'ctx> RefUnwindSafe for TypeCtx<'ctx>
impl<'ctx> Send for TypeCtx<'ctx>
impl<'ctx> Sync for TypeCtx<'ctx>
impl<'ctx> Unpin for TypeCtx<'ctx>
impl<'ctx> UnwindSafe for TypeCtx<'ctx>
Blanket Implementations
sourceimpl<T> BorrowMut<T> for T where
T: ?Sized,
impl<T> BorrowMut<T> for T where
T: ?Sized,
const: unstable · sourcepub fn borrow_mut(&mut self) -> &mut T
pub fn borrow_mut(&mut self) -> &mut T
Mutably borrows from an owned value. Read more
impl<T> Pointable for T
impl<T> Pointable for T
sourceimpl<T> ToOwned for T where
T: Clone,
impl<T> ToOwned for T where
T: Clone,
type Owned = T
type Owned = T
The resulting type after obtaining ownership.
sourcepub fn to_owned(&self) -> T
pub fn to_owned(&self) -> T
Creates owned data from borrowed data, usually by cloning. Read more
sourcepub fn clone_into(&self, target: &mut T)
pub fn clone_into(&self, target: &mut T)
🔬 This is a nightly-only experimental API. (
toowned_clone_into
)Uses borrowed data to replace owned data, usually by cloning. Read more