From 68d2db509157d9bee27effb5ac5b047493b4d584 Mon Sep 17 00:00:00 2001 From: Stjepan Glavina Date: Sun, 20 Sep 2020 18:29:46 +0200 Subject: [PATCH] Update async-executor --- Cargo.toml | 4 ++-- README.md | 2 +- src/lib.rs | 4 ++-- 3 files changed, 5 insertions(+), 5 deletions(-) diff --git a/Cargo.toml b/Cargo.toml index 65b6ef0..9daad19 100644 --- a/Cargo.toml +++ b/Cargo.toml @@ -14,11 +14,11 @@ readme = "README.md" [dependencies] async-channel = "1.4.2" -async-executor = "1.1.1" +async-executor = "1.3.0" async-fs = "1.3.0" async-io = "1.1.0" async-lock = "2.1.2" -async-net = "1.3.0" +async-net = "1.4.1" async-process = "1.0.0" blocking = "1.0.0" futures-lite = "1.4.0" diff --git a/README.md b/README.md index f3a2998..62ae1a5 100644 --- a/README.md +++ b/README.md @@ -32,7 +32,7 @@ fn main() -> io::Result<()> { stream.write_all(req).await?; let mut stdout = Unblock::new(std::io::stdout()); - io::copy(&stream, &mut stdout).await?; + io::copy(stream, &mut stdout).await?; Ok(()) }) } diff --git a/src/lib.rs b/src/lib.rs index 1e2fa43..e42a450 100644 --- a/src/lib.rs +++ b/src/lib.rs @@ -19,7 +19,7 @@ //! stream.write_all(req).await?; //! //! let mut stdout = Unblock::new(std::io::stdout()); -//! io::copy(&stream, &mut stdout).await?; +//! io::copy(stream, &mut stdout).await?; //! Ok(()) //! }) //! } @@ -100,7 +100,7 @@ pub mod prelude { /// }); /// ``` pub fn spawn(future: impl Future + Send + 'static) -> Task { - static GLOBAL: Lazy = Lazy::new(|| { + static GLOBAL: Lazy> = Lazy::new(|| { let num_threads = { // Parse SMOL_THREADS or default to 1. std::env::var("SMOL_THREADS")