pub struct PrattOperator {
pub symbol: Symbol,
pub fixity: Fixity,
pub left_bp: u16,
pub right_bp: u16,
pub result: PrattResult,
}Expand description
A single operator entry in a PrattTable: its symbol, fixity, binding
powers, and the expression form it produces.
Fields§
§symbol: SymbolSymbol that triggers this operator during parsing.
fixity: FixityHow the operator binds relative to its operands.
left_bp: u16Left binding power, governing how tightly the operator binds to its left.
right_bp: u16Right binding power, governing how tightly the operator binds to its right.
result: PrattResultExpression form produced when this operator matches.
Trait Implementations§
Source§impl Clone for PrattOperator
impl Clone for PrattOperator
Source§fn clone(&self) -> PrattOperator
fn clone(&self) -> PrattOperator
Returns a duplicate of the value. Read more
1.0.0 (const: unstable) · Source§fn clone_from(&mut self, source: &Self)
fn clone_from(&mut self, source: &Self)
Performs copy-assignment from
source. Read moreSource§impl Debug for PrattOperator
impl Debug for PrattOperator
impl Eq for PrattOperator
Source§impl PartialEq for PrattOperator
impl PartialEq for PrattOperator
Source§fn eq(&self, other: &PrattOperator) -> bool
fn eq(&self, other: &PrattOperator) -> bool
Tests for
self and other values to be equal, and is used by ==.impl StructuralPartialEq for PrattOperator
Auto Trait Implementations§
impl Freeze for PrattOperator
impl RefUnwindSafe for PrattOperator
impl Send for PrattOperator
impl Sync for PrattOperator
impl Unpin for PrattOperator
impl UnsafeUnpin for PrattOperator
impl UnwindSafe for PrattOperator
Blanket Implementations§
Source§impl<T> BorrowMut<T> for Twhere
T: ?Sized,
impl<T> BorrowMut<T> for Twhere
T: ?Sized,
Source§fn borrow_mut(&mut self) -> &mut T
fn borrow_mut(&mut self) -> &mut T
Mutably borrows from an owned value. Read more