pub trait Operator {
fn get_assoc(&self) -> bool;
fn get_precedence(&self) -> u64;
fn get_precedence_and_assoc(&self) -> (u64, bool) { ... }
}
Expand description
Represents an operator
Required Methods
sourcefn get_assoc(&self) -> bool
fn get_assoc(&self) -> bool
Get the associativity as a boolean that is true if it goes rightwards
sourcefn get_precedence(&self) -> u64
fn get_precedence(&self) -> u64
Get the precedence as an unsigned integer, where the lower it is, the more precedence/priority it has
Provided Methods
sourcefn get_precedence_and_assoc(&self) -> (u64, bool)
fn get_precedence_and_assoc(&self) -> (u64, bool)
Get the precedence and associativity of this operator