// http://play.rust-lang.org/?gist=89c4e30f6847cd0858cfc49e5b89eb58&version=stable&mode=debug&edition=2015 trait ThingValue { fn as_string(&self) -> String; } impl ThingValue for Box { fn as_string(&self) -> String { (&*self as &ThingValue).as_string() } } trait Thing { type Value: ThingValue; fn get_value(&self) -> Self::Value; } struct SuchValue; impl ThingValue for SuchValue { fn as_string(&self) -> String { String::from("qwerty") } } struct Such; impl Thing for Such { type Value = SuchValue; fn get_value(&self) -> Self::Value { SuchValue {} } } struct Wrap> (T); impl> Thing for Wrap { type Value = Box; fn get_value(&self) -> Box { Box::new(self.0.get_value()) } } fn main() { let things: Vec>>> = vec![Box::new(Wrap(Such{}))]; }