Enum token_lists::Token [−][src]
Expand description
Represents the token lists.
Variants
Symbol(String)
Expand description
A symbol token represented by its name.
Expand description
A list token containing other tokens.
Implementations
impl Token
[src]
impl Token
[src]pub fn symbol(self) -> Option<String>
[src]
pub fn symbol(self) -> Option<String>
[src]If the token is a Symbol
, returns an Option
, containing the symbol name.
Else returns None
.
pub fn symbol_ref(&self) -> Option<&String>
[src]
pub fn symbol_ref(&self) -> Option<&String>
[src]Same as fn symbol
, but returns a ref.
Trait Implementations
impl StructuralPartialEq for Token
[src]
Auto Trait Implementations
impl RefUnwindSafe for Token
impl Send for Token
impl Sync for Token
impl Unpin for Token
impl UnwindSafe for Token
Blanket Implementations
impl<T> BorrowMut<T> for T where
T: ?Sized,
[src]
impl<T> BorrowMut<T> for T where
T: ?Sized,
[src]pub fn borrow_mut(&mut self) -> &mut T
[src]
pub fn borrow_mut(&mut self) -> &mut T
[src]Mutably borrows from an owned value. Read more
impl<T> ToOwned for T where
T: Clone,
[src]
impl<T> ToOwned for T where
T: Clone,
[src]type Owned = T
type Owned = T
The resulting type after obtaining ownership.
pub fn to_owned(&self) -> T
[src]
pub fn to_owned(&self) -> T
[src]Creates owned data from borrowed data, usually by cloning. Read more
pub fn clone_into(&self, target: &mut T)
[src]
pub fn clone_into(&self, target: &mut T)
[src]🔬 This is a nightly-only experimental API. (toowned_clone_into
)
recently added
Uses borrowed data to replace owned data, usually by cloning. Read more