pub fn lastN(self: AccumBuffer, dist: usize) !u8 self: AccumBufferdist: usize47
48
49
50
51
52
53
54 pub fn lastN(self: AccumBuffer, dist: usize) !u8 {
const buf_len = self.buf.items.len;
if (dist > buf_len) {
return error.CorruptInput;
}
return self.buf.items[buf_len - dist];
}
Retrieve the n-th last byte