Enum rustc_parse::parser::FlatToken [−][src]
pub enum FlatToken {
Token(Token),
AttrTarget(AttributesData),
Empty,
}A helper struct used when building a AttrAnnotatedTokenStream from
a LazyTokenStream. Both delimiter and non-delimited tokens
are stored as FlatToken::Token. A vector of FlatTokens
is then ‘parsed’ to build up a AttrAnnotatedTokenStream with nested
AttrAnnotatedTokenTree::Delimited tokens
Variants
Token(Token)A token - this holds both delimiter (e.g. ‘{’ and ‘}’) and non-delimiter tokens
AttrTarget(AttributesData)Holds the AttributesData for an AST node. The
AttributesData is inserted directly into the
constructed AttrAnnotatedTokenStream as
a AttrAnnotatedTokenTree::Attributes
A special ‘empty’ token that is ignored during the conversion
to a AttrAnnotatedTokenStream. This is used to simplify the
handling of replace ranges.
Trait Implementations
Auto Trait Implementations
impl !RefUnwindSafe for FlatToken
impl !Send for FlatToken
impl !Sync for FlatToken
impl Unpin for FlatToken
impl !UnwindSafe for FlatToken
Blanket Implementations
impl<T> Any for T where
T: 'static + ?Sized, [src]
T: 'static + ?Sized,
impl<T> Borrow<T> for T where
T: ?Sized, [src]
T: ?Sized,
impl<T> BorrowMut<T> for T where
T: ?Sized, [src]
T: ?Sized,
pub fn borrow_mut(&mut self) -> &mut T[src]
impl<T> From<T> for T[src]
impl<T, U> Into<U> for T where
U: From<T>, [src]
U: From<T>,
impl<T> ToOwned for T where
T: Clone, [src]
T: Clone,
type Owned = T
The resulting type after obtaining ownership.
pub fn to_owned(&self) -> T[src]
pub fn clone_into(&self, target: &mut T)[src]
impl<T, U> TryFrom<U> for T where
U: Into<T>, [src]
U: Into<T>,
type Error = Infallible
The type returned in the event of a conversion error.
pub fn try_from(value: U) -> Result<T, <T as TryFrom<U>>::Error>[src]
impl<T, U> TryInto<U> for T where
U: TryFrom<T>, [src]
U: TryFrom<T>,