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

Method expect

perro_source/runtime_project/perro_scene/src/parser.rs:45–51  ·  view source on GitHub ↗
(&mut self, t: Token<'a>)

Source from the content-addressed store, hash-verified

43 fn advance(&mut self) {
44 self.current = self.lexer.next_token();
45 }
46
47 fn expect(&mut self, t: Token<'a>) -> ParseResult<()> {
48 if self.current != t {
49 return Err(format!("Expected {:?}, got {:?}", t, self.current));
50 }
51 self.advance();
52 Ok(())
53 }
54

Callers 15

create_textureFunction · 0.45
bench_upsert_framesFunction · 0.45
bench_retained_framesFunction · 0.45
bench_multimesh_framesFunction · 0.45
bench_postprocess_framesFunction · 0.45
bench_light_framesFunction · 0.45
bench_sky_framesFunction · 0.45
parse_and_validateFunction · 0.45
post_prelude_literalFunction · 0.45
resumedMethod · 0.45
mainFunction · 0.45
create_textureFunction · 0.45

Calls 1

advanceMethod · 0.45