#[repr(u8)]pub enum Assoc {
None = 0,
Left = 1,
Right = 2,
}Expand description
Operator associativity classification.
Assoc determines how operators of the same precedence are grouped during parsing.
It supports left-, right-, and non-associative operators.
| Variant | Description |
|---|---|
Assoc::None | Non-associative — cannot chain with itself. |
Assoc::Left | Left-associative — groups from left to right. |
Assoc::Right | Right-associative — groups from right to left. |
Variants§
None = 0
Non-associative operator.
Left = 1
Left-associative operator.
Right = 2
Right-associative operator.
Implementations§
Trait Implementations§
Source§impl TryFrom<SmartString<LazyCompact>> for Assoc
impl TryFrom<SmartString<LazyCompact>> for Assoc
impl Copy for Assoc
impl Eq for Assoc
impl StructuralPartialEq for Assoc
Auto Trait Implementations§
impl Freeze for Assoc
impl RefUnwindSafe for Assoc
impl Send for Assoc
impl Sync for Assoc
impl Unpin for Assoc
impl UnwindSafe for Assoc
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
Source§impl<T> CloneToUninit for Twhere
T: Clone,
impl<T> CloneToUninit for Twhere
T: Clone,
Source§impl<Q, K> Equivalent<K> for Q
impl<Q, K> Equivalent<K> for Q
Source§impl<Q, K> Equivalent<K> for Q
impl<Q, K> Equivalent<K> for Q
Source§fn equivalent(&self, key: &K) -> bool
fn equivalent(&self, key: &K) -> bool
Compare self to
key and return true if they are equal.