pub enum Value<'a> {
None,
Integer(i32),
Text(Cow<'a, str>),
Keyword(&'static Keyword),
}Expand description
The value of a token.
Variants§
None
No value, for a character token, an operator token such as ::, or the end.
Integer(i32)
The value of ICONST and PARAM.
Text(Cow<'a, str>)
The text of IDENT, UIDENT, SCONST, USCONST, FCONST, BCONST, XCONST and Op. An identifier is in lower case and not longer than 63 bytes. A bit string starts with b and a hexadecimal string starts with x, as in PostgreSQL.
Keyword(&'static Keyword)
The keyword of a keyword token.
Trait Implementations§
Auto Trait Implementations§
impl<'a> Freeze for Value<'a>
impl<'a> RefUnwindSafe for Value<'a>
impl<'a> Send for Value<'a>
impl<'a> Sync for Value<'a>
impl<'a> Unpin for Value<'a>
impl<'a> UnsafeUnpin for Value<'a>
impl<'a> UnwindSafe for Value<'a>
Blanket Implementations§
Source§impl<T> BorrowMut<T> for Twhere
T: ?Sized,
impl<T> BorrowMut<T> for Twhere
T: ?Sized,
Source§fn borrow_mut(&mut self) -> &mut T
fn borrow_mut(&mut self) -> &mut T
Mutably borrows from an owned value. Read more