Revert "remove dead code"

This reverts commit bc65fc56ed.
This commit is contained in:
Sascha L. Teichmann 2024-01-08 01:34:19 +01:00
parent bc65fc56ed
commit 069f4728c5
1 changed files with 9 additions and 0 deletions

View File

@ -385,3 +385,12 @@ func (pb *posBuf) Read(p []byte) (int, error) {
pb.Pos += pl
return pl, nil
}
func (pb *posBuf) ReadByte() (byte, error) {
if pb.Pos >= len(pb.Data) {
return 0, io.EOF
}
c := pb.Data[pb.Pos]
pb.Pos++
return c, nil
}