Enum proc_macro::Delimiter 1.29.0[−][src]
pub enum Delimiter {
Parenthesis,
Brace,
Bracket,
None,
}Describes how a sequence of token trees is delimited.
Variants
Parenthesis( ... )
Brace{ ... }
Bracket[ ... ]
NoneØ ... Ø
An implicit delimiter, that may, for example, appear around tokens coming from a
"macro variable" $var. It is important to preserve operator priorities in cases like
$var * 3 where $var is 1 + 2.
Implicit delimiters may not survive roundtrip of a token stream through a string.
Trait Implementations
impl Copy for Delimiter[src]
impl Copy for Delimiterimpl Clone for Delimiter[src]
impl Clone for Delimiterfn clone(&self) -> Delimiter[src]
fn clone(&self) -> DelimiterReturns a copy of the value. Read more
fn clone_from(&mut self, source: &Self)1.0.0[src]
fn clone_from(&mut self, source: &Self)1.0.0
[src]Performs copy-assignment from source. Read more
impl Debug for Delimiter[src]
impl Debug for Delimiterfn fmt(&self, f: &mut Formatter) -> Result[src]
fn fmt(&self, f: &mut Formatter) -> ResultFormats the value using the given formatter. Read more
impl PartialEq for Delimiter[src]
impl PartialEq for Delimiterfn eq(&self, other: &Delimiter) -> bool[src]
fn eq(&self, other: &Delimiter) -> boolThis method tests for self and other values to be equal, and is used by ==. Read more
#[must_use]
fn ne(&self, other: &Rhs) -> bool1.0.0[src]
#[must_use]
fn ne(&self, other: &Rhs) -> bool1.0.0
[src]This method tests for !=.
impl Eq for Delimiter[src]
impl Eq for Delimiter