mirror of
https://github.com/embassy-rs/embassy.git
synced 2025-09-30 05:40:55 +00:00
Merge pull request #2756 from Frostie314159/ticker_send_sync
Made `Ticker::next` `Send+Sync`.
This commit is contained in:
commit
0549dd5fd7
@ -203,7 +203,7 @@ impl Ticker {
|
||||
}
|
||||
|
||||
/// Waits for the next tick.
|
||||
pub fn next(&mut self) -> impl Future<Output = ()> + '_ {
|
||||
pub fn next(&mut self) -> impl Future<Output = ()> + Send + Sync + '_ {
|
||||
poll_fn(|cx| {
|
||||
if self.expires_at <= Instant::now() {
|
||||
let dur = self.duration;
|
||||
|
Loading…
x
Reference in New Issue
Block a user