From bbbfbb7812ede7720183407bbe4cfbd98b5f5c1f Mon Sep 17 00:00:00 2001 From: Taiki Endo Date: Thu, 25 Apr 2019 11:11:47 +0900 Subject: [PATCH] Update to stabilized futures_api --- .travis.yml | 2 +- README.md | 2 +- futures-channel/benches/sync_mpsc.rs | 2 +- futures-channel/src/lib.rs | 2 -- futures-channel/tests/channel.rs | 2 +- futures-channel/tests/mpsc.rs | 2 +- futures-channel/tests/oneshot.rs | 2 -- futures-core/src/lib.rs | 1 - .../src/task/__internal/atomic_waker.rs | 1 - futures-executor/benches/thread_notify.rs | 2 +- futures-executor/src/lib.rs | 2 -- futures-executor/src/local_pool.rs | 3 -- futures-executor/tests/local_pool.rs | 2 -- futures-io/src/lib.rs | 2 -- futures-io/tests/cursor.rs | 2 -- futures-sink/src/lib.rs | 2 -- futures-test/src/assert.rs | 6 ++-- futures-test/src/future/mod.rs | 4 +-- futures-test/src/lib.rs | 6 +--- futures-test/src/task/context.rs | 3 +- futures-test/src/task/noop_spawner.rs | 4 +-- futures-test/src/task/panic_spawner.rs | 4 +-- futures-test/src/task/panic_waker.rs | 3 +- futures-test/src/task/record_spawner.rs | 2 +- futures-test/src/task/wake_counter.rs | 1 - futures-util/benches/futures_unordered.rs | 2 +- futures-util/src/async_await/join.rs | 6 ++-- futures-util/src/async_await/select_mod.rs | 6 ++-- futures-util/src/compat/compat01as03.rs | 10 +++---- futures-util/src/compat/executor.rs | 2 +- futures-util/src/future/empty.rs | 2 +- futures-util/src/future/join.rs | 8 +++--- futures-util/src/future/join_all.rs | 2 +- futures-util/src/future/lazy.rs | 2 +- futures-util/src/future/maybe_done.rs | 2 +- futures-util/src/future/mod.rs | 20 ++++++------- futures-util/src/future/option.rs | 2 +- futures-util/src/future/poll_fn.rs | 2 +- futures-util/src/future/ready.rs | 6 ++-- futures-util/src/future/select.rs | 1 - futures-util/src/io/mod.rs | 16 +++++------ futures-util/src/lib.rs | 1 - futures-util/src/sink/drain.rs | 2 +- futures-util/src/stream/mod.rs | 9 +++--- futures-util/src/stream/poll_fn.rs | 1 - futures-util/src/task/noop_waker.rs | 2 -- futures-util/src/task/spawn.rs | 8 +++--- futures-util/src/try_future/mod.rs | 22 +++++++-------- futures-util/src/try_future/try_join.rs | 10 +++---- futures-util/src/try_future/try_join_all.rs | 2 +- futures-util/src/try_stream/mod.rs | 28 +++++++++---------- futures-util/tests/atomic_waker.rs | 2 -- futures-util/tests/futures_unordered.rs | 2 +- futures-util/tests/mutex.rs | 2 +- futures-util/tests/select_all.rs | 2 +- futures-util/tests/select_next_some.rs | 2 +- futures/src/lib.rs | 2 -- futures/tests/abortable.rs | 2 -- futures/tests/async_await_macros.rs | 2 +- futures/tests/basic_combinators.rs | 2 -- futures/tests/compat.rs | 2 +- futures/tests/eager_drop.rs | 2 -- futures/tests/fuse.rs | 2 -- futures/tests/future_obj.rs | 2 +- futures/tests/futures_ordered.rs | 2 -- futures/tests/futures_unordered.rs | 2 -- futures/tests/inspect.rs | 2 -- futures/tests/io_read_exact.rs | 2 -- futures/tests/join_all.rs | 2 +- futures/tests/oneshot.rs | 2 -- futures/tests/recurse.rs | 2 -- futures/tests/shared.rs | 2 -- futures/tests/split.rs | 2 -- futures/tests/stream.rs | 2 +- futures/tests/try_join_all.rs | 2 +- futures/tests/unfold.rs | 2 -- 76 files changed, 112 insertions(+), 176 deletions(-) diff --git a/.travis.yml b/.travis.yml index 5adf63b606..7a0acacdad 100644 --- a/.travis.yml +++ b/.travis.yml @@ -25,7 +25,7 @@ matrix: # When updating this, the reminder to update the minimum required version in README.md. - name: cargo test (minimum required version) - rust: nightly-2019-04-15 + rust: nightly-2019-04-25 - name: cargo clippy rust: nightly diff --git a/README.md b/README.md index 9752c4c7e8..904e1dff2b 100644 --- a/README.md +++ b/README.md @@ -39,7 +39,7 @@ Now, you can use futures-rs: use futures::future::Future; // Note: It's not `futures_preview` ``` -The current version of futures-rs requires Rust nightly 2019-04-15 or later. +The current version of futures-rs requires Rust nightly 2019-04-25 or later. ### Feature `std` diff --git a/futures-channel/benches/sync_mpsc.rs b/futures-channel/benches/sync_mpsc.rs index aa1b930eda..e077a617fd 100644 --- a/futures-channel/benches/sync_mpsc.rs +++ b/futures-channel/benches/sync_mpsc.rs @@ -1,4 +1,4 @@ -#![feature(test, futures_api)] +#![feature(test)] extern crate test; use crate::test::Bencher; diff --git a/futures-channel/src/lib.rs b/futures-channel/src/lib.rs index 91ddbaa646..f60133bfdd 100644 --- a/futures-channel/src/lib.rs +++ b/futures-channel/src/lib.rs @@ -3,8 +3,6 @@ //! This crate provides channels that can be used to communicate between //! asynchronous tasks. -#![feature(futures_api)] - #![cfg_attr(not(feature = "std"), no_std)] #![warn(missing_docs, missing_debug_implementations, rust_2018_idioms)] diff --git a/futures-channel/tests/channel.rs b/futures-channel/tests/channel.rs index 7866c4d886..2f54f6005e 100644 --- a/futures-channel/tests/channel.rs +++ b/futures-channel/tests/channel.rs @@ -1,4 +1,4 @@ -#![feature(async_await, await_macro, futures_api)] +#![feature(async_await, await_macro)] use futures::channel::mpsc; use futures::executor::block_on; diff --git a/futures-channel/tests/mpsc.rs b/futures-channel/tests/mpsc.rs index 823dd25f94..4b42e3f040 100644 --- a/futures-channel/tests/mpsc.rs +++ b/futures-channel/tests/mpsc.rs @@ -1,4 +1,4 @@ -#![feature(futures_api, async_await, await_macro)] +#![feature(async_await, await_macro)] use futures::channel::{mpsc, oneshot}; use futures::executor::{block_on, block_on_stream}; diff --git a/futures-channel/tests/oneshot.rs b/futures-channel/tests/oneshot.rs index 8b820b1611..b36d25df60 100644 --- a/futures-channel/tests/oneshot.rs +++ b/futures-channel/tests/oneshot.rs @@ -1,5 +1,3 @@ -#![feature(futures_api)] - use futures::channel::oneshot::{self, Sender}; use futures::executor::block_on; use futures::future::{Future, FutureExt, poll_fn}; diff --git a/futures-core/src/lib.rs b/futures-core/src/lib.rs index fbffb63653..1971629ff8 100644 --- a/futures-core/src/lib.rs +++ b/futures-core/src/lib.rs @@ -1,6 +1,5 @@ //! Core traits and types for asynchronous operations in Rust. -#![feature(futures_api)] #![cfg_attr(feature = "cfg-target-has-atomic", feature(cfg_target_has_atomic))] #![cfg_attr(not(feature = "std"), no_std)] diff --git a/futures-core/src/task/__internal/atomic_waker.rs b/futures-core/src/task/__internal/atomic_waker.rs index 11772ec4f4..f7b694c1ea 100644 --- a/futures-core/src/task/__internal/atomic_waker.rs +++ b/futures-core/src/task/__internal/atomic_waker.rs @@ -169,7 +169,6 @@ impl AtomicWaker { /// Here is how `register` is used when implementing a flag. /// /// ``` - /// #![feature(futures_api)] /// use futures::future::Future; /// use futures::task::{Context, Poll, AtomicWaker}; /// use std::sync::atomic::AtomicBool; diff --git a/futures-executor/benches/thread_notify.rs b/futures-executor/benches/thread_notify.rs index b317a864db..d8fbec4555 100644 --- a/futures-executor/benches/thread_notify.rs +++ b/futures-executor/benches/thread_notify.rs @@ -1,4 +1,4 @@ -#![feature(test, futures_api)] +#![feature(test)] extern crate test; use crate::test::Bencher; diff --git a/futures-executor/src/lib.rs b/futures-executor/src/lib.rs index c4064b66f1..bbcda09786 100644 --- a/futures-executor/src/lib.rs +++ b/futures-executor/src/lib.rs @@ -1,7 +1,5 @@ //! Built-in executors and related tools. -#![feature(futures_api)] - #![cfg_attr(not(feature = "std"), no_std)] #![warn(missing_docs, missing_debug_implementations, rust_2018_idioms)] diff --git a/futures-executor/src/local_pool.rs b/futures-executor/src/local_pool.rs index 1116e700ee..d624099e1a 100644 --- a/futures-executor/src/local_pool.rs +++ b/futures-executor/src/local_pool.rs @@ -132,7 +132,6 @@ impl LocalPool { /// the `LocalPool` by using its spawner handle: /// /// ``` - /// #![feature(futures_api)] /// use futures::executor::LocalPool; /// use futures::future::ready; /// @@ -170,7 +169,6 @@ impl LocalPool { /// can be made. Returns `true` if one future was completed, `false` otherwise. /// /// ``` - /// #![feature(futures_api)] /// use futures::executor::LocalPool; /// use futures::task::LocalSpawnExt; /// use futures::future::{ready, empty}; @@ -211,7 +209,6 @@ impl LocalPool { /// on any task. /// /// ``` - /// #![feature(futures_api)] /// use futures::executor::LocalPool; /// use futures::task::LocalSpawnExt; /// use futures::future::{ready, empty}; diff --git a/futures-executor/tests/local_pool.rs b/futures-executor/tests/local_pool.rs index 1f6958130d..44b0a76ff0 100644 --- a/futures-executor/tests/local_pool.rs +++ b/futures-executor/tests/local_pool.rs @@ -1,5 +1,3 @@ -#![feature(futures_api)] - use futures::channel::oneshot; use futures::executor::LocalPool; use futures::future::{Future, lazy, poll_fn}; diff --git a/futures-io/src/lib.rs b/futures-io/src/lib.rs index cacfd0465f..d9e04c88ca 100644 --- a/futures-io/src/lib.rs +++ b/futures-io/src/lib.rs @@ -10,8 +10,6 @@ #![doc(html_root_url = "https://rust-lang-nursery.github.io/futures-api-docs/0.3.0-alpha.14/futures_io")] -#![feature(futures_api)] - #[cfg(feature = "std")] mod if_std { use futures_core::task::{Context, Poll}; diff --git a/futures-io/tests/cursor.rs b/futures-io/tests/cursor.rs index 27eafe3683..09a622ce0f 100644 --- a/futures-io/tests/cursor.rs +++ b/futures-io/tests/cursor.rs @@ -1,5 +1,3 @@ -#![feature(futures_api)] - use assert_matches::assert_matches; use futures::Poll; use futures::future::lazy; diff --git a/futures-sink/src/lib.rs b/futures-sink/src/lib.rs index f475c41647..58c79134d1 100644 --- a/futures-sink/src/lib.rs +++ b/futures-sink/src/lib.rs @@ -7,8 +7,6 @@ #![warn(missing_docs, missing_debug_implementations, rust_2018_idioms)] #![doc(html_root_url = "https://rust-lang-nursery.github.io/futures-api-docs/0.3.0-alpha.14/futures_sink")] -#![feature(futures_api)] - #[cfg(feature = "alloc")] extern crate alloc; diff --git a/futures-test/src/assert.rs b/futures-test/src/assert.rs index d4e15de6bd..2b73a79067 100644 --- a/futures-test/src/assert.rs +++ b/futures-test/src/assert.rs @@ -9,7 +9,7 @@ pub fn assert_is_unpin_stream(_: &mut S) {} /// # Examples /// /// ``` -/// #![feature(async_await, futures_api)] +/// #![feature(async_await)] /// use futures::stream; /// use futures_test::future::FutureTestExt; /// use futures_test::{ @@ -46,7 +46,7 @@ macro_rules! assert_stream_pending { /// # Examples /// /// ``` -/// #![feature(async_await, futures_api)] +/// #![feature(async_await)] /// use futures::stream; /// use futures_test::future::FutureTestExt; /// use futures_test::{ @@ -89,7 +89,7 @@ macro_rules! assert_stream_next { /// # Examples /// /// ``` -/// #![feature(async_await, futures_api)] +/// #![feature(async_await)] /// use futures::stream; /// use futures_test::future::FutureTestExt; /// use futures_test::{ diff --git a/futures-test/src/future/mod.rs b/futures-test/src/future/mod.rs index 80288afb91..a3e56c7906 100644 --- a/futures-test/src/future/mod.rs +++ b/futures-test/src/future/mod.rs @@ -33,7 +33,7 @@ pub trait FutureTestExt: Future { /// # Examples /// /// ``` - /// #![feature(async_await, futures_api)] + /// #![feature(async_await)] /// use futures::task::Poll; /// use futures::future::FutureExt; /// use futures_test::task::noop_context; @@ -60,7 +60,7 @@ pub trait FutureTestExt: Future { /// # Examples /// /// ``` - /// #![feature(async_await, futures_api)] + /// #![feature(async_await)] /// use futures::channel::oneshot; /// use futures::executor::block_on; /// use futures_test::future::FutureTestExt; diff --git a/futures-test/src/lib.rs b/futures-test/src/lib.rs index 78850dc170..8bb000728a 100644 --- a/futures-test/src/lib.rs +++ b/futures-test/src/lib.rs @@ -1,10 +1,6 @@ //! Utilities to make testing [`Future`s](futures_core::Future) easier -#![feature( - async_await, - await_macro, - futures_api, -)] +#![feature(async_await, await_macro)] #![warn(missing_docs, missing_debug_implementations, rust_2018_idioms)] #![doc( html_root_url = "https://rust-lang-nursery.github.io/futures-doc/0.3.0-alpha.5/futures_test" diff --git a/futures-test/src/task/context.rs b/futures-test/src/task/context.rs index ad19c4fec9..a86bd335a7 100644 --- a/futures-test/src/task/context.rs +++ b/futures-test/src/task/context.rs @@ -7,7 +7,6 @@ use futures_core::task::Context; /// # Examples /// /// ```should_panic -/// #![feature(futures_api)] /// use futures_test::task::panic_context; /// /// let cx = panic_context(); @@ -23,7 +22,7 @@ pub fn panic_context() -> Context<'static> { /// # Examples /// /// ``` -/// #![feature(async_await, futures_api)] +/// #![feature(async_await)] /// use futures::future::Future; /// use futures::task::Poll; /// use futures_test::task::noop_context; diff --git a/futures-test/src/task/noop_spawner.rs b/futures-test/src/task/noop_spawner.rs index 8882933a1a..7bc3facc83 100644 --- a/futures-test/src/task/noop_spawner.rs +++ b/futures-test/src/task/noop_spawner.rs @@ -7,7 +7,7 @@ use futures_core::task::{Spawn, SpawnError}; /// # Examples /// /// ``` -/// #![feature(async_await, futures_api)] +/// #![feature(async_await)] /// use futures::task::SpawnExt; /// use futures_test::task::NoopSpawner; /// @@ -46,7 +46,7 @@ impl Default for NoopSpawner { /// # Examples /// /// ``` -/// #![feature(async_await, futures_api)] +/// #![feature(async_await)] /// use futures::task::SpawnExt; /// use futures_test::task::noop_spawner_mut; /// diff --git a/futures-test/src/task/panic_spawner.rs b/futures-test/src/task/panic_spawner.rs index 3e14431c57..8a7ca46201 100644 --- a/futures-test/src/task/panic_spawner.rs +++ b/futures-test/src/task/panic_spawner.rs @@ -7,7 +7,7 @@ use futures_core::task::{Spawn, SpawnError}; /// # Examples /// /// ```should_panic -/// #![feature(async_await, futures_api)] +/// #![feature(async_await)] /// use futures::task::SpawnExt; /// use futures_test::task::PanicSpawner; /// @@ -46,7 +46,7 @@ impl Default for PanicSpawner { /// # Examples /// /// ```should_panic -/// #![feature(async_await, futures_api)] +/// #![feature(async_await)] /// use futures::task::SpawnExt; /// use futures_test::task::panic_spawner_mut; /// diff --git a/futures-test/src/task/panic_waker.rs b/futures-test/src/task/panic_waker.rs index 6e5295cc37..304163ee6a 100644 --- a/futures-test/src/task/panic_waker.rs +++ b/futures-test/src/task/panic_waker.rs @@ -30,7 +30,6 @@ fn raw_panic_waker() -> RawWaker { /// # Examples /// /// ```should_panic -/// #![feature(futures_api)] /// use futures_test::task::panic_waker; /// /// let waker = panic_waker(); @@ -47,7 +46,7 @@ pub fn panic_waker() -> Waker { /// # Examples /// /// ```should_panic -/// #![feature(async_await, futures_api)] +/// #![feature(async_await)] /// use futures::task; /// use futures_test::task::panic_waker_ref; /// diff --git a/futures-test/src/task/record_spawner.rs b/futures-test/src/task/record_spawner.rs index 5ac9aed0ff..d4886cfe68 100644 --- a/futures-test/src/task/record_spawner.rs +++ b/futures-test/src/task/record_spawner.rs @@ -7,7 +7,7 @@ use futures_core::task::{Spawn, SpawnError}; /// # Examples /// /// ``` -/// #![feature(async_await, futures_api)] +/// #![feature(async_await)] /// use futures::task::SpawnExt; /// use futures_test::task::RecordSpawner; /// diff --git a/futures-test/src/task/wake_counter.rs b/futures-test/src/task/wake_counter.rs index e4d5df188f..9fb2dbdbf8 100644 --- a/futures-test/src/task/wake_counter.rs +++ b/futures-test/src/task/wake_counter.rs @@ -42,7 +42,6 @@ impl ArcWake for WakerInner { /// # Examples /// /// ``` -/// #![feature(futures_api)] /// use futures_test::task::new_count_waker; /// /// let (waker, count) = new_count_waker(); diff --git a/futures-util/benches/futures_unordered.rs b/futures-util/benches/futures_unordered.rs index 9608eafa0d..05e9eadb79 100644 --- a/futures-util/benches/futures_unordered.rs +++ b/futures-util/benches/futures_unordered.rs @@ -1,4 +1,4 @@ -#![feature(test, futures_api)] +#![feature(test)] extern crate test; use crate::test::Bencher; diff --git a/futures-util/src/async_await/join.rs b/futures-util/src/async_await/join.rs index 5d8d5b185d..227d6466b8 100644 --- a/futures-util/src/async_await/join.rs +++ b/futures-util/src/async_await/join.rs @@ -11,7 +11,7 @@ /// # Examples /// /// ``` -/// #![feature(async_await, await_macro, futures_api)] +/// #![feature(async_await, await_macro)] /// # futures::executor::block_on(async { /// use futures::{join, future}; /// @@ -60,7 +60,7 @@ macro_rules! join { /// `Ok` of a tuple of the values: /// /// ``` -/// #![feature(async_await, await_macro, futures_api)] +/// #![feature(async_await, await_macro)] /// # futures::executor::block_on(async { /// use futures::{try_join, future}; /// @@ -75,7 +75,7 @@ macro_rules! join { /// that error: /// /// ``` -/// #![feature(async_await, await_macro, futures_api)] +/// #![feature(async_await, await_macro)] /// # futures::executor::block_on(async { /// use futures::{try_join, future}; /// diff --git a/futures-util/src/async_await/select_mod.rs b/futures-util/src/async_await/select_mod.rs index 5a7f638d30..8aedddca6f 100644 --- a/futures-util/src/async_await/select_mod.rs +++ b/futures-util/src/async_await/select_mod.rs @@ -24,7 +24,7 @@ macro_rules! document_select_macro { /// # Examples /// /// ``` - /// #![feature(async_await, await_macro, futures_api)] + /// #![feature(async_await, await_macro)] /// # futures::executor::block_on(async { /// use futures::future::{self, FutureExt}; /// use futures::select; @@ -40,7 +40,7 @@ macro_rules! document_select_macro { /// ``` /// /// ``` - /// #![feature(async_await, await_macro, futures_api)] + /// #![feature(async_await, await_macro)] /// # futures::executor::block_on(async { /// use futures::future::{self, FutureExt}; /// use futures::stream::{self, StreamExt}; @@ -62,7 +62,7 @@ macro_rules! document_select_macro { /// the case where all futures have completed. /// /// ``` - /// #![feature(async_await, await_macro, futures_api)] + /// #![feature(async_await, await_macro)] /// # futures::executor::block_on(async { /// use futures::future::{self, FutureExt}; /// use futures::select; diff --git a/futures-util/src/compat/compat01as03.rs b/futures-util/src/compat/compat01as03.rs index d35f4b0dfd..537044eb1b 100644 --- a/futures-util/src/compat/compat01as03.rs +++ b/futures-util/src/compat/compat01as03.rs @@ -52,7 +52,7 @@ pub trait Future01CompatExt: Future01 { /// [`Future>`](futures_core::future::Future). /// /// ``` - /// #![feature(async_await, await_macro, futures_api)] + /// #![feature(async_await, await_macro)] /// # futures::executor::block_on(async { /// # // TODO: These should be all using `futures::compat`, but that runs up against Cargo /// # // feature issues @@ -79,7 +79,7 @@ pub trait Stream01CompatExt: Stream01 { /// [`Stream>`](futures_core::stream::Stream). /// /// ``` - /// #![feature(async_await, await_macro, futures_api)] + /// #![feature(async_await, await_macro)] /// # futures::executor::block_on(async { /// use futures::stream::StreamExt; /// use futures_util::compat::Stream01CompatExt; @@ -107,7 +107,7 @@ pub trait Sink01CompatExt: Sink01 { /// [`Sink`](futures_sink::sink::Sink). /// /// ``` - /// #![feature(async_await, await_macro, futures_api)] + /// #![feature(async_await, await_macro)] /// # futures::executor::block_on(async { /// use futures::{sink::SinkExt, stream::StreamExt}; /// use futures_util::compat::{Stream01CompatExt, Sink01CompatExt}; @@ -356,7 +356,7 @@ mod io { /// [`AsyncRead`](futures_io::AsyncRead). /// /// ``` - /// #![feature(async_await, await_macro, futures_api, impl_trait_in_bindings)] + /// #![feature(async_await, await_macro, impl_trait_in_bindings)] /// # futures::executor::block_on(async { /// use futures::io::AsyncReadExt; /// use futures_util::compat::AsyncRead01CompatExt; @@ -385,7 +385,7 @@ mod io { /// [`AsyncWrite`](futures_io::AsyncWrite). /// /// ``` - /// #![feature(async_await, await_macro, futures_api, impl_trait_in_bindings)] + /// #![feature(async_await, await_macro, impl_trait_in_bindings)] /// # futures::executor::block_on(async { /// use futures::io::AsyncWriteExt; /// use futures_util::compat::AsyncWrite01CompatExt; diff --git a/futures-util/src/compat/executor.rs b/futures-util/src/compat/executor.rs index 04f9350dde..43bb26a28f 100644 --- a/futures-util/src/compat/executor.rs +++ b/futures-util/src/compat/executor.rs @@ -22,7 +22,7 @@ pub trait Executor01CompatExt: Executor01 + /// futures 0.3 [`Spawn`](futures_core::task::Spawn). /// /// ``` - /// #![feature(async_await, await_macro, futures_api)] + /// #![feature(async_await, await_macro)] /// use futures::Future; /// use futures::task::SpawnExt; /// use futures::future::{FutureExt, TryFutureExt}; diff --git a/futures-util/src/future/empty.rs b/futures-util/src/future/empty.rs index 5cf183225c..8e51630dec 100644 --- a/futures-util/src/future/empty.rs +++ b/futures-util/src/future/empty.rs @@ -22,7 +22,7 @@ impl FusedFuture for Empty { /// # Examples /// /// ```ignore -/// #![feature(async_await, await_macro, futures_api)] +/// #![feature(async_await, await_macro)] /// # futures::executor::block_on(async { /// use futures::future; /// diff --git a/futures-util/src/future/join.rs b/futures-util/src/future/join.rs index 155562009c..e62c060d1f 100644 --- a/futures-util/src/future/join.rs +++ b/futures-util/src/future/join.rs @@ -90,7 +90,7 @@ generate! { /// # Examples /// /// ``` -/// #![feature(async_await, await_macro, futures_api)] +/// #![feature(async_await, await_macro)] /// # futures::executor::block_on(async { /// use futures::future; /// @@ -115,7 +115,7 @@ where /// # Examples /// /// ``` -/// #![feature(async_await, await_macro, futures_api)] +/// #![feature(async_await, await_macro)] /// # futures::executor::block_on(async { /// use futures::future; /// @@ -145,7 +145,7 @@ where /// # Examples /// /// ``` -/// #![feature(async_await, await_macro, futures_api)] +/// #![feature(async_await, await_macro)] /// # futures::executor::block_on(async { /// use futures::future; /// @@ -179,7 +179,7 @@ where /// # Examples /// /// ``` -/// #![feature(async_await, await_macro, futures_api)] +/// #![feature(async_await, await_macro)] /// # futures::executor::block_on(async { /// use futures::future; /// diff --git a/futures-util/src/future/join_all.rs b/futures-util/src/future/join_all.rs index df329dd2f1..c6a6b532d1 100644 --- a/futures-util/src/future/join_all.rs +++ b/futures-util/src/future/join_all.rs @@ -99,7 +99,7 @@ where /// # Examples /// /// ``` -/// #![feature(async_await, await_macro, futures_api)] +/// #![feature(async_await, await_macro)] /// # futures::executor::block_on(async { /// use futures::future::{join_all}; /// diff --git a/futures-util/src/future/lazy.rs b/futures-util/src/future/lazy.rs index 1e0e9660bd..f35c99d8c5 100644 --- a/futures-util/src/future/lazy.rs +++ b/futures-util/src/future/lazy.rs @@ -19,7 +19,7 @@ impl Unpin for Lazy {} /// # Examples /// /// ``` -/// #![feature(async_await, await_macro, futures_api)] +/// #![feature(async_await, await_macro)] /// # futures::executor::block_on(async { /// use futures::future; /// diff --git a/futures-util/src/future/maybe_done.rs b/futures-util/src/future/maybe_done.rs index dc174e5ca7..6ee9e3bad4 100644 --- a/futures-util/src/future/maybe_done.rs +++ b/futures-util/src/future/maybe_done.rs @@ -27,7 +27,7 @@ impl Unpin for MaybeDone {} /// # Examples /// /// ``` -/// #![feature(async_await, await_macro, futures_api)] +/// #![feature(async_await, await_macro)] /// # futures::executor::block_on(async { /// use futures::future; /// use pin_utils::pin_mut; diff --git a/futures-util/src/future/mod.rs b/futures-util/src/future/mod.rs index b42ba2f556..51ef6caea3 100644 --- a/futures-util/src/future/mod.rs +++ b/futures-util/src/future/mod.rs @@ -134,7 +134,7 @@ pub trait FutureExt: Future { /// # Examples /// /// ``` - /// #![feature(async_await, await_macro, futures_api)] + /// #![feature(async_await, await_macro)] /// # futures::executor::block_on(async { /// use futures::future::{self, FutureExt}; /// @@ -166,7 +166,7 @@ pub trait FutureExt: Future { /// # Examples /// /// ``` - /// #![feature(async_await, await_macro, futures_api)] + /// #![feature(async_await, await_macro)] /// # futures::executor::block_on(async { /// use futures::future::{self, FutureExt}; /// @@ -192,7 +192,7 @@ pub trait FutureExt: Future { /// # Examples /// /// ``` - /// #![feature(async_await, await_macro, futures_api)] + /// #![feature(async_await, await_macro)] /// # futures::executor::block_on(async { /// use futures::future::{self, FutureExt}; /// @@ -222,7 +222,7 @@ pub trait FutureExt: Future { /// # Examples /// /// ``` - /// #![feature(async_await, await_macro, futures_api)] + /// #![feature(async_await, await_macro)] /// # futures::executor::block_on(async { /// use futures::future::{self, FutureExt}; /// @@ -251,7 +251,7 @@ pub trait FutureExt: Future { /// # Examples /// /// ``` - /// #![feature(async_await, await_macro, futures_api)] + /// #![feature(async_await, await_macro)] /// # futures::executor::block_on(async { /// use futures::future::{self, FutureExt}; /// use futures::stream::StreamExt; @@ -285,7 +285,7 @@ pub trait FutureExt: Future { /// # Examples /// /// ``` - /// #![feature(async_await, await_macro, futures_api)] + /// #![feature(async_await, await_macro)] /// # futures::executor::block_on(async { /// use futures::future::{self, FutureExt}; /// @@ -315,7 +315,7 @@ pub trait FutureExt: Future { /// # Examples /// /// ``` - /// #![feature(async_await, await_macro, futures_api)] + /// #![feature(async_await, await_macro)] /// # futures::executor::block_on(async { /// use futures::future::{self, FutureExt}; /// use futures::stream::{self, StreamExt}; @@ -368,7 +368,7 @@ pub trait FutureExt: Future { /// # Examples /// /// ``` - /// #![feature(async_await, await_macro, futures_api)] + /// #![feature(async_await, await_macro)] /// # futures::executor::block_on(async { /// use futures::future::{self, FutureExt}; /// @@ -405,7 +405,7 @@ pub trait FutureExt: Future { // TODO: minimize and open rust-lang/rust ticket, currently errors: // 'assertion failed: !value.has_escaping_regions()' /// ```ignore - /// #![feature(async_await, await_macro, futures_api)] + /// #![feature(async_await, await_macro)] /// # futures::executor::block_on(async { /// use futures::future::{self, FutureExt, Ready}; /// @@ -438,7 +438,7 @@ pub trait FutureExt: Future { /// # Examples /// /// ``` - /// #![feature(async_await, await_macro, futures_api)] + /// #![feature(async_await, await_macro)] /// # futures::executor::block_on(async { /// use futures::future::{self, FutureExt}; /// diff --git a/futures-util/src/future/option.rs b/futures-util/src/future/option.rs index 3d7bc35be4..99b5adcc36 100644 --- a/futures-util/src/future/option.rs +++ b/futures-util/src/future/option.rs @@ -12,7 +12,7 @@ use pin_utils::unsafe_pinned; /// # Examples /// /// ``` -/// #![feature(async_await, await_macro, futures_api)] +/// #![feature(async_await, await_macro)] /// # futures::executor::block_on(async { /// use futures::future::{self, OptionFuture}; /// diff --git a/futures-util/src/future/poll_fn.rs b/futures-util/src/future/poll_fn.rs index 501b77b995..f8b2424bcf 100644 --- a/futures-util/src/future/poll_fn.rs +++ b/futures-util/src/future/poll_fn.rs @@ -20,7 +20,7 @@ impl Unpin for PollFn {} /// # Examples /// /// ``` -/// #![feature(async_await, await_macro, futures_api)] +/// #![feature(async_await, await_macro)] /// # futures::executor::block_on(async { /// use futures::future::poll_fn; /// use futures::task::{Context, Poll}; diff --git a/futures-util/src/future/ready.rs b/futures-util/src/future/ready.rs index 761367ae93..0ae12907eb 100644 --- a/futures-util/src/future/ready.rs +++ b/futures-util/src/future/ready.rs @@ -29,7 +29,7 @@ impl Future for Ready { /// # Examples /// /// ``` -/// #![feature(async_await, await_macro, futures_api)] +/// #![feature(async_await, await_macro)] /// # futures::executor::block_on(async { /// use futures::future; /// @@ -46,7 +46,7 @@ pub fn ready(t: T) -> Ready { /// # Examples /// /// ``` -/// #![feature(async_await, await_macro, futures_api)] +/// #![feature(async_await, await_macro)] /// # futures::executor::block_on(async { /// use futures::future; /// @@ -63,7 +63,7 @@ pub fn ok(t: T) -> Ready> { /// # Examples /// /// ``` -/// #![feature(async_await, await_macro, futures_api)] +/// #![feature(async_await, await_macro)] /// # futures::executor::block_on(async { /// use futures::future; /// diff --git a/futures-util/src/future/select.rs b/futures-util/src/future/select.rs index 09fa27206c..cc5591059b 100644 --- a/futures-util/src/future/select.rs +++ b/futures-util/src/future/select.rs @@ -28,7 +28,6 @@ impl Unpin for Select {} /// # Examples /// /// ``` -/// #![feature(futures_api)] /// use futures::future::{self, Either, Future, FutureExt}; /// /// // A poor-man's join implemented on top of select diff --git a/futures-util/src/io/mod.rs b/futures-util/src/io/mod.rs index 8c34a38283..e2c2473472 100644 --- a/futures-util/src/io/mod.rs +++ b/futures-util/src/io/mod.rs @@ -61,7 +61,7 @@ pub trait AsyncReadExt: AsyncRead { /// # Examples /// /// ``` - /// #![feature(async_await, await_macro, futures_api)] + /// #![feature(async_await, await_macro)] /// # futures::executor::block_on(async { /// use futures::io::AsyncReadExt; /// use std::io::Cursor; @@ -93,7 +93,7 @@ pub trait AsyncReadExt: AsyncRead { /// # Examples /// /// ``` - /// #![feature(async_await, await_macro, futures_api)] + /// #![feature(async_await, await_macro)] /// # futures::executor::block_on(async { /// use futures::io::AsyncReadExt; /// use std::io::Cursor; @@ -127,7 +127,7 @@ pub trait AsyncReadExt: AsyncRead { /// # Examples /// /// ``` - /// #![feature(async_await, await_macro, futures_api)] + /// #![feature(async_await, await_macro)] /// # futures::executor::block_on(async { /// use futures::io::AsyncReadExt; /// use std::io::Cursor; @@ -144,7 +144,7 @@ pub trait AsyncReadExt: AsyncRead { /// ## EOF is hit before `buf` is filled /// /// ``` - /// #![feature(async_await, await_macro, futures_api)] + /// #![feature(async_await, await_macro)] /// # futures::executor::block_on(async { /// use futures::io::AsyncReadExt; /// use std::io::{self, Cursor}; @@ -171,7 +171,7 @@ pub trait AsyncReadExt: AsyncRead { /// # Examples /// /// ``` - /// #![feature(async_await, await_macro, futures_api)] + /// #![feature(async_await, await_macro)] /// # futures::executor::block_on(async { /// use futures::io::AsyncReadExt; /// use std::io::Cursor; @@ -201,7 +201,7 @@ pub trait AsyncReadExt: AsyncRead { /// # Examples /// /// ``` - /// #![feature(async_await, await_macro, futures_api)] + /// #![feature(async_await, await_macro)] /// # futures::executor::block_on(async { /// use futures::io::AsyncReadExt; /// use std::io::Cursor; @@ -253,7 +253,7 @@ pub trait AsyncWriteExt: AsyncWrite { /// # Examples /// /// ``` - /// #![feature(async_await, await_macro, futures_api)] + /// #![feature(async_await, await_macro)] /// # futures::executor::block_on(async { /// use futures::io::{AllowStdIo, AsyncWriteExt}; /// use std::io::{BufWriter, Cursor}; @@ -294,7 +294,7 @@ pub trait AsyncWriteExt: AsyncWrite { /// # Examples /// /// ``` - /// #![feature(async_await, await_macro, futures_api)] + /// #![feature(async_await, await_macro)] /// # futures::executor::block_on(async { /// use futures::io::AsyncWriteExt; /// use std::io::Cursor; diff --git a/futures-util/src/lib.rs b/futures-util/src/lib.rs index 857c63dfb5..94d555d9a2 100644 --- a/futures-util/src/lib.rs +++ b/futures-util/src/lib.rs @@ -1,7 +1,6 @@ //! Combinators and utilities for working with `Future`s, `Stream`s, `Sink`s, //! and the `AsyncRead` and `AsyncWrite` traits. -#![feature(futures_api)] #![cfg_attr(feature = "alloc", feature(box_into_pin))] #![cfg_attr(feature = "std", feature(async_await, await_macro))] #![cfg_attr(feature = "cfg-target-has-atomic", feature(cfg_target_has_atomic))] diff --git a/futures-util/src/sink/drain.rs b/futures-util/src/sink/drain.rs index 2e5d505dd7..7a490da216 100644 --- a/futures-util/src/sink/drain.rs +++ b/futures-util/src/sink/drain.rs @@ -23,7 +23,7 @@ pub enum DrainError { /// # Examples /// /// ``` -/// #![feature(async_await, await_macro, futures_api)] +/// #![feature(async_await, await_macro)] /// # futures::executor::block_on(async { /// use futures::sink::{self, SinkExt}; /// diff --git a/futures-util/src/stream/mod.rs b/futures-util/src/stream/mod.rs index 54b48afc9f..505feaa832 100644 --- a/futures-util/src/stream/mod.rs +++ b/futures-util/src/stream/mod.rs @@ -270,7 +270,7 @@ pub trait StreamExt: Stream { /// # Examples /// /// ``` - /// #![feature(async_await, await_macro, futures_api)] + /// #![feature(async_await, await_macro)] /// # futures::executor::block_on(async { /// use futures::stream::{self, StreamExt}; /// @@ -643,7 +643,7 @@ pub trait StreamExt: Stream { /// # Examples /// /// ``` - /// #![feature(async_await, await_macro, futures_api)] + /// #![feature(async_await, await_macro)] /// # futures::executor::block_on(async { /// use futures::channel::oneshot; /// use futures::stream::{self, StreamExt}; @@ -741,7 +741,6 @@ pub trait StreamExt: Stream { /// # Examples /// /// ``` - /// #![feature(futures_api)] /// use futures::executor::block_on_stream; /// use futures::stream::{self, StreamExt}; /// use futures::task::Poll; @@ -892,7 +891,7 @@ pub trait StreamExt: Stream { /// # Examples /// /// ``` - /// #![feature(async_await, await_macro, futures_api)] + /// #![feature(async_await, await_macro)] /// # futures::executor::block_on(async { /// use futures::channel::oneshot; /// use futures::stream::{self, StreamExt}; @@ -1116,7 +1115,7 @@ pub trait StreamExt: Stream { /// # Examples /// /// ``` - /// #![feature(async_await, await_macro, futures_api)] + /// #![feature(async_await, await_macro)] /// # futures::executor::block_on(async { /// use futures::{future, select}; /// use futures::stream::{StreamExt, FuturesUnordered}; diff --git a/futures-util/src/stream/poll_fn.rs b/futures-util/src/stream/poll_fn.rs index ecbb5aa1d3..908b6aac61 100644 --- a/futures-util/src/stream/poll_fn.rs +++ b/futures-util/src/stream/poll_fn.rs @@ -20,7 +20,6 @@ impl Unpin for PollFn {} /// # Examples /// /// ``` -/// #![feature(futures_api)] /// use futures::stream::poll_fn; /// use futures::task::Poll; /// diff --git a/futures-util/src/task/noop_waker.rs b/futures-util/src/task/noop_waker.rs index 1378c13cec..971062b9f1 100644 --- a/futures-util/src/task/noop_waker.rs +++ b/futures-util/src/task/noop_waker.rs @@ -23,7 +23,6 @@ fn noop_raw_waker() -> RawWaker { /// # Examples /// /// ``` -/// #![feature(futures_api)] /// use futures::task::noop_waker; /// let waker = noop_waker(); /// waker.wake(); @@ -42,7 +41,6 @@ pub fn noop_waker() -> Waker { /// # Examples /// /// ``` -/// #![feature(futures_api)] /// use futures::task::noop_waker_ref; /// let waker = noop_waker_ref(); /// waker.wake_by_ref(); diff --git a/futures-util/src/task/spawn.rs b/futures-util/src/task/spawn.rs index e414dccf74..70eaa23456 100644 --- a/futures-util/src/task/spawn.rs +++ b/futures-util/src/task/spawn.rs @@ -32,7 +32,7 @@ pub trait SpawnExt: Spawn { /// today. Feel free to use this method in the meantime. /// /// ``` - /// #![feature(async_await, await_macro, futures_api)] + /// #![feature(async_await, await_macro)] /// use futures::executor::ThreadPool; /// use futures::task::SpawnExt; /// @@ -57,7 +57,7 @@ pub trait SpawnExt: Spawn { /// resolves to the output of the spawned future. /// /// ``` - /// #![feature(async_await, await_macro, futures_api)] + /// #![feature(async_await, await_macro)] /// use futures::executor::ThreadPool; /// use futures::future; /// use futures::task::SpawnExt; @@ -110,7 +110,7 @@ pub trait LocalSpawnExt: LocalSpawn { /// today. Feel free to use this method in the meantime. /// /// ``` - /// #![feature(async_await, await_macro, futures_api)] + /// #![feature(async_await, await_macro)] /// use futures::executor::LocalPool; /// use futures::task::LocalSpawnExt; /// @@ -136,7 +136,7 @@ pub trait LocalSpawnExt: LocalSpawn { /// resolves to the output of the spawned future. /// /// ``` - /// #![feature(async_await, await_macro, futures_api)] + /// #![feature(async_await, await_macro)] /// use futures::executor::LocalPool; /// use futures::future; /// use futures::task::LocalSpawnExt; diff --git a/futures-util/src/try_future/mod.rs b/futures-util/src/try_future/mod.rs index de93a7695e..ba9db5b8fb 100644 --- a/futures-util/src/try_future/mod.rs +++ b/futures-util/src/try_future/mod.rs @@ -79,7 +79,6 @@ pub trait TryFutureExt: TryFuture { /// # Examples /// /// ``` - /// #![feature(futures_api)] /// use futures::future::{Future, TryFutureExt}; /// use futures::sink::Sink; /// # use futures::channel::mpsc::{self, SendError}; @@ -123,7 +122,7 @@ pub trait TryFutureExt: TryFuture { /// # Examples /// /// ``` - /// #![feature(async_await, await_macro, futures_api)] + /// #![feature(async_await, await_macro)] /// use futures::future::{self, TryFutureExt}; /// /// # futures::executor::block_on(async { @@ -137,7 +136,7 @@ pub trait TryFutureExt: TryFuture { /// effect: /// /// ``` - /// #![feature(async_await, await_macro, futures_api)] + /// #![feature(async_await, await_macro)] /// use futures::future::{self, TryFutureExt}; /// /// # futures::executor::block_on(async { @@ -171,7 +170,7 @@ pub trait TryFutureExt: TryFuture { /// # Examples /// /// ``` - /// #![feature(async_await, await_macro, futures_api)] + /// #![feature(async_await, await_macro)] /// use futures::future::{self, TryFutureExt}; /// /// # futures::executor::block_on(async { @@ -185,7 +184,7 @@ pub trait TryFutureExt: TryFuture { /// no effect: /// /// ``` - /// #![feature(async_await, await_macro, futures_api)] + /// #![feature(async_await, await_macro)] /// use futures::future::{self, TryFutureExt}; /// /// # futures::executor::block_on(async { @@ -216,7 +215,7 @@ pub trait TryFutureExt: TryFuture { /// # Examples /// /// ``` - /// #![feature(async_await, await_macro, futures_api)] + /// #![feature(async_await, await_macro)] /// use futures::future::{self, TryFutureExt}; /// /// # futures::executor::block_on(async { @@ -246,7 +245,7 @@ pub trait TryFutureExt: TryFuture { /// # Examples /// /// ``` - /// #![feature(async_await, await_macro, futures_api)] + /// #![feature(async_await, await_macro)] /// use futures::future::{self, TryFutureExt}; /// /// # futures::executor::block_on(async { @@ -260,7 +259,7 @@ pub trait TryFutureExt: TryFuture { /// effect: /// /// ``` - /// #![feature(async_await, await_macro, futures_api)] + /// #![feature(async_await, await_macro)] /// use futures::future::{self, TryFutureExt}; /// /// # futures::executor::block_on(async { @@ -292,7 +291,7 @@ pub trait TryFutureExt: TryFuture { /// # Examples /// /// ``` - /// #![feature(async_await, await_macro, futures_api)] + /// #![feature(async_await, await_macro)] /// use futures::future::{self, TryFutureExt}; /// /// # futures::executor::block_on(async { @@ -306,7 +305,7 @@ pub trait TryFutureExt: TryFuture { /// no effect: /// /// ``` - /// #![feature(async_await, await_macro, futures_api)] + /// #![feature(async_await, await_macro)] /// use futures::future::{self, TryFutureExt}; /// /// # futures::executor::block_on(async { @@ -381,7 +380,7 @@ pub trait TryFutureExt: TryFuture { /// # Examples /// /// ``` - /// #![feature(async_await, await_macro, futures_api)] + /// #![feature(async_await, await_macro)] /// use futures::future::{self, TryFutureExt}; /// /// # futures::executor::block_on(async { @@ -416,7 +415,6 @@ pub trait TryFutureExt: TryFuture { /// # Examples /// /// ``` - /// #![feature(futures_api)] /// use futures::future::{Future, TryFuture, TryFutureExt}; /// /// # type T = i32; diff --git a/futures-util/src/try_future/try_join.rs b/futures-util/src/try_future/try_join.rs index 1756784ec8..8809bd87ca 100644 --- a/futures-util/src/try_future/try_join.rs +++ b/futures-util/src/try_future/try_join.rs @@ -133,7 +133,7 @@ generate! { /// [`Ok`] of a tuple of the values: /// /// ``` -/// #![feature(async_await, await_macro, futures_api)] +/// #![feature(async_await, await_macro)] /// # futures::executor::block_on(async { /// use futures::future; /// @@ -149,7 +149,7 @@ generate! { /// that error: /// /// ``` -/// #![feature(async_await, await_macro, futures_api)] +/// #![feature(async_await, await_macro)] /// # futures::executor::block_on(async { /// use futures::future; /// @@ -173,7 +173,7 @@ where /// # Examples /// /// ``` -/// #![feature(async_await, await_macro, futures_api)] +/// #![feature(async_await, await_macro)] /// # futures::executor::block_on(async { /// use futures::future; /// @@ -203,7 +203,7 @@ where /// # Examples /// /// ``` -/// #![feature(async_await, await_macro, futures_api)] +/// #![feature(async_await, await_macro)] /// # futures::executor::block_on(async { /// use futures::future; /// @@ -236,7 +236,7 @@ where /// # Examples /// /// ``` -/// #![feature(async_await, await_macro, futures_api)] +/// #![feature(async_await, await_macro)] /// # futures::executor::block_on(async { /// use futures::future; /// diff --git a/futures-util/src/try_future/try_join_all.rs b/futures-util/src/try_future/try_join_all.rs index 61d125faae..deefe0ffb5 100644 --- a/futures-util/src/try_future/try_join_all.rs +++ b/futures-util/src/try_future/try_join_all.rs @@ -97,7 +97,7 @@ where /// # Examples /// /// ``` -/// #![feature(async_await, await_macro, futures_api)] +/// #![feature(async_await, await_macro)] /// # futures::executor::block_on(async { /// use futures::future::{self, try_join_all}; /// diff --git a/futures-util/src/try_stream/mod.rs b/futures-util/src/try_stream/mod.rs index e3691d93e8..bdae4d237a 100644 --- a/futures-util/src/try_stream/mod.rs +++ b/futures-util/src/try_stream/mod.rs @@ -79,7 +79,7 @@ pub trait TryStreamExt: TryStream { /// # Examples /// /// ``` - /// #![feature(async_await, await_macro, futures_api)] + /// #![feature(async_await, await_macro)] /// # futures::executor::block_on(async { /// use futures::stream::{self, TryStreamExt}; /// @@ -105,7 +105,7 @@ pub trait TryStreamExt: TryStream { /// # Examples /// /// ``` - /// #![feature(async_await, await_macro, futures_api)] + /// #![feature(async_await, await_macro)] /// # futures::executor::block_on(async { /// use futures::stream::{self, TryStreamExt}; /// @@ -131,7 +131,7 @@ pub trait TryStreamExt: TryStream { /// # Examples /// /// ``` - /// #![feature(async_await, await_macro, futures_api)] + /// #![feature(async_await, await_macro)] /// # futures::executor::block_on(async { /// use futures::stream::{self, TryStreamExt}; /// @@ -260,7 +260,7 @@ pub trait TryStreamExt: TryStream { /// # Examples /// /// ``` - /// #![feature(async_await, await_macro, futures_api)] + /// #![feature(async_await, await_macro)] /// # futures::executor::block_on(async { /// use futures::stream::{self, TryStreamExt}; /// @@ -292,7 +292,7 @@ pub trait TryStreamExt: TryStream { /// # Examples /// /// ``` - /// #![feature(async_await, await_macro, futures_api)] + /// #![feature(async_await, await_macro)] /// # futures::executor::block_on(async { /// use futures::future; /// use futures::stream::{self, TryStreamExt}; @@ -327,7 +327,7 @@ pub trait TryStreamExt: TryStream { /// # Examples /// /// ``` - /// #![feature(async_await, await_macro, futures_api)] + /// #![feature(async_await, await_macro)] /// # futures::executor::block_on(async { /// use futures::future; /// use futures::stream::{self, TryStreamExt}; @@ -362,7 +362,7 @@ pub trait TryStreamExt: TryStream { /// # Examples /// /// ``` - /// #![feature(async_await, await_macro, futures_api)] + /// #![feature(async_await, await_macro)] /// # futures::executor::block_on(async { /// use futures::channel::oneshot; /// use futures::stream::{self, StreamExt, TryStreamExt}; @@ -418,7 +418,7 @@ pub trait TryStreamExt: TryStream { /// # Examples /// /// ``` - /// #![feature(async_await, await_macro, futures_api)] + /// #![feature(async_await, await_macro)] /// # futures::executor::block_on(async { /// use futures::channel::mpsc; /// use futures::executor::block_on; @@ -461,7 +461,7 @@ pub trait TryStreamExt: TryStream { /// /// # Examples /// ``` - /// #![feature(async_await, await_macro, futures_api)] + /// #![feature(async_await, await_macro)] /// # futures::executor::block_on(async { /// use futures::executor::block_on; /// use futures::future; @@ -502,7 +502,7 @@ pub trait TryStreamExt: TryStream { /// # Examples /// /// ``` - /// #![feature(async_await, await_macro, futures_api)] + /// #![feature(async_await, await_macro)] /// # futures::executor::block_on(async { /// use futures::future; /// use futures::stream::{self, TryStreamExt}; @@ -585,7 +585,7 @@ pub trait TryStreamExt: TryStream { /// /// Results are returned in the order of completion: /// ``` - /// #![feature(async_await, await_macro, futures_api)] + /// #![feature(async_await, await_macro)] /// # futures::executor::block_on(async { /// use futures::channel::oneshot; /// use futures::stream::{self, StreamExt, TryStreamExt}; @@ -609,7 +609,7 @@ pub trait TryStreamExt: TryStream { /// /// Errors from the underlying stream itself are propagated: /// ``` - /// #![feature(async_await, await_macro, futures_api)] + /// #![feature(async_await, await_macro)] /// # futures::executor::block_on(async { /// use futures::channel::mpsc; /// use futures::future; @@ -651,7 +651,7 @@ pub trait TryStreamExt: TryStream { /// Wraps a [`TryStream`] into a stream compatible with libraries using /// futures 0.1 `Stream`. Requires the `compat` feature to be enabled. /// ``` - /// #![feature(async_await, await_macro, futures_api)] + /// #![feature(async_await, await_macro)] /// use futures::future::{FutureExt, TryFutureExt}; /// # let (tx, rx) = futures::channel::oneshot::channel(); /// @@ -686,7 +686,7 @@ pub trait TryStreamExt: TryStream { /// # Examples /// /// ``` - /// #![feature(async_await, await_macro, futures_api)] + /// #![feature(async_await, await_macro)] /// # futures::executor::block_on(async { /// use futures::executor::block_on; /// use futures::future::lazy; diff --git a/futures-util/tests/atomic_waker.rs b/futures-util/tests/atomic_waker.rs index 7a1e6da444..75b84f5c49 100644 --- a/futures-util/tests/atomic_waker.rs +++ b/futures-util/tests/atomic_waker.rs @@ -1,5 +1,3 @@ -#![feature(futures_api)] - use std::sync::atomic::AtomicUsize; use std::sync::atomic::Ordering; use std::sync::Arc; diff --git a/futures-util/tests/futures_unordered.rs b/futures-util/tests/futures_unordered.rs index 726daf1629..ec4b6bade9 100644 --- a/futures-util/tests/futures_unordered.rs +++ b/futures-util/tests/futures_unordered.rs @@ -1,4 +1,4 @@ -#![feature(async_await, await_macro, futures_api)] +#![feature(async_await, await_macro)] use futures::future; use futures::task::Poll; diff --git a/futures-util/tests/mutex.rs b/futures-util/tests/mutex.rs index ab634e8f35..73649ec8fd 100644 --- a/futures-util/tests/mutex.rs +++ b/futures-util/tests/mutex.rs @@ -1,4 +1,4 @@ -#![feature(async_await, await_macro, futures_api)] +#![feature(async_await, await_macro)] use futures::channel::mpsc; use futures::future::{ready, FutureExt}; diff --git a/futures-util/tests/select_all.rs b/futures-util/tests/select_all.rs index 6c895e5925..a0e9ad667f 100644 --- a/futures-util/tests/select_all.rs +++ b/futures-util/tests/select_all.rs @@ -1,4 +1,4 @@ -#![feature(async_await, await_macro, futures_api)] +#![feature(async_await, await_macro)] use futures::future; use futures::FutureExt; diff --git a/futures-util/tests/select_next_some.rs b/futures-util/tests/select_next_some.rs index 0485146949..fb521d6075 100644 --- a/futures-util/tests/select_next_some.rs +++ b/futures-util/tests/select_next_some.rs @@ -1,4 +1,4 @@ -#![feature(async_await, await_macro, futures_api)] +#![feature(async_await, await_macro)] use futures::{future, select}; use futures::future::{FusedFuture, FutureExt}; diff --git a/futures/src/lib.rs b/futures/src/lib.rs index 005beefeda..f20f7a86a3 100644 --- a/futures/src/lib.rs +++ b/futures/src/lib.rs @@ -21,7 +21,6 @@ //! streams and sinks, and then spawned as independent tasks that are run to //! completion, but *do not block* the thread running them. -#![feature(futures_api)] #![cfg_attr(feature = "cfg-target-has-atomic", feature(cfg_target_has_atomic))] #![cfg_attr(feature = "never-type", feature(never_type))] @@ -125,7 +124,6 @@ pub mod executor { //! can then spawn further tasks back onto the pool to complete its work: //! //! ``` - //! #![feature(futures_api)] //! use futures::executor::ThreadPool; //! # use futures::future::{Future, lazy}; //! # let my_app = lazy(|_| 42); diff --git a/futures/tests/abortable.rs b/futures/tests/abortable.rs index dbedc230a5..5925c9a27b 100644 --- a/futures/tests/abortable.rs +++ b/futures/tests/abortable.rs @@ -1,5 +1,3 @@ -#![feature(futures_api)] - use futures::channel::oneshot; use futures::executor::block_on; use futures::future::{abortable, Aborted, FutureExt}; diff --git a/futures/tests/async_await_macros.rs b/futures/tests/async_await_macros.rs index 765adcdf1b..2480fa88d8 100644 --- a/futures/tests/async_await_macros.rs +++ b/futures/tests/async_await_macros.rs @@ -1,5 +1,5 @@ #![recursion_limit="128"] -#![feature(async_await, await_macro, futures_api)] +#![feature(async_await, await_macro)] use futures::{Poll, pending, poll, join, try_join, select}; use futures::channel::{mpsc, oneshot}; diff --git a/futures/tests/basic_combinators.rs b/futures/tests/basic_combinators.rs index 66ac5428b4..fa65b6f5f1 100644 --- a/futures/tests/basic_combinators.rs +++ b/futures/tests/basic_combinators.rs @@ -1,5 +1,3 @@ -#![feature(futures_api)] - use futures::future::{self, FutureExt, TryFutureExt}; use futures_test::future::FutureTestExt; use std::sync::mpsc; diff --git a/futures/tests/compat.rs b/futures/tests/compat.rs index dbfb7bb57a..f03134191b 100644 --- a/futures/tests/compat.rs +++ b/futures/tests/compat.rs @@ -1,4 +1,4 @@ -#![feature(await_macro, async_await, futures_api)] +#![feature(await_macro, async_await)] #![cfg(feature = "compat")] use tokio::timer::Delay; diff --git a/futures/tests/eager_drop.rs b/futures/tests/eager_drop.rs index c1237911dd..674e40121d 100644 --- a/futures/tests/eager_drop.rs +++ b/futures/tests/eager_drop.rs @@ -1,5 +1,3 @@ -#![feature(futures_api)] - use futures::channel::oneshot; use futures::future::{self, Future, FutureExt, TryFutureExt}; use futures::task::{Context, Poll}; diff --git a/futures/tests/fuse.rs b/futures/tests/fuse.rs index 1386845eab..83f2c1ce9e 100644 --- a/futures/tests/fuse.rs +++ b/futures/tests/fuse.rs @@ -1,5 +1,3 @@ -#![feature(futures_api)] - use futures::future::{self, FutureExt}; use futures::task::Context; use futures_test::task::panic_waker; diff --git a/futures/tests/future_obj.rs b/futures/tests/future_obj.rs index 39472f0db1..d4e798ef5a 100644 --- a/futures/tests/future_obj.rs +++ b/futures/tests/future_obj.rs @@ -1,4 +1,4 @@ -#![feature(async_await, futures_api)] +#![feature(async_await)] use futures::future::{Future, FutureObj}; use std::pin::Pin; diff --git a/futures/tests/futures_ordered.rs b/futures/tests/futures_ordered.rs index c51cb551d3..7828149d84 100644 --- a/futures/tests/futures_ordered.rs +++ b/futures/tests/futures_ordered.rs @@ -1,5 +1,3 @@ -#![feature(futures_api)] - use futures::channel::oneshot; use futures::executor::{block_on, block_on_stream}; use futures::future::{self, join, FutureExt}; diff --git a/futures/tests/futures_unordered.rs b/futures/tests/futures_unordered.rs index dce4fa9130..b0d7c57387 100644 --- a/futures/tests/futures_unordered.rs +++ b/futures/tests/futures_unordered.rs @@ -1,5 +1,3 @@ -#![feature(futures_api)] - use futures::channel::oneshot; use futures::executor::{block_on, block_on_stream}; use futures::future::{self, join, FutureExt}; diff --git a/futures/tests/inspect.rs b/futures/tests/inspect.rs index 00b43566e5..42f6f73634 100644 --- a/futures/tests/inspect.rs +++ b/futures/tests/inspect.rs @@ -1,5 +1,3 @@ -#![feature(futures_api)] - use futures::executor::block_on; use futures::future::{self, FutureExt}; diff --git a/futures/tests/io_read_exact.rs b/futures/tests/io_read_exact.rs index 7f6b1031e9..e042e97936 100644 --- a/futures/tests/io_read_exact.rs +++ b/futures/tests/io_read_exact.rs @@ -1,5 +1,3 @@ -#![feature(futures_api)] - use futures::executor::block_on; use futures::io::AsyncReadExt; diff --git a/futures/tests/join_all.rs b/futures/tests/join_all.rs index 7036d8372f..39f2608f30 100644 --- a/futures/tests/join_all.rs +++ b/futures/tests/join_all.rs @@ -1,4 +1,4 @@ -#![feature(async_await, futures_api)] +#![feature(async_await)] use futures_util::future::*; use std::future::Future; diff --git a/futures/tests/oneshot.rs b/futures/tests/oneshot.rs index 38e79a2ee2..58951ec581 100644 --- a/futures/tests/oneshot.rs +++ b/futures/tests/oneshot.rs @@ -1,5 +1,3 @@ -#![feature(futures_api)] - use futures::channel::oneshot; use futures::future::{FutureExt, TryFutureExt}; use futures_test::future::FutureTestExt; diff --git a/futures/tests/recurse.rs b/futures/tests/recurse.rs index 5c64778c28..2920a41a59 100644 --- a/futures/tests/recurse.rs +++ b/futures/tests/recurse.rs @@ -1,5 +1,3 @@ -#![feature(futures_api)] - use futures::executor::block_on; use futures::future::{self, FutureExt, BoxFuture}; use std::sync::mpsc; diff --git a/futures/tests/shared.rs b/futures/tests/shared.rs index 5f7565ebce..4e97265198 100644 --- a/futures/tests/shared.rs +++ b/futures/tests/shared.rs @@ -1,5 +1,3 @@ -#![feature(futures_api)] - use futures::channel::oneshot; use futures::executor::{block_on, LocalPool}; use futures::future::{self, FutureExt, LocalFutureObj}; diff --git a/futures/tests/split.rs b/futures/tests/split.rs index 84ae5049d5..5a6b38024f 100644 --- a/futures/tests/split.rs +++ b/futures/tests/split.rs @@ -1,5 +1,3 @@ -#![feature(futures_api)] - use futures::executor::block_on; use futures::sink::{Sink, SinkExt}; use futures::stream::{self, Stream, StreamExt}; diff --git a/futures/tests/stream.rs b/futures/tests/stream.rs index c6a617c2c7..65953d02d4 100644 --- a/futures/tests/stream.rs +++ b/futures/tests/stream.rs @@ -1,4 +1,4 @@ -#![feature(async_await, futures_api)] +#![feature(async_await)] extern crate futures; extern crate futures_util; diff --git a/futures/tests/try_join_all.rs b/futures/tests/try_join_all.rs index 3d4fa44c8b..bdca3e959c 100644 --- a/futures/tests/try_join_all.rs +++ b/futures/tests/try_join_all.rs @@ -1,4 +1,4 @@ -#![feature(async_await, futures_api)] +#![feature(async_await)] use futures_util::future::*; use futures_util::try_future::{try_join_all, TryJoinAll}; diff --git a/futures/tests/unfold.rs b/futures/tests/unfold.rs index cd8819c28e..377647fa22 100644 --- a/futures/tests/unfold.rs +++ b/futures/tests/unfold.rs @@ -1,5 +1,3 @@ -#![feature(futures_api)] - use futures::future; use futures::stream;