[−][src]Trait moore_vhdl::ty2::Type
An interface for dealing with types.
This is the main type trait, which all types and subtypes implement.
Required methods
pub fn is_scalar(&self) -> bool
[src]
Check if this is a scalar type.
Enumeration, integer, floating-point, and physical types are scalar.
pub fn is_discrete(&self) -> bool
[src]
Check if this is a discrete type.
Enumeration and integer types are discrete.
pub fn is_numeric(&self) -> bool
[src]
Check if this is a numeric type.
Integer, floating-point, and physical types are numeric.
pub fn is_composite(&self) -> bool
[src]
Check if this is a composite type.
Array and record types are composite.
pub fn into_owned<'a>(self) -> OwnedType<'a> where
Self: 'a,
[src]
Self: 'a,
Convert into an owned type.
pub fn to_owned<'a>(&self) -> OwnedType<'a> where
Self: 'a,
[src]
Self: 'a,
Clone this type.
pub fn as_any(&self) -> AnyType<'_>
[src]
Converts from &Type
to AnyType
.
Provided methods
pub fn is_equal(&self, other: &dyn Type) -> bool
[src]
Check if two types are equal.
pub fn is_implicitly_castable(&self, _into: &dyn Type) -> bool
[src]
Check if the type can be implicitly cast to another.
Trait Implementations
impl<'t> AllocOwned<'t, 't, dyn Type + 't> for TypeArena<'t>
[src]
pub fn alloc_owned(&'t self, value: OwnedType<'t>) -> &'t dyn Type
[src]
pub fn maybe_alloc(&'a self, value: Cow<'t, T>) -> &'t T
[src]
pub fn force_alloc(&'a self, value: Cow<'_, T>) -> &'t T
[src]
impl<'t> Borrow<dyn Type + 't> for OwnedType<'t>
[src]
impl<'a> Eq for dyn Type + 'a
[src]
impl<'a> PartialEq<dyn Type + 'a> for dyn Type + 'a
[src]
pub fn eq(&self, other: &dyn Type) -> bool
[src]
#[must_use]pub fn ne(&self, other: &Rhs) -> bool
1.0.0[src]
impl<'t> ToOwned for dyn Type + 't
[src]
Implementors
impl Type for EnumBasetype
[src]
pub fn is_scalar(&self) -> bool
[src]
pub fn is_discrete(&self) -> bool
[src]
pub fn is_numeric(&self) -> bool
[src]
pub fn is_composite(&self) -> bool
[src]
pub fn as_any(&self) -> AnyType<'_>
[src]
pub fn into_owned<'a>(self) -> OwnedType<'a> where
Self: 'a,
[src]
Self: 'a,
pub fn to_owned<'a>(&self) -> OwnedType<'a> where
Self: 'a,
[src]
Self: 'a,
impl Type for FloatingBasetype
[src]
pub fn is_scalar(&self) -> bool
[src]
pub fn is_discrete(&self) -> bool
[src]
pub fn is_numeric(&self) -> bool
[src]
pub fn is_composite(&self) -> bool
[src]
pub fn as_any(&self) -> AnyType<'_>
[src]
pub fn into_owned<'a>(self) -> OwnedType<'a> where
Self: 'a,
[src]
Self: 'a,
pub fn to_owned<'a>(&self) -> OwnedType<'a> where
Self: 'a,
[src]
Self: 'a,
impl Type for IntegerBasetype
[src]
pub fn is_scalar(&self) -> bool
[src]
pub fn is_discrete(&self) -> bool
[src]
pub fn is_numeric(&self) -> bool
[src]
pub fn is_composite(&self) -> bool
[src]
pub fn as_any(&self) -> AnyType<'_>
[src]
pub fn into_owned<'a>(self) -> OwnedType<'a> where
Self: 'a,
[src]
Self: 'a,
pub fn to_owned<'a>(&self) -> OwnedType<'a> where
Self: 'a,
[src]
Self: 'a,
impl Type for NullType
[src]
pub fn is_scalar(&self) -> bool
[src]
pub fn is_discrete(&self) -> bool
[src]
pub fn is_numeric(&self) -> bool
[src]
pub fn is_composite(&self) -> bool
[src]
pub fn into_owned<'a>(self) -> OwnedType<'a> where
Self: 'a,
[src]
Self: 'a,
pub fn to_owned<'a>(&self) -> OwnedType<'a> where
Self: 'a,
[src]
Self: 'a,
pub fn as_any(&self) -> AnyType<'_>
[src]
impl Type for PhysicalBasetype
[src]
pub fn is_scalar(&self) -> bool
[src]
pub fn is_discrete(&self) -> bool
[src]
pub fn is_numeric(&self) -> bool
[src]
pub fn is_composite(&self) -> bool
[src]
pub fn as_any(&self) -> AnyType<'_>
[src]
pub fn into_owned<'a>(self) -> OwnedType<'a> where
Self: 'a,
[src]
Self: 'a,
pub fn to_owned<'a>(&self) -> OwnedType<'a> where
Self: 'a,
[src]
Self: 'a,
impl Type for UniversalIntegerType
[src]
pub fn is_scalar(&self) -> bool
[src]
pub fn is_discrete(&self) -> bool
[src]
pub fn is_numeric(&self) -> bool
[src]
pub fn is_composite(&self) -> bool
[src]
pub fn as_any(&self) -> AnyType<'_>
[src]
pub fn into_owned<'a>(self) -> OwnedType<'a> where
Self: 'a,
[src]
Self: 'a,
pub fn to_owned<'a>(&self) -> OwnedType<'a> where
Self: 'a,
[src]
Self: 'a,
impl Type for UniversalRealType
[src]
pub fn is_scalar(&self) -> bool
[src]
pub fn is_discrete(&self) -> bool
[src]
pub fn is_numeric(&self) -> bool
[src]
pub fn is_composite(&self) -> bool
[src]
pub fn as_any(&self) -> AnyType<'_>
[src]
pub fn into_owned<'a>(self) -> OwnedType<'a> where
Self: 'a,
[src]
Self: 'a,
pub fn to_owned<'a>(&self) -> OwnedType<'a> where
Self: 'a,
[src]
Self: 'a,
impl<'t> Type for AccessType<'t>
[src]
pub fn is_scalar(&self) -> bool
[src]
pub fn is_discrete(&self) -> bool
[src]
pub fn is_numeric(&self) -> bool
[src]
pub fn is_composite(&self) -> bool
[src]
pub fn into_owned<'a>(self) -> OwnedType<'a> where
Self: 'a,
[src]
Self: 'a,
pub fn to_owned<'a>(&self) -> OwnedType<'a> where
Self: 'a,
[src]
Self: 'a,
pub fn as_any(&self) -> AnyType<'_>
[src]
impl<'t> Type for ArrayType<'t>
[src]
pub fn is_scalar(&self) -> bool
[src]
pub fn is_discrete(&self) -> bool
[src]
pub fn is_numeric(&self) -> bool
[src]
pub fn is_composite(&self) -> bool
[src]
pub fn into_owned<'a>(self) -> OwnedType<'a> where
Self: 'a,
[src]
Self: 'a,
pub fn to_owned<'a>(&self) -> OwnedType<'a> where
Self: 'a,
[src]
Self: 'a,
pub fn as_any(&self) -> AnyType<'_>
[src]
impl<'t> Type for TypeDecl<'t>
[src]
pub fn is_scalar(&self) -> bool
[src]
pub fn is_discrete(&self) -> bool
[src]
pub fn is_numeric(&self) -> bool
[src]
pub fn is_composite(&self) -> bool
[src]
pub fn into_owned<'a>(self) -> OwnedType<'a> where
Self: 'a,
[src]
Self: 'a,
pub fn to_owned<'a>(&self) -> OwnedType<'a> where
Self: 'a,
[src]
Self: 'a,
pub fn as_any(&self) -> AnyType<'_>
[src]
impl<'t> Type for TypeMark<'t>
[src]
pub fn is_scalar(&self) -> bool
[src]
pub fn is_discrete(&self) -> bool
[src]
pub fn is_numeric(&self) -> bool
[src]
pub fn is_composite(&self) -> bool
[src]
pub fn into_owned<'a>(self) -> OwnedType<'a> where
Self: 'a,
[src]
Self: 'a,
pub fn to_owned<'a>(&self) -> OwnedType<'a> where
Self: 'a,
[src]
Self: 'a,
pub fn as_any(&self) -> AnyType<'_>
[src]
impl<'t> Type for EnumSubtype<'t>
[src]
pub fn is_scalar(&self) -> bool
[src]
pub fn is_discrete(&self) -> bool
[src]
pub fn is_numeric(&self) -> bool
[src]
pub fn is_composite(&self) -> bool
[src]
pub fn as_any(&self) -> AnyType<'_>
[src]
pub fn into_owned<'a>(self) -> OwnedType<'a> where
Self: 'a,
[src]
Self: 'a,
pub fn to_owned<'a>(&self) -> OwnedType<'a> where
Self: 'a,
[src]
Self: 'a,
impl<'t> Type for FloatingSubtype<'t>
[src]
pub fn is_scalar(&self) -> bool
[src]
pub fn is_discrete(&self) -> bool
[src]
pub fn is_numeric(&self) -> bool
[src]
pub fn is_composite(&self) -> bool
[src]
pub fn as_any(&self) -> AnyType<'_>
[src]
pub fn into_owned<'a>(self) -> OwnedType<'a> where
Self: 'a,
[src]
Self: 'a,
pub fn to_owned<'a>(&self) -> OwnedType<'a> where
Self: 'a,
[src]
Self: 'a,
impl<'t> Type for IntegerSubtype<'t>
[src]
pub fn is_scalar(&self) -> bool
[src]
pub fn is_discrete(&self) -> bool
[src]
pub fn is_numeric(&self) -> bool
[src]
pub fn is_composite(&self) -> bool
[src]
pub fn as_any(&self) -> AnyType<'_>
[src]
pub fn into_owned<'a>(self) -> OwnedType<'a> where
Self: 'a,
[src]
Self: 'a,
pub fn to_owned<'a>(&self) -> OwnedType<'a> where
Self: 'a,
[src]
Self: 'a,
impl<'t> Type for PhysicalSubtype<'t>
[src]
pub fn is_scalar(&self) -> bool
[src]
pub fn is_discrete(&self) -> bool
[src]
pub fn is_numeric(&self) -> bool
[src]
pub fn is_composite(&self) -> bool
[src]
pub fn as_any(&self) -> AnyType<'_>
[src]
pub fn into_owned<'a>(self) -> OwnedType<'a> where
Self: 'a,
[src]
Self: 'a,
pub fn to_owned<'a>(&self) -> OwnedType<'a> where
Self: 'a,
[src]
Self: 'a,