mirror of
https://github.com/tokio-rs/bytes.git
synced 2026-08-13 00:00:32 +02:00
8c11456185c1d20cac3ea4c741e5e0c50305cfb3
reserve and try_reclaim
Instead of providing a separate `try_reclaim` function, `reserve` will attempt to reclaim the existing buffer before allocating.
Bytes
A utility library for working with bytes.
Usage
To use bytes, first add this to your Cargo.toml:
[dependencies]
bytes = "0.4"
Next, add this to your crate:
extern crate bytes;
use bytes::{Bytes, BytesMut, Buf, BufMut};
License
bytes is primarily distributed under the terms of both the MIT license and the
Apache License (Version 2.0), with portions covered by various BSD-like
licenses.
See LICENSE-APACHE, and LICENSE-MIT for details.
Languages
Rust
99.6%
Shell
0.4%