Struct pomsky_syntax::exprs::Alternation
source · Expand description
An alternation.
This is a list of alternatives. Each alternative is a Rule.
If an alternative consists of multiple expressions (e.g. 'a' | 'b' 'c'),
that alternative is a Rule::Group. Note that a group’s parentheses are
removed when compiling to a regex if they aren’t required. In other words,
'a' | ('b' 'c') compiles to a|bc.
Fields§
§rules: Vec<Rule<'i>>Trait Implementations§
source§impl<'i> Clone for Alternation<'i>
impl<'i> Clone for Alternation<'i>
source§fn clone(&self) -> Alternation<'i>
fn clone(&self) -> Alternation<'i>
Returns a copy of the value. Read more
1.0.0 · source§fn clone_from(&mut self, source: &Self)
fn clone_from(&mut self, source: &Self)
Performs copy-assignment from
source. Read more