Skip to content

Commit a84f425

Browse files
committed
Update to stabilized futures_api
1 parent 4284055 commit a84f425

Some content is hidden

Large Commits have some content hidden by default. Use the searchbox below for content that may be hidden.

74 files changed

+111
-174
lines changed

futures-channel/benches/sync_mpsc.rs

+1-1
Original file line numberDiff line numberDiff line change
@@ -1,4 +1,4 @@
1-
#![feature(test, futures_api)]
1+
#![feature(test)]
22

33
extern crate test;
44
use crate::test::Bencher;

futures-channel/src/lib.rs

-2
Original file line numberDiff line numberDiff line change
@@ -3,8 +3,6 @@
33
//! This crate provides channels that can be used to communicate between
44
//! asynchronous tasks.
55
6-
#![feature(futures_api)]
7-
86
#![cfg_attr(not(feature = "std"), no_std)]
97

108
#![warn(missing_docs, missing_debug_implementations, rust_2018_idioms)]

futures-channel/tests/channel.rs

+1-1
Original file line numberDiff line numberDiff line change
@@ -1,4 +1,4 @@
1-
#![feature(async_await, await_macro, futures_api)]
1+
#![feature(async_await, await_macro)]
22

33
use futures::channel::mpsc;
44
use futures::executor::block_on;

futures-channel/tests/mpsc.rs

+1-1
Original file line numberDiff line numberDiff line change
@@ -1,4 +1,4 @@
1-
#![feature(futures_api, async_await, await_macro)]
1+
#![feature(async_await, await_macro)]
22

33
use futures::channel::{mpsc, oneshot};
44
use futures::executor::{block_on, block_on_stream};

futures-channel/tests/oneshot.rs

-2
Original file line numberDiff line numberDiff line change
@@ -1,5 +1,3 @@
1-
#![feature(futures_api)]
2-
31
use futures::channel::oneshot::{self, Sender};
42
use futures::executor::block_on;
53
use futures::future::{Future, FutureExt, poll_fn};

futures-core/src/lib.rs

-1
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,5 @@
11
//! Core traits and types for asynchronous operations in Rust.
22
3-
#![feature(futures_api)]
43
#![cfg_attr(feature = "cfg-target-has-atomic", feature(cfg_target_has_atomic))]
54

65
#![cfg_attr(not(feature = "std"), no_std)]

futures-core/src/task/__internal/atomic_waker.rs

-1
Original file line numberDiff line numberDiff line change
@@ -169,7 +169,6 @@ impl AtomicWaker {
169169
/// Here is how `register` is used when implementing a flag.
170170
///
171171
/// ```
172-
/// #![feature(futures_api)]
173172
/// use futures::future::Future;
174173
/// use futures::task::{Context, Poll, AtomicWaker};
175174
/// use std::sync::atomic::AtomicBool;

futures-executor/benches/thread_notify.rs

+1-1
Original file line numberDiff line numberDiff line change
@@ -1,4 +1,4 @@
1-
#![feature(test, futures_api)]
1+
#![feature(test)]
22

33
extern crate test;
44
use crate::test::Bencher;

futures-executor/src/lib.rs

-2
Original file line numberDiff line numberDiff line change
@@ -1,7 +1,5 @@
11
//! Built-in executors and related tools.
22
3-
#![feature(futures_api)]
4-
53
#![cfg_attr(not(feature = "std"), no_std)]
64

75
#![warn(missing_docs, missing_debug_implementations, rust_2018_idioms)]

futures-executor/src/local_pool.rs

-3
Original file line numberDiff line numberDiff line change
@@ -132,7 +132,6 @@ impl LocalPool {
132132
/// the `LocalPool` by using its spawner handle:
133133
///
134134
/// ```
135-
/// #![feature(futures_api)]
136135
/// use futures::executor::LocalPool;
137136
/// use futures::future::ready;
138137
///
@@ -170,7 +169,6 @@ impl LocalPool {
170169
/// can be made. Returns `true` if one future was completed, `false` otherwise.
171170
///
172171
/// ```
173-
/// #![feature(futures_api)]
174172
/// use futures::executor::LocalPool;
175173
/// use futures::task::LocalSpawnExt;
176174
/// use futures::future::{ready, empty};
@@ -211,7 +209,6 @@ impl LocalPool {
211209
/// on any task.
212210
///
213211
/// ```
214-
/// #![feature(futures_api)]
215212
/// use futures::executor::LocalPool;
216213
/// use futures::task::LocalSpawnExt;
217214
/// use futures::future::{ready, empty};

futures-executor/tests/local_pool.rs

-2
Original file line numberDiff line numberDiff line change
@@ -1,5 +1,3 @@
1-
#![feature(futures_api)]
2-
31
use futures::channel::oneshot;
42
use futures::executor::LocalPool;
53
use futures::future::{Future, lazy, poll_fn};

futures-io/src/lib.rs

-2
Original file line numberDiff line numberDiff line change
@@ -10,8 +10,6 @@
1010

1111
#![doc(html_root_url = "https://rust-lang-nursery.github.io/futures-api-docs/0.3.0-alpha.14/futures_io")]
1212

13-
#![feature(futures_api)]
14-
1513
#[cfg(feature = "std")]
1614
mod if_std {
1715
use futures_core::task::{Context, Poll};

futures-io/tests/cursor.rs

-2
Original file line numberDiff line numberDiff line change
@@ -1,5 +1,3 @@
1-
#![feature(futures_api)]
2-
31
use assert_matches::assert_matches;
42
use futures::Poll;
53
use futures::future::lazy;

futures-sink/src/lib.rs

-2
Original file line numberDiff line numberDiff line change
@@ -7,8 +7,6 @@
77
#![warn(missing_docs, missing_debug_implementations, rust_2018_idioms)]
88
#![doc(html_root_url = "https://rust-lang-nursery.github.io/futures-api-docs/0.3.0-alpha.14/futures_sink")]
99

10-
#![feature(futures_api)]
11-
1210
#[cfg(feature = "alloc")]
1311
extern crate alloc;
1412

futures-test/src/assert.rs

+3-3
Original file line numberDiff line numberDiff line change
@@ -9,7 +9,7 @@ pub fn assert_is_unpin_stream<S: Stream + Unpin>(_: &mut S) {}
99
/// # Examples
1010
///
1111
/// ```
12-
/// #![feature(async_await, futures_api)]
12+
/// #![feature(async_await)]
1313
/// use futures::stream;
1414
/// use futures_test::future::FutureTestExt;
1515
/// use futures_test::{
@@ -46,7 +46,7 @@ macro_rules! assert_stream_pending {
4646
/// # Examples
4747
///
4848
/// ```
49-
/// #![feature(async_await, futures_api)]
49+
/// #![feature(async_await)]
5050
/// use futures::stream;
5151
/// use futures_test::future::FutureTestExt;
5252
/// use futures_test::{
@@ -89,7 +89,7 @@ macro_rules! assert_stream_next {
8989
/// # Examples
9090
///
9191
/// ```
92-
/// #![feature(async_await, futures_api)]
92+
/// #![feature(async_await)]
9393
/// use futures::stream;
9494
/// use futures_test::future::FutureTestExt;
9595
/// use futures_test::{

futures-test/src/future/mod.rs

+2-2
Original file line numberDiff line numberDiff line change
@@ -33,7 +33,7 @@ pub trait FutureTestExt: Future {
3333
/// # Examples
3434
///
3535
/// ```
36-
/// #![feature(async_await, futures_api)]
36+
/// #![feature(async_await)]
3737
/// use futures::task::Poll;
3838
/// use futures::future::FutureExt;
3939
/// use futures_test::task::noop_context;
@@ -60,7 +60,7 @@ pub trait FutureTestExt: Future {
6060
/// # Examples
6161
///
6262
/// ```
63-
/// #![feature(async_await, futures_api)]
63+
/// #![feature(async_await)]
6464
/// use futures::channel::oneshot;
6565
/// use futures::executor::block_on;
6666
/// use futures_test::future::FutureTestExt;

futures-test/src/lib.rs

+1-5
Original file line numberDiff line numberDiff line change
@@ -1,10 +1,6 @@
11
//! Utilities to make testing [`Future`s](futures_core::Future) easier
22
3-
#![feature(
4-
async_await,
5-
await_macro,
6-
futures_api,
7-
)]
3+
#![feature(async_await, await_macro, futures_api_const_fn_ptr)]
84
#![warn(missing_docs, missing_debug_implementations, rust_2018_idioms)]
95
#![doc(
106
html_root_url = "https://rust-lang-nursery.github.io/futures-doc/0.3.0-alpha.5/futures_test"

futures-test/src/task/context.rs

+1-2
Original file line numberDiff line numberDiff line change
@@ -7,7 +7,6 @@ use futures_core::task::Context;
77
/// # Examples
88
///
99
/// ```should_panic
10-
/// #![feature(futures_api)]
1110
/// use futures_test::task::panic_context;
1211
///
1312
/// let cx = panic_context();
@@ -23,7 +22,7 @@ pub fn panic_context() -> Context<'static> {
2322
/// # Examples
2423
///
2524
/// ```
26-
/// #![feature(async_await, futures_api)]
25+
/// #![feature(async_await)]
2726
/// use futures::future::Future;
2827
/// use futures::task::Poll;
2928
/// use futures_test::task::noop_context;

futures-test/src/task/noop_spawner.rs

+2-2
Original file line numberDiff line numberDiff line change
@@ -7,7 +7,7 @@ use futures_core::task::{Spawn, SpawnError};
77
/// # Examples
88
///
99
/// ```
10-
/// #![feature(async_await, futures_api)]
10+
/// #![feature(async_await)]
1111
/// use futures::task::SpawnExt;
1212
/// use futures_test::task::NoopSpawner;
1313
///
@@ -46,7 +46,7 @@ impl Default for NoopSpawner {
4646
/// # Examples
4747
///
4848
/// ```
49-
/// #![feature(async_await, futures_api)]
49+
/// #![feature(async_await)]
5050
/// use futures::task::SpawnExt;
5151
/// use futures_test::task::noop_spawner_mut;
5252
///

futures-test/src/task/panic_spawner.rs

+2-2
Original file line numberDiff line numberDiff line change
@@ -7,7 +7,7 @@ use futures_core::task::{Spawn, SpawnError};
77
/// # Examples
88
///
99
/// ```should_panic
10-
/// #![feature(async_await, futures_api)]
10+
/// #![feature(async_await)]
1111
/// use futures::task::SpawnExt;
1212
/// use futures_test::task::PanicSpawner;
1313
///
@@ -46,7 +46,7 @@ impl Default for PanicSpawner {
4646
/// # Examples
4747
///
4848
/// ```should_panic
49-
/// #![feature(async_await, futures_api)]
49+
/// #![feature(async_await)]
5050
/// use futures::task::SpawnExt;
5151
/// use futures_test::task::panic_spawner_mut;
5252
///

futures-test/src/task/panic_waker.rs

+1-2
Original file line numberDiff line numberDiff line change
@@ -30,7 +30,6 @@ fn raw_panic_waker() -> RawWaker {
3030
/// # Examples
3131
///
3232
/// ```should_panic
33-
/// #![feature(futures_api)]
3433
/// use futures_test::task::panic_waker;
3534
///
3635
/// let waker = panic_waker();
@@ -47,7 +46,7 @@ pub fn panic_waker() -> Waker {
4746
/// # Examples
4847
///
4948
/// ```should_panic
50-
/// #![feature(async_await, futures_api)]
49+
/// #![feature(async_await)]
5150
/// use futures::task;
5251
/// use futures_test::task::panic_waker_ref;
5352
///

futures-test/src/task/record_spawner.rs

+1-1
Original file line numberDiff line numberDiff line change
@@ -7,7 +7,7 @@ use futures_core::task::{Spawn, SpawnError};
77
/// # Examples
88
///
99
/// ```
10-
/// #![feature(async_await, futures_api)]
10+
/// #![feature(async_await)]
1111
/// use futures::task::SpawnExt;
1212
/// use futures_test::task::RecordSpawner;
1313
///

futures-test/src/task/wake_counter.rs

-1
Original file line numberDiff line numberDiff line change
@@ -42,7 +42,6 @@ impl ArcWake for WakerInner {
4242
/// # Examples
4343
///
4444
/// ```
45-
/// #![feature(futures_api)]
4645
/// use futures_test::task::new_count_waker;
4746
///
4847
/// let (waker, count) = new_count_waker();

futures-util/benches/futures_unordered.rs

+1-1
Original file line numberDiff line numberDiff line change
@@ -1,4 +1,4 @@
1-
#![feature(test, futures_api)]
1+
#![feature(test)]
22

33
extern crate test;
44
use crate::test::Bencher;

futures-util/src/async_await/join.rs

+3-3
Original file line numberDiff line numberDiff line change
@@ -11,7 +11,7 @@
1111
/// # Examples
1212
///
1313
/// ```
14-
/// #![feature(async_await, await_macro, futures_api)]
14+
/// #![feature(async_await, await_macro)]
1515
/// # futures::executor::block_on(async {
1616
/// use futures::{join, future};
1717
///
@@ -60,7 +60,7 @@ macro_rules! join {
6060
/// `Ok` of a tuple of the values:
6161
///
6262
/// ```
63-
/// #![feature(async_await, await_macro, futures_api)]
63+
/// #![feature(async_await, await_macro)]
6464
/// # futures::executor::block_on(async {
6565
/// use futures::{try_join, future};
6666
///
@@ -75,7 +75,7 @@ macro_rules! join {
7575
/// that error:
7676
///
7777
/// ```
78-
/// #![feature(async_await, await_macro, futures_api)]
78+
/// #![feature(async_await, await_macro)]
7979
/// # futures::executor::block_on(async {
8080
/// use futures::{try_join, future};
8181
///

futures-util/src/async_await/select_mod.rs

+3-3
Original file line numberDiff line numberDiff line change
@@ -24,7 +24,7 @@ macro_rules! document_select_macro {
2424
/// # Examples
2525
///
2626
/// ```
27-
/// #![feature(async_await, await_macro, futures_api)]
27+
/// #![feature(async_await, await_macro)]
2828
/// # futures::executor::block_on(async {
2929
/// use futures::future::{self, FutureExt};
3030
/// use futures::select;
@@ -40,7 +40,7 @@ macro_rules! document_select_macro {
4040
/// ```
4141
///
4242
/// ```
43-
/// #![feature(async_await, await_macro, futures_api)]
43+
/// #![feature(async_await, await_macro)]
4444
/// # futures::executor::block_on(async {
4545
/// use futures::future::{self, FutureExt};
4646
/// use futures::stream::{self, StreamExt};
@@ -62,7 +62,7 @@ macro_rules! document_select_macro {
6262
/// the case where all futures have completed.
6363
///
6464
/// ```
65-
/// #![feature(async_await, await_macro, futures_api)]
65+
/// #![feature(async_await, await_macro)]
6666
/// # futures::executor::block_on(async {
6767
/// use futures::future::{self, FutureExt};
6868
/// use futures::select;

futures-util/src/compat/compat01as03.rs

+5-5
Original file line numberDiff line numberDiff line change
@@ -52,7 +52,7 @@ pub trait Future01CompatExt: Future01 {
5252
/// [`Future<Output = Result<T, E>>`](futures_core::future::Future).
5353
///
5454
/// ```
55-
/// #![feature(async_await, await_macro, futures_api)]
55+
/// #![feature(async_await, await_macro)]
5656
/// # futures::executor::block_on(async {
5757
/// # // TODO: These should be all using `futures::compat`, but that runs up against Cargo
5858
/// # // feature issues
@@ -79,7 +79,7 @@ pub trait Stream01CompatExt: Stream01 {
7979
/// [`Stream<Item = Result<T, E>>`](futures_core::stream::Stream).
8080
///
8181
/// ```
82-
/// #![feature(async_await, await_macro, futures_api)]
82+
/// #![feature(async_await, await_macro)]
8383
/// # futures::executor::block_on(async {
8484
/// use futures::stream::StreamExt;
8585
/// use futures_util::compat::Stream01CompatExt;
@@ -107,7 +107,7 @@ pub trait Sink01CompatExt: Sink01 {
107107
/// [`Sink<SinkItem = T, SinkError = E>`](futures_sink::sink::Sink).
108108
///
109109
/// ```
110-
/// #![feature(async_await, await_macro, futures_api)]
110+
/// #![feature(async_await, await_macro)]
111111
/// # futures::executor::block_on(async {
112112
/// use futures::{sink::SinkExt, stream::StreamExt};
113113
/// use futures_util::compat::{Stream01CompatExt, Sink01CompatExt};
@@ -356,7 +356,7 @@ mod io {
356356
/// [`AsyncRead`](futures_io::AsyncRead).
357357
///
358358
/// ```
359-
/// #![feature(async_await, await_macro, futures_api, impl_trait_in_bindings)]
359+
/// #![feature(async_await, await_macro, impl_trait_in_bindings)]
360360
/// # futures::executor::block_on(async {
361361
/// use futures::io::AsyncReadExt;
362362
/// use futures_util::compat::AsyncRead01CompatExt;
@@ -385,7 +385,7 @@ mod io {
385385
/// [`AsyncWrite`](futures_io::AsyncWrite).
386386
///
387387
/// ```
388-
/// #![feature(async_await, await_macro, futures_api, impl_trait_in_bindings)]
388+
/// #![feature(async_await, await_macro, impl_trait_in_bindings)]
389389
/// # futures::executor::block_on(async {
390390
/// use futures::io::AsyncWriteExt;
391391
/// use futures_util::compat::AsyncWrite01CompatExt;

futures-util/src/compat/executor.rs

+1-1
Original file line numberDiff line numberDiff line change
@@ -22,7 +22,7 @@ pub trait Executor01CompatExt: Executor01<Executor01Future> +
2222
/// futures 0.3 [`Spawn`](futures_core::task::Spawn).
2323
///
2424
/// ```
25-
/// #![feature(async_await, await_macro, futures_api)]
25+
/// #![feature(async_await, await_macro)]
2626
/// use futures::Future;
2727
/// use futures::task::SpawnExt;
2828
/// use futures::future::{FutureExt, TryFutureExt};

futures-util/src/future/empty.rs

+1-1
Original file line numberDiff line numberDiff line change
@@ -22,7 +22,7 @@ impl<T> FusedFuture for Empty<T> {
2222
/// # Examples
2323
///
2424
/// ```ignore
25-
/// #![feature(async_await, await_macro, futures_api)]
25+
/// #![feature(async_await, await_macro)]
2626
/// # futures::executor::block_on(async {
2727
/// use futures::future;
2828
///

0 commit comments

Comments
 (0)