Merge pull request #1854 from bugadani/str
embassy-{net, sync, time}: Use fmt::unwrap
This commit is contained in:
@ -71,7 +71,7 @@ impl Instant {
|
||||
/// Panics on over/underflow.
|
||||
pub fn duration_since(&self, earlier: Instant) -> Duration {
|
||||
Duration {
|
||||
ticks: self.ticks.checked_sub(earlier.ticks).unwrap(),
|
||||
ticks: unwrap!(self.ticks.checked_sub(earlier.ticks)),
|
||||
}
|
||||
}
|
||||
|
||||
|
Reference in New Issue
Block a user