MCPcopy Create free account
hub / github.com/dylan-sutton-chavez/edge-python / skip_annotation

Method skip_annotation

compiler/src/modules/parser/stmt.rs:337–345  ·  view source on GitHub ↗

Annotation: discard tokens up to `=`; Edge Python is dynamically typed. Returns true when an assignment follows. */

(&mut self)

Source from the content-addressed store, hash-verified

335
336 /* Annotation: discard tokens up to `=`; Edge Python is dynamically typed. Returns true when an assignment follows. */
337 fn skip_annotation(&mut self) -> bool {
338 while !matches!(
339 self.peek(),
340 Some(TokenType::Equal | TokenType::Dedent | TokenType::Endmarker) | None
341 ) {
342 self.advance();
343 }
344 matches!(self.peek(), Some(TokenType::Equal))
345 }
346
347 /* Decodes a just-emitted `[a, b, ...]` display into bare target names; None unless every element is a plain name load. */
348 fn list_display_targets(&self, start: usize) -> Option<Vec<String>> {

Callers 1

name_stmtMethod · 0.80

Calls 1

advanceMethod · 0.80

Tested by

no test coverage detected