[][src]Enum full_moon::ast::Value

pub enum Value<'a> {
    Function(FunctionBody<'a>),
    FunctionCall(Box<FunctionCall<'a>>),
    TableConstructor(Box<TableConstructor<'a>>),
    Number(Cow<'a, Token<'a>>),
    ParseExpression(Box<Expression<'a>>),
    String(Cow<'a, Token<'a>>),
    Symbol(Cow<'a, Token<'a>>),
    Var(Box<Var<'a>>),
}

Values that cannot be used standalone, but as part of things such as statements

Variants

Function(FunctionBody<'a>)

An anonymous function, such as function() end)

FunctionCall(Box<FunctionCall<'a>>)

A call of a function, such as call()

TableConstructor(Box<TableConstructor<'a>>)

A table constructor, such as { 1, 2, 3 }

Number(Cow<'a, Token<'a>>)

A number token, such as 3.3

ParseExpression(Box<Expression<'a>>)

An expression between parentheses, such as (3 + 2)

String(Cow<'a, Token<'a>>)

A string token, such as "hello"

Symbol(Cow<'a, Token<'a>>)

A symbol, such as true

Var(Box<Var<'a>>)

A more complex value, such as call().x

Trait Implementations

impl<'a> PartialEq<Value<'a>> for Value<'a>[src]

impl<'a> Clone for Value<'a>[src]

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

Performs copy-assignment from source. Read more

impl<'a> Debug for Value<'a>[src]

impl<'a> Serialize for Value<'a>[src]

impl<'de: 'a, 'a> Deserialize<'de> for Value<'a>[src]

Auto Trait Implementations

impl<'a> Send for Value<'a>

impl<'a> Sync for Value<'a>

Blanket Implementations

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

type Owned = T

The resulting type after obtaining ownership.

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

impl<T> From<T> for 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.

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

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

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

impl<T> DeserializeOwned for T where
    T: Deserialize<'de>, 
[src]