[][src]Struct moore_vhdl::hir::LitExpr

pub struct LitExpr { /* fields omitted */ }

A literal expression.

Methods

impl LitExpr
[src]

pub fn new_integer(span: Span, value: BigInt) -> LitExpr
[src]

Create a new integer literal expression.

pub fn new_float(span: Span, value: BigRational) -> LitExpr
[src]

Create a new float literal expression.

pub fn value(&self) -> &LitExprValue
[src]

Return the constant value of the literal.

pub fn is_integer(&self) -> bool
[src]

Check if this is an integer literal.

pub fn is_float(&self) -> bool
[src]

Check if this is a floating-point literal.

pub fn integer_value(&self) -> Option<&BigInt>
[src]

Return the literal's integer value, or None if it is not an integer.

pub fn float_value(&self) -> Option<&BigRational>
[src]

Return the literal's float value, or None if it is not an float.

Trait Implementations

impl<'a, 't> Alloc<'a, 'a, LitExpr> for Arenas2<'t> where
    't: 'a, 
[src]

impl<'t> Node<'t> for LitExpr
[src]

fn desc_name(&self) -> String
[src]

A human-readable description of the node, including its name. Read more

impl<'t> Expr2<'t> for LitExpr
[src]

impl Debug for LitExpr
[src]

Auto Trait Implementations

impl Send for LitExpr

impl Sync for LitExpr

Blanket Implementations

impl<T> From for T
[src]

impl<T, U> Into for T where
    U: From<T>, 
[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> Any for T where
    T: 'static + ?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.