pub struct SavePoint { /* private fields */ }Expand description
Store state of the lexer and allow rescanning from that point. Port of the
C++ JSLexer::SavePoint (JSLexer.h:751-821).
DEVIATION: the C++ SavePoint holds a JSLexer * and exposes restore().
In Rust a save point cannot hold a &mut JSLexer across an intervening
advance (which also borrows the lexer mutably), so it is a plain value
snapshot and restore takes &mut JSLexer.
Implementations§
Auto Trait Implementations§
impl Freeze for SavePoint
impl RefUnwindSafe for SavePoint
impl Send for SavePoint
impl Sync for SavePoint
impl Unpin for SavePoint
impl UnsafeUnpin for SavePoint
impl UnwindSafe for SavePoint
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