1 Two associated items (like methods, associated types, associated functions,
2 etc.) were defined with the same identifier.
4 Erroneous code example:
10 fn bar(&self) -> bool { self.0 > 5 }
11 fn bar() {} // error: duplicate associated function
16 fn baz(&self) -> bool;
22 fn baz(&self) -> bool { true }
24 // error: duplicate method
25 fn baz(&self) -> bool { self.0 > 5 }
27 // error: duplicate associated type
32 Note, however, that items with the same name are allowed for inherent `impl`
33 blocks that don't overlap:
39 fn bar(&self) -> bool { self.0 > 5 }
43 fn bar(&self) -> bool { self.0 }