ps-promise 0.1.0-17

Promise-like owned futures
Documentation
1
2
3
4
5
6
7
8
9
10
11
use crate::sync::atomic::Ordering;

use super::super::GateState;

impl GateState {
    /// Returns whether the inner promise requested a wakeup since the last
    /// call, clearing the request.
    pub(in crate::gate) fn take_wake_request(&self) -> bool {
        self.woke.swap(false, Ordering::AcqRel)
    }
}