Struct mun_syntax::Parse
source · pub struct Parse<T> { /* private fields */ }
Expand description
Parse
is the result of the parsing: a syntax tree and a collection of errors.
Note that we always produce a syntax tree, event for completely invalid files.
Implementations§
source§impl<T> Parse<T>
impl<T> Parse<T>
pub fn syntax_node(&self) -> SyntaxNode
source§impl<T: AstNode> Parse<T>
impl<T: AstNode> Parse<T>
pub fn into_syntax(self) -> Parse<SyntaxNode>
pub fn tree(&self) -> T
pub fn errors(&self) -> &[SyntaxError]
pub fn ok(self) -> Result<T, Arc<[SyntaxError]>>
source§impl Parse<SourceFile>
impl Parse<SourceFile>
pub fn debug_dump(&self) -> String
sourcepub fn reparse(&self, indel: &Indel) -> Parse<SourceFile>
pub fn reparse(&self, indel: &Indel) -> Parse<SourceFile>
Parses the SourceFile
again but with the given modification applied.