struct State<'a> {
err: Vec<ErrorInfo>,
cursor: TreeCursor<'a>,
source: &'a Rope,
owner: FileID,
}
Fields§
§err: Vec<ErrorInfo>
§cursor: TreeCursor<'a>
§source: &'a Rope
§owner: FileID
Trait Implementations§
source§impl<'a> Visitor<'a> for State<'a>
impl<'a> Visitor<'a> for State<'a>
fn cursor(&self) -> &TreeCursor<'a>
fn cursor_mut(&mut self) -> &mut TreeCursor<'a>
fn source(&self) -> &Rope
fn push_err_raw(&mut self, err: ErrorInfo)
fn skip_extra(&mut self) -> bool
source§fn goto_first_child(&mut self) -> bool
fn goto_first_child(&mut self) -> bool
try to go down
source§fn goto_named(&mut self) -> bool
fn goto_named(&mut self) -> bool
try to goto a named node on the current layer
fn goto_next_sibling(&mut self) -> bool
fn goto_parent(&mut self)
fn kind(&self) -> &str
fn node(&self) -> Node<'a>
fn child_by_name(&self, name: &str) -> Option<Node<'a>>
source§fn goto_next_kind(&mut self, kind: &str) -> bool
fn goto_next_kind(&mut self, kind: &str) -> bool
try to go forward at least once until we find a node of kind
source§fn goto_field(&mut self, name: &str) -> bool
fn goto_field(&mut self, name: &str) -> bool
try to go forward until we find a node as a field name
source§fn goto_kind(&mut self, name: &str) -> bool
fn goto_kind(&mut self, name: &str) -> bool
try to go forward until we find a node of kind name
fn push_error<T: Into<String>>(&mut self, w: u32, error: T)
fn push_error_with_type<T: Into<String>>( &mut self, w: u32, error: T, error_type: ErrorType, )
fn push_error_node<T: Into<String>>(&mut self, node: Node<'_>, w: u32, error: T)
Auto Trait Implementations§
impl<'a> Freeze for State<'a>
impl<'a> RefUnwindSafe for State<'a>
impl<'a> !Send for State<'a>
impl<'a> !Sync for State<'a>
impl<'a> Unpin for State<'a>
impl<'a> UnwindSafe for State<'a>
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
§impl<T> Instrument for T
impl<T> Instrument for T
§fn instrument(self, span: Span) -> Instrumented<Self>
fn instrument(self, span: Span) -> Instrumented<Self>
§fn in_current_span(self) -> Instrumented<Self>
fn in_current_span(self) -> Instrumented<Self>
source§impl<T> IntoEither for T
impl<T> IntoEither for T
source§fn into_either(self, into_left: bool) -> Either<Self, Self>
fn into_either(self, into_left: bool) -> Either<Self, Self>
Converts
self
into a Left
variant of Either<Self, Self>
if into_left
is true
.
Converts self
into a Right
variant of Either<Self, Self>
otherwise. Read moresource§fn into_either_with<F>(self, into_left: F) -> Either<Self, Self>
fn into_either_with<F>(self, into_left: F) -> Either<Self, Self>
Converts
self
into a Left
variant of Either<Self, Self>
if into_left(&self)
returns true
.
Converts self
into a Right
variant of Either<Self, Self>
otherwise. Read more