Hi, I faced with weird behavior if you write negative number Here is a [pool_request](https://github.com/tuffy/bitstream-io/pull/25) with test to reproduce the behavior Long story short, highest bits get overwritten by new bits. I assume it may happens because [in this line](https://github.com/tuffy/bitstream-io/pull/25) `.to_u8()` is called after bit range checks, but I'm not sure. To fix it in our app, we started convert types to unsigned before calling `.write(bit_len, val)` - and then it works properly
Activity