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

Method parse_pass_statement

crates/ruff_python_parser/src/parser/statement.rs:864–871  ·  view source on GitHub ↗

Parses a `pass` statement. # Panics If the parser isn't positioned at a `pass` token. See:

(&mut self)

Source from the content-addressed store, hash-verified

862 ///
863 /// See: <https://docs.python.org/3/reference/simple_stmts.html#grammar-token-python-grammar-pass_stmt>
864 fn parse_pass_statement(&mut self) -> ast::StmtPass {
865 let start = self.node_start();
866 self.bump(TokenKind::Pass);
867 ast::StmtPass {
868 range: self.node_range(start),
869 node_index: AtomicNodeIndex::NONE,
870 }
871 }
872
873 /// Parses a `continue` statement.
874 ///

Callers 1

Calls 3

node_startMethod · 0.80
node_rangeMethod · 0.80
bumpMethod · 0.45

Tested by

no test coverage detected