lexer: fix ReadRune() to actually move the cursor

Signed-off-by: Alejandro Mery <amery@jpi.io>
This commit is contained in:
2023-08-29 00:45:52 +00:00
parent 7230a74f49
commit edcba80baa
+3
View File
@@ -153,6 +153,9 @@ func (b *Reader) ReadRune() (rune, int, error) {
// decode rune
r, l := utf8.DecodeRune(b.buf[b.cursor:])
// step over
b.cursor += l
return r, l, nil
}