]> git.lizzy.rs Git - rust.git/blob - src/test/ui/mismatched_types/trait-impl-fn-incompatibility.rs
Rollup merge of #89945 - JohnTitor:we-now-specialize-clone-from-slice, r=the8472
[rust.git] / src / test / ui / mismatched_types / trait-impl-fn-incompatibility.rs
1 trait Foo {
2     fn foo(x: u16);
3     fn bar(&mut self, bar: &mut Bar);
4 }
5
6 struct Bar;
7
8 impl Foo for Bar {
9     fn foo(x: i16) { } //~ ERROR incompatible type
10     fn bar(&mut self, bar: &Bar) { } //~ ERROR incompatible type
11 }
12
13 fn main() {
14 }