diff options
| author | Frank Steffahn <frank.steffahn@stu.uni-kiel.de> | 2022-01-07 01:52:42 +0100 |
|---|---|---|
| committer | Frank Steffahn <frank.steffahn@stu.uni-kiel.de> | 2022-01-07 01:53:51 +0100 |
| commit | 731bbae816e49cb404f402e8a5d392059e417ee5 (patch) | |
| tree | 34ebb15eabbe77035062a9fe9eada6c7e3c059c6 /library/core/src/future | |
| parent | a043acd0b2cb9cb510cdeb040c0ce881af376142 (diff) | |
| download | rust-731bbae816e49cb404f402e8a5d392059e417ee5.tar.gz rust-731bbae816e49cb404f402e8a5d392059e417ee5.zip | |
Also change PhantomData parameter of iter::Empty, and future::Pending
Diffstat (limited to 'library/core/src/future')
| -rw-r--r-- | library/core/src/future/pending.rs | 5 |
1 files changed, 1 insertions, 4 deletions
diff --git a/library/core/src/future/pending.rs b/library/core/src/future/pending.rs index 560dd25ecff..2877e66eca8 100644 --- a/library/core/src/future/pending.rs +++ b/library/core/src/future/pending.rs @@ -12,7 +12,7 @@ use crate::task::{Context, Poll}; #[stable(feature = "future_readiness_fns", since = "1.48.0")] #[must_use = "futures do nothing unless you `.await` or poll them"] pub struct Pending<T> { - _data: marker::PhantomData<T>, + _data: marker::PhantomData<fn() -> T>, } /// Creates a future which never resolves, representing a computation that never @@ -44,9 +44,6 @@ impl<T> Future for Pending<T> { } #[stable(feature = "future_readiness_fns", since = "1.48.0")] -impl<T> Unpin for Pending<T> {} - -#[stable(feature = "future_readiness_fns", since = "1.48.0")] impl<T> Debug for Pending<T> { fn fmt(&self, f: &mut fmt::Formatter<'_>) -> fmt::Result { f.debug_struct("Pending").finish() |
