I have types for which I implement different traits. I'd like to store references/Boxes to objects that implement common set of traits.
For example (not my use case) I'd like a vector where each element implements
type Element = Clone + Display + PartialEq; let v: Vec<&Element> = vec!;
I think I understand why I can't specify multiple traits like that (fat pointer only points to a single trait impl).
What are my options in Rust? I could have a helper that creates e.g. tuples with each index representing one & dyn trait but perhaps there's a better way.