Skip to content

Releases: async-rs/async-std

v0.99.8

28 Sep 15:58
155256c
Compare
Choose a tag to compare

This release came slightly ahead of schedule in order to fix compatibility issues with the newly released futures-preview@0.3.0-alpha.19 and Rust 1.39 beta release. Additionally we've introduced documentation for futures concurrency, and several new io::Read methods!

Added

  • Added README to examples directory.
  • Added concurrency documentation to the futures submodule.
  • Added io::Read::take method.
  • Added io::Read::by_ref method.
  • Added io::Read::chain method.

Changed

  • Pin futures-preview to 0.3.0-alpha.18, to avoid rustc upgrade problems.
  • Simplified extension traits using a macro.
  • Use the broadcast module with std::sync::Mutex, reducing dependencies.

v0.99.7

26 Sep 16:41
cc76722
Compare
Choose a tag to compare

This release includes 16 new APIs, including new streams combinators, Futures concurrency macros, and extensions to the sync and io submodules.

example using future::join

use async_std::future;

let a = future::ready(1);
let b = future::ready(2);
let c = future::ready(3);

let f = future::join!(a, b, c);
assert_eq!(f.await, (1, 2, 3));

Added

  • Added future::join macro as "unstable"
  • Added future::select macro as "unstable"
  • Added future::try_join macro as "unstable"
  • Added future::try_select macro as "unstable"
  • Added io::BufWriter struct
  • Added stream::Extend trait
  • Added stream::Stream::chain method
  • Added stream::Stream::filter method
  • Added stream::Stream::inspect method
  • Added stream::Stream::skip_while method
  • Added stream::Stream::skip method
  • Added stream::Stream::step_by method
  • Added sync::Arc struct from stdlib
  • Added sync::Barrier struct as "unstable"
  • Added sync::Weak struct from stdlib
  • Added task::ready macro as "unstable"

Changed

  • Correctly marked the pin submodule as "unstable" in the docs
  • Updated tutorial to have certain functions suffixed with _loop
  • io traits are now re-exports of futures-rs types, allowing them to be
    implemented
  • stream traits are now re-exports of futures-rs types, allowing them to be
    implemented
  • prelude::* now needs to be in scope for functions io and stream traits
    to work

v0.99.6

19 Sep 13:45
4719435
Compare
Choose a tag to compare

This release adds several new combinators, a work-stealing executor, and the ability to collect streams using IntoStream and FromStream.

Additionally async-attributes 1.0 has been released which adds support for async fn main, #[test] async fn, and #[bench] async fn.

Example

let a = stream::once(1u8);
let b = stream::once(2u8);
let c = stream::once(3u8);

let s = stream::join!(a, b, c);

assert_eq!(s.collect().await, vec![1u8, 2u8, 3u8]));

Added

  • Added stream::Stream::collect as "unstable"
  • Added stream::Stream::enumerate
  • Added stream::Stream::fuse
  • Added stream::Stream::fold
  • Added stream::Stream::scan
  • Added stream::Stream::zip
  • Added stream::join macro as "unstable"
  • Added stream::DoubleEndedStream as "unstable"
  • Added stream::FromStream trait as "unstable"
  • Added stream::IntoStream trait as "unstable"
  • Added io::Cursor as "unstable"
  • Added io::BufRead::consume method
  • Added io::repeat
  • Added io::Slice and io::SliceMut
  • Added documentation for feature flags
  • Added pin submodule as "unstable"
  • Added the ability to collect a stream of Result<T, E>s into a
    Result<impl FromStream<T>, E>

Changed

  • Refactored the scheduling algorithm of our executor to use work stealing
  • Refactored the network driver, removing 400 lines of code
  • Removed the Send bound from task::block_on
  • Removed Unpin bound from impl<T: futures::stream::Stream> Stream for T

v0.99.5

12 Sep 12:39
9d71584
Compare
Choose a tag to compare

Added

  • Added tests for io::timeout
  • Added io::BufRead::fill_buf, an async fn counterpart to poll_fill_buf
  • Added fs::create_dir_all
  • Added future::timeout, a free function to time out futures after a threshold
  • Added io::prelude
  • Added net::ToSocketAddrs, a non-blocking version of std's ToSocketAddrs
  • Added stream::Stream::all
  • Added stream::Stream::filter_map
  • Added stream::Stream::find_map
  • Added stream::Stream::find
  • Added stream::Stream::min_by
  • Added stream::Stream::nth

Changed

  • Polished the text and examples of the tutorial
  • cargo fmt on all examples
  • Simplified internals of TcpStream::connect_to
  • Modularized our CI setup, enabled a rustfmt fallback, and improved caching
  • Reduced our dependency on the futures-rs crate, improving compilation times
  • Split io::Read, io::Write, io::BufRead, and stream::Stream into
    multiple files
  • fs::File now flushes more often to prevent flushes during seek
  • Updated all dependencies
  • Fixed a bug in the conversion of File into raw handle
  • Fixed compilation errors on the latest nightly