[][src]Enum moore_vhdl::term::Term

pub enum Term<'t> {
    Null,
    Open,
    Others,
    Default,
    IntLit(BigInt),
    FloatLit(BigRational),
    PhysLit(BigIntSpanned<EitherUnit<'t>>),
    StrLit(Name),
    Unresolved(ResolvableName),
    Ident(Spanned<Def>),
    Ident2(Spanned<Def2<'t>>),
    TypeMark(Spanned<TypeMarkRef>),
    Enum(Vec<Spanned<EnumRef>>),
    Enum2(Vec<Spanned<Def2<'t>>>),
    Select(Subterm<'t>, Spanned<ResolvableName>),
    SelectAll(Subterm<'t>),
    Range(Spanned<Dir>, Subterm<'t>, Subterm<'t>),
    RangeSuffix(Subterm<'t>, Subterm<'t>),
    UnboundedRange(Subterm<'t>),
    SubtypeInd(Spanned<TypeMarkRef>, Option<Subterm<'t>>, Option<Subterm<'t>>),
    PrefixParen(Subterm<'t>, Subterm<'t>),
    SuffixParen(Subterm<'t>, Subterm<'t>),
    Paren(Vec<Spanned<Term<'t>>>),
    Aggregate(Vec<(Vec<Spanned<Term<'t>>>, Spanned<Term<'t>>)>),
    Unary(Spanned<UnaryOp>, Subterm<'t>),
    Binary(Spanned<BinaryOp>, Subterm<'t>, Subterm<'t>),
    Qual(Subterm<'t>, Subterm<'t>),
    New(Subterm<'t>),
}

A term.

This is a generalization of expressions and names in VHDL. It allows various parts of the AST to be mapped to a common data structure, and then remapped to the desired output structure. This is useful for example if the parser processes a subtype indication as an expression.

Variants

Null

A term of the form null.

Open

A term of the form open.

Others

A term of the form others.

Default

A term of the form default.

IntLit(BigInt)

An integer literal.

FloatLit(BigRational)

A floating point literal.

PhysLit(BigIntSpanned<EitherUnit<'t>>)

A physical literal.

StrLit(Name)

A bit string literal.

Unresolved(ResolvableName)

An unresolved name.

Ident(Spanned<Def>)

A term that refers to a definition.

Ident2(Spanned<Def2<'t>>)

A term that refers to a definition.

TypeMark(Spanned<TypeMarkRef>)

A term that refers to a type or subtype definition.

A term that refers to an enum variant.

Enum2(Vec<Spanned<Def2<'t>>>)

A term that refers to an enum variant.

A term of the form T.<name>.

SelectAll(Subterm<'t>)

A term of the form T.all.

Range(Spanned<Dir>, Subterm<'t>, Subterm<'t>)

A term of the form T (to|downto) T.

RangeSuffix(Subterm<'t>, Subterm<'t>)

A term of the form T range T.

UnboundedRange(Subterm<'t>)

A term of the form T range <>.

SubtypeInd(Spanned<TypeMarkRef>, Option<Subterm<'t>>, Option<Subterm<'t>>)

A term of the form [T] <type_mark> [T]. The first optional subterm is the resolution indication, the second is the constraint.

PrefixParen(Subterm<'t>, Subterm<'t>)

A term of the form (T) T.

SuffixParen(Subterm<'t>, Subterm<'t>)

A term of the form T (T).

Paren(Vec<Spanned<Term<'t>>>)

A term of the form (T,T,…).

Aggregate(Vec<(Vec<Spanned<Term<'t>>>, Spanned<Term<'t>>)>)

A term of the form (T|T|… => T, T|T|… => T, …).

Unary(Spanned<UnaryOp>, Subterm<'t>)

A term of the form op T.

Binary(Spanned<BinaryOp>, Subterm<'t>, Subterm<'t>)

A term of the form T op T.

Qual(Subterm<'t>, Subterm<'t>)

A term of the form T'T.

New(Subterm<'t>)

A term of the form new T.

Trait Implementations

impl<'t> Debug for Term<'t>[src]

impl<'t> Eq for Term<'t>[src]

impl<'t> PartialEq<Term<'t>> for Term<'t>[src]

impl<'t> StructuralEq for Term<'t>[src]

impl<'t> StructuralPartialEq for Term<'t>[src]

Auto Trait Implementations

impl<'t> !RefUnwindSafe for Term<'t>

impl<'t> !Send for Term<'t>

impl<'t> !Sync for Term<'t>

impl<'t> Unpin for Term<'t>

impl<'t> !UnwindSafe for Term<'t>

Blanket Implementations

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

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

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

impl<T> From<T> for T[src]

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

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

type Error = Infallible

The type returned in the event of a conversion error.

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

type Error = <U as TryFrom<T>>::Error

The type returned in the event of a conversion error.