MCPcopy Create free account
hub / github.com/MaterializeInc/materialize / peek

Method peek

src/testdrive/src/parser.rs:586–591  ·  view source on GitHub ↗
(&mut self)

Source from the content-addressed store, hash-verified

584 }
585
586 fn peek(&mut self) -> Option<&(usize, String)> {
587 if self.next.is_none() {
588 self.next = Some(self.read_one())
589 }
590 self.next.as_ref().unwrap().as_ref()
591 }
592
593 pub fn line_col(&self, pos: usize) -> (usize, usize) {
594 let (base_pos, (line, col)) = self.pos_map.range(..=pos).next_back().unwrap();

Callers 8

push_intoMethod · 0.45
merge_withMethod · 0.45
parseFunction · 0.45
parse_fail_sqlFunction · 0.45
slurp_oneFunction · 0.45
read_oneMethod · 0.45
nextMethod · 0.45
columns_prettyFunction · 0.45

Calls 4

is_noneMethod · 0.80
read_oneMethod · 0.80
unwrapMethod · 0.80
as_refMethod · 0.45

Tested by

no test coverage detected