bitsandbytes 0.3.2

An owned, bit-aware binary codec: fast bit/byte field types and the unified #[bin] macro.
Documentation
1
2
3
4
5
6
7
8
//! `codec` (a fn pair owns the wire form) and struct-level wire mapping (a wire *type*
//! owns it) are two answers to the same question — combining them is contradictory.
use bnb::bin;

#[bin(codec = bnb::codecs::leb128, wire = u64)]
struct Varint(u64);

fn main() {}