[][src]Enum full_moon::ast::Field

pub enum Field<'a> {
    ExpressionKey {
        brackets: ContainedSpan<'a>,
        key: Expression<'a>,
        equal: Cow<'a, TokenReference<'a>>,
        value: Expression<'a>,
    },
    NameKey {
        key: Cow<'a, TokenReference<'a>>,
        equal: Cow<'a, TokenReference<'a>>,
        value: Expression<'a>,
    },
    NoKey(Expression<'a>),
}

Fields of a TableConstructor

Variants

ExpressionKey

A key in the format of [expression] = value

Fields of ExpressionKey

brackets: ContainedSpan<'a>

The [...] part of [expression] = value

key: Expression<'a>

The expression part of [expression] = value

equal: Cow<'a, TokenReference<'a>>

The = part of [expression] = value

value: Expression<'a>

The value part of [expression] = value

NameKey

A key in the format of name = value

Fields of NameKey

key: Cow<'a, TokenReference<'a>>

The name part of name = value

equal: Cow<'a, TokenReference<'a>>

The = part of name = value

value: Expression<'a>

The value part of name = value

NoKey(Expression<'a>)

A field with no key, just a value (such as "a" in { "a" })

Trait Implementations

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

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

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

impl<'a> Display for Field<'a>[src]

impl<'a> Node<'a> for Field<'a>[src]

impl<'a> Owned for Field<'a>[src]

type Owned = Field<'static>

What an owned version of the object looks like. Usually contains a 'static lifetime.

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

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

impl<'a> StructuralPartialEq for Field<'a>[src]

Auto Trait Implementations

impl<'a> RefUnwindSafe for Field<'a>

impl<'a> Send for Field<'a>

impl<'a> Sync for Field<'a>

impl<'a> Unpin for Field<'a>

impl<'a> UnwindSafe for Field<'a>

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> DeserializeOwned for T where
    T: for<'de> Deserialize<'de>, 
[src]

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

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

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

type Owned = T

The resulting type after obtaining ownership.

impl<T> ToString for T where
    T: Display + ?Sized
[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.