pub struct PrattContext {
pub min_prec: u8,
pub depth: usize,
pub max_depth: usize,
}Expand description
A context for operator-precedence parsing (Pratt parsing).
Fields§
§min_prec: u8§depth: usize§max_depth: usizeImplementations§
Source§impl PrattContext
impl PrattContext
pub fn new(min_prec: u8) -> Self
pub fn with_min_prec(&self, p: u8) -> Self
pub fn is_too_deep(&self) -> bool
Auto Trait Implementations§
impl Freeze for PrattContext
impl RefUnwindSafe for PrattContext
impl Send for PrattContext
impl Sync for PrattContext
impl Unpin for PrattContext
impl UnsafeUnpin for PrattContext
impl UnwindSafe for PrattContext
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