fork/rust

git clone https://git.julia.blue/fork/rust

borsAuto merge of #66089 - Mark-Simulacrum:stable-next, r=Mark-Simulacrum4560ea788cb

1.39.0
845 B17 linesraw
1error[E0053]: method `foo` has an incompatible type for trait
2  --> $DIR/impl-generic-mismatch-ab.rs:8:32
3   |
4LL |     fn foo<A: Debug>(&self, a: &A, b: &impl Debug);
5   |                                -- type in trait
6...
7LL |     fn foo<B: Debug>(&self, a: &impl Debug, b: &B) { }
8   |                                ^^^^^^^^^^^ expected type parameter, found a different type parameter
9   |
10   = note: expected type `fn(&(), &B, &impl Debug)`
11              found type `fn(&(), &impl Debug, &B)`
12   = note: a type parameter was expected, but a different one was found; you might be missing a type parameter or trait bound
13   = note: for more information, visit https://doc.rust-lang.org/book/ch10-02-traits.html#traits-as-parameters
14
15error: aborting due to previous error
16
17For more information about this error, try `rustc --explain E0053`.