obeli_sk_executor/
lib.rs

1pub mod executor;
2pub mod expired_timers_watcher;
3pub mod worker;
4
5use tokio::task::AbortHandle;
6
7pub struct AbortOnDropHandle {
8    handle: AbortHandle,
9}
10impl AbortOnDropHandle {
11    #[must_use]
12    pub fn new(handle: AbortHandle) -> Self {
13        Self { handle }
14    }
15}
16impl Drop for AbortOnDropHandle {
17    fn drop(&mut self) {
18        self.handle.abort();
19    }
20}