Closed as not planned
Description
Given the following code: https://play.rust-lang.org/?version=stable&mode=debug&edition=2021&gist=5c8b3650fbcd3671c608fd2e6ed118ad
fn foo(x: impl std::ops::Add) {
todo!()
}
struct X<T>(T);
impl<T: std::ops::Add<Output = T>> std::ops::Add for X<T> {
type Output = Self;
fn add(self, rhs: Self) -> Self {
Self(self.0 + rhs.0)
}
}
fn main() {
foo(X("x"));
}
The current output is:
note: required because of the requirements on the impl of `Add` for `X<&str>`
Ideally the output should look like:
note: required by the impl of `Add` for `X<&str>`
The original phrasing is distracting and contributes to visual noise.