Enum macrohelper::Lit []

pub enum Lit {
    Str(StringStrStyle),
    ByteStr(Vec<u8>, StrStyle),
    Byte(u8),
    Char(char),
    Int(u64IntTy),
    Float(StringFloatTy),
    Bool(bool),
}

Literal kind.

E.g. "foo", 42, 12.34 or bool

Variants

A string literal ("foo")

A byte string (b"foo")

A byte char (b'f')

A character literal ('a')

An integer literal (1)

A float literal (1f64 or 1E10f64 or 1.0E10)

A boolean literal

Trait Implementations

impl Debug for Lit

Formats the value using the given formatter.

impl ToTokens for Lit

impl From<String> for Lit

Performs the conversion.

impl<'a> From<&'a str> for Lit

Performs the conversion.

impl From<Vec<u8>> for Lit

Performs the conversion.

impl<'a> From<&'a [u8]> for Lit

Performs the conversion.

impl From<char> for Lit

Performs the conversion.

impl From<bool> for Lit

Performs the conversion.

impl From<isize> for Lit

Performs the conversion.

impl From<i8> for Lit

Performs the conversion.

impl From<i16> for Lit

Performs the conversion.

impl From<i32> for Lit

Performs the conversion.

impl From<i64> for Lit

Performs the conversion.

impl From<usize> for Lit

Performs the conversion.

impl From<u8> for Lit

Performs the conversion.

impl From<u16> for Lit

Performs the conversion.

impl From<u32> for Lit

Performs the conversion.

impl From<u64> for Lit

Performs the conversion.

impl From<f32> for Lit

Performs the conversion.

impl From<f64> for Lit

Performs the conversion.

impl PartialEq<Lit> for Lit

This method tests for self and other values to be equal, and is used by ==. Read more

This method tests for !=.

impl Clone for Lit

Returns a copy of the value. Read more

Performs copy-assignment from source. Read more

impl Eq for Lit