-
Notifications
You must be signed in to change notification settings - Fork 19
Milestone
Description
Hi,
I am working on moving RTIC to embedded time, however the following trivial code gives a weird trait bound error that I need help with.
What is causing this as is there a recommended fix?
Code:
let now = M::now();
match instant.checked_duration_since(&now) {
None => {
// ...
}
Some(dur) => {
let new_instant = now + dur; // <-- error
// ...
}
}
Error:
error[E0277]: the trait bound `rtic_core::monotonic::Generic<<M as rtic_core::monotonic::Clock>::T>: FixedPoint` is not satisfied
--> src/tq.rs:71:47
|
71 | let new_instant = now + dur;
| ^ the trait `FixedPoint` is not implemented for `rtic_core::monotonic::Generic<<M as rtic_core::monotonic::Clock>::T>`
|
= note: required because of the requirements on the impl of `Add<rtic_core::monotonic::Generic<<M as rtic_core::monotonic::Clock>::T>>` for `Instant<M>`
Metadata
Metadata
Assignees
Labels
No labels