-
- Downloads
RingBuf: Fix edge cases with mark/reset.
- This fixes #25 and fixes #26. - Move the mark state into a 'Mark' enum. - Store both 'pos' and 'len' inside the mark because both are needed to distinguish between full/empty states. This fixes 'reset' setting 'len' to zero when the buffer was full when marked. - Clear the mark when the length of the marked input range exceeds the capacity. Fixes bugs with the mark not being cleared correctly on writes. - Add test cases.
Please register or sign in to comment