trait Foo {
fn foo(&self, a: A) -> A {
a
}
}
trait NotRelevant {
fn nr(&self, a: A) -> A {
a
}
}
struct Bar;
impl Foo for Bar {}
impl Foo for Bar {}
impl NotRelevant for Bar {}
fn main() {
let f1 = Bar;
f1.foo(1usize);
//~^ error: the trait bound `Bar: Foo` is not satisfied
}