Closed chiefnoah closed 10 months ago
Cast both the offset and the slice.len() to isize so we can safely underflow to a negative number. We lose out on 1-bit of possible offset/slice size, but I'd love to have your computer if you're bumping into that.
isize
Adds a quick test to verify the fix as well.
This fixes #77.
How does that look?
Done.
Cast both the offset and the slice.len() to
isize
so we can safely underflow to a negative number. We lose out on 1-bit of possible offset/slice size, but I'd love to have your computer if you're bumping into that.Adds a quick test to verify the fix as well.
This fixes #77.