embassy/time: derives for TimeoutError.

This commit is contained in:
Dario Nieuwenhuis 2022-05-03 01:08:34 +02:00
parent 71e46d7efd
commit a465615196

View file

@ -7,6 +7,8 @@ use crate::executor::raw;
use crate::time::{Duration, Instant};
/// Error returned by [`with_timeout`] on timeout.
#[derive(Debug, Clone, PartialEq, Eq)]
#[cfg_attr(feature = "defmt", derive(defmt::Format))]
pub struct TimeoutError;
/// Runs a given future with a timeout.