pub trait TryAdd { type Error; type Output; fn try_add(self, rhs: Rhs) -> Result; } impl TryAdd for Option { type Error = ::Error; type Output = Option<::Output>; fn try_add(self, rhs: Self) -> Result { Ok(self) //~ ERROR mismatched types } } struct Other(A); struct X; impl> TryAdd for Other { type Error = ::Error; type Output = Other<::Output>; fn try_add(self, rhs: Self) -> Result { Ok(self) //~ ERROR mismatched types } } fn main() {}