pub struct IncrementalParser { /* private fields */ }Expand description
The incremental parser state — tracks source + cache
Implementations§
Source§impl IncrementalParser
impl IncrementalParser
pub fn new(source: impl Into<String>) -> Self
pub fn apply_change(&mut self, change: TextChange)
pub fn apply_changes(&mut self, changes: Vec<TextChange>)
pub fn source(&self) -> &str
pub fn version(&self) -> u32
pub fn split_declarations(source: &str) -> Vec<(usize, &str)>
pub fn reparse_dirty(&mut self)
pub fn declarations(&self) -> Vec<&ParsedDecl>
pub fn decl_at(&self, offset: usize) -> Option<&ParsedDecl>
pub fn cache_size(&self) -> usize
pub fn dirty_count(&self) -> usize
pub fn invalid_declarations(&self) -> Vec<&ParsedDecl>
pub fn invalidate_by_name(&mut self, name: &str)
Auto Trait Implementations§
impl Freeze for IncrementalParser
impl RefUnwindSafe for IncrementalParser
impl Send for IncrementalParser
impl Sync for IncrementalParser
impl Unpin for IncrementalParser
impl UnsafeUnpin for IncrementalParser
impl UnwindSafe for IncrementalParser
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