[][src]Struct moore_vhdl::ty2::UniversalRealType

pub struct UniversalRealType;

A universal real.

This is not strictly a separate type, but rather defined by the standard as the real type with the largest range. However since we can represent arbitrary numbers as f64, we use this special marker type.

Example

use moore_vhdl::ty2::{Type, UniversalRealType};

let ty = UniversalRealType;

assert_eq!(format!("{}", ty), "{universal real}");
assert_eq!(ty.is_scalar(), true);
assert_eq!(ty.is_discrete(), false);
assert_eq!(ty.is_numeric(), true);

Trait Implementations

impl Type for UniversalRealType
[src]

fn is_equal(&self, other: &dyn Type) -> bool
[src]

Check if two types are equal.

fn is_implicitly_castable(&self, _into: &dyn Type) -> bool
[src]

Check if the type can be implicitly cast to another.

impl FloatingType for UniversalRealType
[src]

fn resolution_func(&self) -> Option<usize>
[src]

The resolution function associated with this type.

fn as_basetype(&self) -> Option<&FloatingBasetype>
[src]

Returns Some if self is an FloatingBasetype, None otherwise.

fn as_subtype(&self) -> Option<&FloatingSubtype>
[src]

Returns Some if self is an FloatingSubtype, None otherwise.

fn unwrap_basetype(&self) -> &FloatingBasetype
[src]

Returns an &FloatingBasetype or panics if the type is not a basetype.

fn unwrap_subtype(&self) -> &FloatingSubtype
[src]

Returns an &FloatingSubtype or panics if the type is not a subtype.

impl Copy for UniversalRealType
[src]

impl Clone for UniversalRealType
[src]

fn clone_from(&mut self, source: &Self)
1.0.0
[src]

Performs copy-assignment from source. Read more

impl Debug for UniversalRealType
[src]

impl Display for UniversalRealType
[src]

Auto Trait Implementations

Blanket Implementations

impl<T> From for T
[src]

impl<T, U> Into for T where
    U: From<T>, 
[src]

impl<T> ToOwned for T where
    T: Clone
[src]

type Owned = T

impl<T> ToString for T where
    T: Display + ?Sized
[src]

impl<T, U> TryFrom for T where
    T: From<U>, 
[src]

type Error = !

🔬 This is a nightly-only experimental API. (try_from)

The type returned in the event of a conversion error.

impl<T> Borrow for T where
    T: ?Sized
[src]

impl<T> BorrowMut for T where
    T: ?Sized
[src]

impl<T, U> TryInto for T where
    U: TryFrom<T>, 
[src]

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.

impl<T> Any for T where
    T: 'static + ?Sized
[src]