MCPcopy Create free account
hub / github.com/PerroEngine/Perro / expect_ident

Method expect_ident

perro_source/core/perro_animation/src/anim_tree.rs:487–495  ·  view source on GitHub ↗
(&mut self)

Source from the content-addressed store, hash-verified

485 }
486
487 fn expect_ident(&mut self) -> Result<String, String> {
488 match std::mem::replace(&mut self.current, Token::Eof) {
489 Token::Ident(v) => {
490 self.advance();
491 Ok(v.to_string())
492 }
493 other => Err(format!("expected identifier, got {other:?}")),
494 }
495 }
496
497 fn advance(&mut self) {
498 self.current = self.lexer.next_token();

Callers 10

parseMethod · 0.45
parse_header_blockMethod · 0.45
parse_output_blockMethod · 0.45
parse_blend_kindMethod · 0.45
parse_add_kindMethod · 0.45
parse_invert_kindMethod · 0.45
parse_maskMethod · 0.45
expect_refMethod · 0.45
consume_closeMethod · 0.45

Calls 1

advanceMethod · 0.45

Tested by

no test coverage detected