Skip to content

Releases: sunshowers-code/buf-list

buf-list 1.1.2

02 Oct 20:43

Choose a tag to compare

Simplify Buf::chunks_vectored implementations for BufList and Cursor<T>.

buf-list 1.1.1

02 Oct 02:31

Choose a tag to compare

Added

bytes::Buf implementations for Cursor<BufList> and Cursor<&BufList>, to go with the existing bytes::Buf implementation for BufList itself. This way, the same BufList can have multiple cursors over it that all use the bytes::Buf implementation.

buf-list 1.1.0

29 Sep 20:52

Choose a tag to compare

Changed

  • With Cursor::read_exact, if there aren't enough bytes remaining, the position will be set to the end of the buffer. This mirrors the same behavior change in std::io::Cursor introduced in Rust 1.80 (see rust-lang/rust#125404).
  • MSRV updated to Rust 1.70.
  • Internal improvement: computed start positions for chunks are now stored in a OnceLock on the BufList rather than being recomputed each time a Cursor is constructed. In the case where there might be many Cursor instances on the same &BufList, this allows for start positions to be shared. Thanks to inanna-malick for your first cntribution!

Fixed

  • Replaced obsolete doc_auto_cfg with doc_cfg, to fix Rust nightly builds with the doc_cfg flag enabled.

buf-list 1.0.3

09 Apr 20:17

Choose a tag to compare

  • Documentation improvements.

buf-list 1.0.2

09 Apr 20:03

Choose a tag to compare

Added

  • A new type Cursor which wraps a BufList or &BufList, and implements Seek, Read and BufRead.
  • BufList implements From<T> for any T that can be converted to Bytes. This creates a
    BufList with a single chunk.
  • BufList::get_chunk returns the chunk at the provided index.
  • New optional features:
    • tokio1: makes Cursor implement tokio's AsyncSeek, AsyncRead and AsyncBufRead
    • futures03: makes Cursor implement futures's AsyncSeek, AsyncRead and AsyncBufRead.

buf-list 1.0.1

17 Feb 00:42

Choose a tag to compare

Added

  • Add recipes for converting a BufList into a Stream or a TryStream.

buf-list 1.0.0

06 Jan 19:45

Choose a tag to compare

Added

  • BufList now implements Extend<B: Buf>. This means you can now collect a stream of Bytes, or other Buf chunks, directly into a BufList via StreamExt::collect.

Changed

  • push_chunk now has a type parameter B: Buf rather than impl Buf.

buf-list 0.1.3

11 Dec 18:09

Choose a tag to compare

  • Fix license indication in README: this crate is Apache-2.0 only, not MIT OR Apache-2.0.

buf-list 0.1.2

11 Dec 07:08

Choose a tag to compare

  • Fix intradoc links.

buf-list 0.1.1

11 Dec 07:00

Choose a tag to compare

  • Fixes to README.
  • Add MSRV policy.