@@ -11,63 +11,3 @@ index c306de3039f..eb5d5988768 100644
11
11
// 64-bit only to be sure the allocator will fail fast on an impossible to satsify size
12
12
#[cfg(target_pointer_width = "64")]
13
13
fn try_oom_error() {
14
- diff --git a/library/core/src/task/wake.rs b/library/core/src/task/wake.rs
15
- index 8fc942dedc9..1b43c46bda5 100644
16
- --- a/library/core/src/task/wake.rs
17
- +++ b/library/core/src/task/wake.rs
18
- @@ -622,7 +622,7 @@ impl LocalWaker {
19
- ///
20
- /// [`poll()`]: crate::future::Future::poll
21
- #[inline]
22
- - #[stable(feature = "futures_api", since = "1.36.0")]
23
- + #[unstable(feature = "local_waker", issue = "118959")]
24
- pub fn wake(self) {
25
- // The actual wakeup call is delegated through a virtual function call
26
- // to the implementation which is defined by the executor.
27
- @@ -644,7 +644,7 @@ pub fn wake(self) {
28
- /// the case where an owned `Waker` is available. This method should be preferred to
29
- /// calling `waker.clone().wake()`.
30
- #[inline]
31
- - #[stable(feature = "futures_api", since = "1.36.0")]
32
- + #[unstable(feature = "local_waker", issue = "118959")]
33
- pub fn wake_by_ref(&self) {
34
- // The actual wakeup call is delegated through a virtual function call
35
- // to the implementation which is defined by the executor.
36
- @@ -664,7 +664,7 @@ pub fn wake_by_ref(&self) {
37
- /// avoid cloning the waker when they would wake the same task anyway.
38
- #[inline]
39
- #[must_use]
40
- - #[stable(feature = "futures_api", since = "1.36.0")]
41
- + #[unstable(feature = "local_waker", issue = "118959")]
42
- pub fn will_wake(&self, other: &LocalWaker) -> bool {
43
- self.waker == other.waker
44
- }
45
- @@ -676,7 +676,7 @@ pub fn will_wake(&self, other: &LocalWaker) -> bool {
46
- /// Therefore this method is unsafe.
47
- #[inline]
48
- #[must_use]
49
- - #[stable(feature = "futures_api", since = "1.36.0")]
50
- + #[unstable(feature = "local_waker", issue = "118959")]
51
- #[rustc_const_unstable(feature = "const_waker", issue = "102012")]
52
- pub const unsafe fn from_raw(waker: RawWaker) -> LocalWaker {
53
- Self { waker }
54
- @@ -748,7 +748,18 @@ fn as_ref(&self) -> &LocalWaker {
55
- }
56
- }
57
-
58
- - #[stable(feature = "futures_api", since = "1.36.0")]
59
- + #[unstable(feature = "local_waker", issue = "118959")]
60
- + impl Drop for LocalWaker {
61
- + #[inline]
62
- + fn drop(&mut self) {
63
- + // SAFETY: This is safe because `LocalWaker::from_raw` is the only way
64
- + // to initialize `drop` and `data` requiring the user to acknowledge
65
- + // that the contract of `RawWaker` is upheld.
66
- + unsafe { (self.waker.vtable.drop)(self.waker.data) }
67
- + }
68
- + }
69
- +
70
- + #[unstable(feature = "local_waker", issue = "118959")]
71
- impl fmt::Debug for LocalWaker {
72
- fn fmt(&self, f: &mut fmt::Formatter<'_>) -> fmt::Result {
73
- let vtable_ptr = self.waker.vtable as *const RawWakerVTable;
0 commit comments