]> git.lizzy.rs Git - rust.git/blob - src/test/ui/traits/impl-method-mismatch.stderr
Auto merge of #84959 - camsteffen:lint-suggest-group, r=estebank
[rust.git] / src / test / ui / traits / impl-method-mismatch.stderr
1 error[E0053]: method `jumbo` has an incompatible type for trait
2   --> $DIR/impl-method-mismatch.rs:7:5
3    |
4 LL |     fn jumbo(&self, x: &usize) -> usize;
5    |     ------------------------------------ type in trait
6 ...
7 LL |     unsafe fn jumbo(&self, x: &usize) { *self + *x; }
8    |     ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ expected normal fn, found unsafe fn
9    |
10    = note: expected fn pointer `fn(&usize, &usize) -> usize`
11               found fn pointer `unsafe fn(&usize, &usize)`
12
13 error: aborting due to previous error
14
15 For more information about this error, try `rustc --explain E0053`.