MCPcopy Create free account
hub / github.com/LaBatata101/sith-language-server / parse

Method parse

crates/sith_python_parser/src/parser/mod.rs:75–82  ·  view source on GitHub ↗

Consumes the [`Parser`] and returns the parsed [`Parsed`].

(mut self)

Source from the content-addressed store, hash-verified

73
74 /// Consumes the [`Parser`] and returns the parsed [`Parsed`].
75 pub(crate) fn parse(mut self) -> Parsed<Mod> {
76 let syntax = match self.mode {
77 Mode::Expression => Mod::Expression(self.parse_single_expression()),
78 Mode::Module | Mode::Ipython => Mod::Module(self.parse_module()),
79 };
80
81 self.finish(syntax)
82 }
83
84 /// Parses a single expression.
85 ///

Callers 5

parse_moduleFunction · 0.45
parse_expressionFunction · 0.45
parse_expression_rangeFunction · 0.45
parse_uncheckedFunction · 0.45
parse_unchecked_sourceFunction · 0.45

Calls 3

parse_moduleMethod · 0.80
finishMethod · 0.45

Tested by

no test coverage detected