Struct syntax::tokenstream::Delimited
[−]
[src]
pub struct Delimited { pub delim: DelimToken, pub tts: ThinTokenStream, }
A delimited sequence of token trees
Fields
delim: DelimToken
The type of delimiter
tts: ThinTokenStream
The delimited sequence of token trees
Methods
impl Delimited
[src]
pub fn open_token(&self) -> Token
[src]
Returns the opening delimiter as a token.
pub fn close_token(&self) -> Token
[src]
Returns the closing delimiter as a token.
pub fn open_tt(&self, span: Span) -> TokenTree
[src]
Returns the opening delimiter as a token tree.
pub fn close_tt(&self, span: Span) -> TokenTree
[src]
Returns the closing delimiter as a token tree.
pub fn stream(&self) -> TokenStream
[src]
Returns the token trees inside the delimiters.
Trait Implementations
impl Clone for Delimited
[src]
fn clone(&self) -> Delimited
[src]
Returns a copy of the value. Read more
fn clone_from(&mut self, source: &Self)
1.0.0[src]
Performs copy-assignment from source
. Read more
impl PartialEq for Delimited
[src]
fn eq(&self, __arg_0: &Delimited) -> bool
[src]
This method tests for self
and other
values to be equal, and is used by ==
. Read more
fn ne(&self, __arg_0: &Delimited) -> bool
[src]
This method tests for !=
.
impl Eq for Delimited
[src]
impl Encodable for Delimited
[src]
impl Decodable for Delimited
[src]
impl Hash for Delimited
[src]
fn hash<__H: Hasher>(&self, __arg_0: &mut __H)
[src]
Feeds this value into the given [Hasher
]. Read more
fn hash_slice<H>(data: &[Self], state: &mut H) where
H: Hasher,
1.3.0[src]
H: Hasher,
Feeds a slice of this type into the given [Hasher
]. Read more