We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
There was an error while loading. Please reload this page.
1 parent c0781d8 commit 5616053Copy full SHA for 5616053
core/src/future/future.rs
@@ -28,7 +28,11 @@ use crate::task::{Context, Poll};
28
#[must_use = "futures do nothing unless you `.await` or poll them"]
29
#[stable(feature = "futures_api", since = "1.36.0")]
30
#[lang = "future_trait"]
31
-#[rustc_on_unimplemented(label = "`{Self}` is not a future", message = "`{Self}` is not a future")]
+#[rustc_on_unimplemented(
32
+ label = "`{Self}` is not a future",
33
+ message = "`{Self}` is not a future",
34
+ note = "{Self} must be a future or must implement `IntoFuture` to be awaited"
35
+)]
36
pub trait Future {
37
/// The type of value produced on completion.
38
0 commit comments