1
0
Fork 0
forked from wry/wry

autocommit 2022-04-27 18:04:02 CEST

This commit is contained in:
Julian Orth 2022-04-27 18:04:02 +02:00
parent cff35fd7da
commit 57899b3f35
14 changed files with 173 additions and 66 deletions

View file

@ -1,3 +1,4 @@
use std::fmt::{Debug, Formatter};
use {
crate::utils::numcell::NumCell,
std::{
@ -14,6 +15,12 @@ pub struct AsyncEvent {
waker: Cell<Option<Waker>>,
}
impl Debug for AsyncEvent {
fn fmt(&self, f: &mut Formatter<'_>) -> std::fmt::Result {
f.debug_struct("AsyncEvent").field("triggers", &self.triggers.get()).finish_non_exhaustive()
}
}
impl AsyncEvent {
pub fn clear(&self) {
self.waker.take();