Hope someone else can give a better explanation. Lifetimes are named regions of code that a reference must be valid for. Your code requires that the Vec contains &'a mut Handler<'a>, but you are trying to put in a &mut Handler<'a> the lifetime of the reference has no known relation to the lifetime 'a. Not the answer you're looking for? Acceleration without force in rotational motion? Youre often better off avoiding them and using owned values instead. How to read a lifetime error without looking at the code? The Rust Programming Language Forum Lifetime issue with 'indicate the anonymous lifetime: `<'_>`' help chb0github February 11, 2022, 12:07am #1 Thanks all for the help so far. Find centralized, trusted content and collaborate around the technologies you use most. To do this, you can use the Asking for help, clarification, or responding to other answers. As a simple Site design / logo 2023 Stack Exchange Inc; user contributions licensed under CC BY-SA. where this elision might otherwise be unclear. Could very old employee stock options still be accessible and viable? How to react to a students panic attack in an oral exam? Store data that implements a trait in a vector, the trait `_embedded_hal_digital_InputPin` is not implemented for `PE2
2023-04-21