Skip to main content

oni_comb_parser/
input.rs

1pub trait Input {
2  type Checkpoint: Copy + Eq + Ord;
3  type Slice<'a>
4  where
5    Self: 'a;
6
7  fn checkpoint(&self) -> Self::Checkpoint;
8  fn reset(&mut self, checkpoint: Self::Checkpoint);
9  fn offset(&self) -> usize;
10  fn remaining(&self) -> Self::Slice<'_>;
11  fn is_eof(&self) -> bool;
12}