(self, count: int)
| 88 | return self.string[self.position.chars : self.position.chars + count] |
| 89 | |
| 90 | def read(self, count: int) -> str: |
| 91 | result = self.string[self.position.chars : self.position.chars + count] |
| 92 | if len(result) < count: |
| 93 | raise Error("read: End of string") |
| 94 | self.position.advance(result) |
| 95 | return result |
| 96 | |
| 97 | def read_regex(self, regex: Pattern[str]) -> Sequence[str]: |
| 98 | match = regex.match(self.string, self.position.chars) |