MCPcopy Create free account
hub / github.com/astral-sh/ruff / parse_call_expression

Method parse_call_expression

crates/ruff_python_parser/src/parser/expression.rs:789–798  ·  view source on GitHub ↗

Parse a call expression. The function name is parsed by the caller and passed as `func` along with the `start` position of the call expression. # Panics If the parser isn't position at a `(` token. See:

(&mut self, func: Expr, start: TextSize)

Source from the content-addressed store, hash-verified

787 ///
788 /// See: <https://docs.python.org/3/reference/expressions.html#calls>
789 pub(super) fn parse_call_expression(&mut self, func: Expr, start: TextSize) -> ast::ExprCall {
790 let arguments = self.parse_arguments(ArgumentsContext::Call);
791
792 ast::ExprCall {
793 func: Box::new(func),
794 arguments,
795 range: self.node_range(start),
796 node_index: AtomicNodeIndex::NONE,
797 }
798 }
799
800 /// Parses an argument list.
801 ///

Callers 1

Calls 2

parse_argumentsMethod · 0.80
node_rangeMethod · 0.80

Tested by

no test coverage detected