Closed Veritius closed 5 months ago
Thank you for your suggestion and looking into naia
!
write_bits
is actually only used for the BitCounter, I've renamed it for the next release to make that clearer.
read_bit
and read_byte
can be accessed from other crates by just calling:
let bit = bool::de(&mut bit_reader);
and let byte = u8::de(&mut bit_reader);
respectively.
The functions
read_bit
andread_byte
inBitReader
's implementation arepub(crate)
preventing outside access. TheSerde
crate cannot be implemented outside naia due to this.Additionally, the
BitWrite
trait has thewrite_bits
function, taking au32
, butBitReader
has no such parallel.