arta_async_std/
time.rs

1use crate::AsyncStdGlobalRuntime;
2use arta::time::TimeRuntime;
3use futures::prelude::Future;
4use std::time::Duration;
5
6impl TimeRuntime for AsyncStdGlobalRuntime {
7    fn sleep(&self, duration: Duration) -> impl Future<Output = ()> + Send {
8        async_std::task::sleep(duration)
9    }
10}