3 releases (breaking)

0.3.0 Jan 27, 2023
0.2.0 Apr 2, 2020
0.1.0 Mar 13, 2020

#1934 in Rust patterns

Download history 128/week @ 2024-03-13 195/week @ 2024-03-20 273/week @ 2024-03-27 202/week @ 2024-04-03 159/week @ 2024-04-10 135/week @ 2024-04-17 174/week @ 2024-04-24 173/week @ 2024-05-01 145/week @ 2024-05-08 104/week @ 2024-05-15 243/week @ 2024-05-22 137/week @ 2024-05-29 108/week @ 2024-06-05 155/week @ 2024-06-12 182/week @ 2024-06-19 141/week @ 2024-06-26

598 downloads per month
Used in 23 crates (4 directly)

MIT license

21KB
502 lines

minibytes

This create provides the Bytes type. It is similar to &[u8]: cloning or slicing are zero-copy. Unlike &[u8], Bytes does not have lifetime. This is done by maintaining the life cycle of the underlying storage using reference count.

Aside from supporting Vec<u8> as the underlying storage, Bytes also supports memmap::Mmap. Libraries can implement BytesOwner for other types to further extend storage support.

Dependencies

~0.4–1.2MB
~24K SLoC